Skip to content

Commit a48ebde

Browse files
alanopsclaude
andcommitted
Fix Railway deployment configuration
- Add .dockerignore to exclude frontend files from backend build - Add railway.toml to configure subdirectory deployment - Point Railway to backend/Dockerfile specifically This should resolve the 'Cannot find module express' error during build. 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
1 parent d7de743 commit a48ebde

3 files changed

Lines changed: 40 additions & 0 deletions

File tree

backend-only.tar.gz

10.8 KB
Binary file not shown.

backend/.dockerignore

Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,33 @@
1+
# Ignore everything outside backend directory
2+
../src
3+
../public
4+
../pages
5+
../components
6+
../styles
7+
../tests
8+
../tools
9+
../out
10+
../node_modules
11+
../.next
12+
../next.config.js
13+
../tailwind.config.js
14+
../postcss.config.js
15+
../tsconfig.json
16+
../package.json
17+
../package-lock.json
18+
19+
# Ignore unnecessary files
20+
*.md
21+
.git
22+
.gitignore
23+
.env*
24+
node_modules
25+
npm-debug.log*
26+
yarn-debug.log*
27+
yarn-error.log*
28+
29+
# Ignore build artifacts
30+
dist
31+
build
32+
.next
33+
out

railway.toml

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
[build]
2+
builder = "dockerfile"
3+
dockerfilePath = "backend/Dockerfile"
4+
5+
[deploy]
6+
startCommand = "npm start"
7+
healthcheckPath = "/health"

0 commit comments

Comments
 (0)