Spaces:
Running

axeronis commited on
Commit
a5853b7
·
1 Parent(s): 7b9aed2

Update start command to run migrations automatically

Browse files
Files changed (2) hide show
  1. backend/nixpacks.toml +1 -1
  2. backend/railway.json +2 -2
backend/nixpacks.toml CHANGED
@@ -8,4 +8,4 @@ cmds = ["pip install --no-cache-dir -r requirements.txt"]
8
  cmds = ["echo 'Build phase complete'"]
9
 
10
  [start]
11
- cmd = "uvicorn app.main:app --host 0.0.0.0 --port $PORT"
 
8
  cmds = ["echo 'Build phase complete'"]
9
 
10
  [start]
11
+ cmd = "alembic upgrade head && uvicorn app.main:app --host 0.0.0.0 --port $PORT"
backend/railway.json CHANGED
@@ -5,8 +5,8 @@
5
  "nixpacksConfigPath": "nixpacks.toml"
6
  },
7
  "deploy": {
8
- "startCommand": "uvicorn app.main:app --host 0.0.0.0 --port $PORT",
9
  "restartPolicyType": "ON_FAILURE",
10
  "restartPolicyMaxRetries": 10
11
  }
12
- }
 
5
  "nixpacksConfigPath": "nixpacks.toml"
6
  },
7
  "deploy": {
8
+ "startCommand": "alembic upgrade head && uvicorn app.main:app --host 0.0.0.0 --port $PORT",
9
  "restartPolicyType": "ON_FAILURE",
10
  "restartPolicyMaxRetries": 10
11
  }
12
+ }