diff --git a/Dockerfile b/Dockerfile index ed03ecc..c6f8a3e 100644 --- a/Dockerfile +++ b/Dockerfile @@ -14,8 +14,10 @@ RUN npm install --include=dev COPY . . RUN nx run-many -t build -p spin-cycle spin-cycle-client --prod -# Compile TypeORM migrations to JS for production runtime +# Compile TypeORM migrations to JS for production runtime and run migrations RUN npx tsc -p apps/spin-cycle/tsconfig.migrations.json +RUN npm run db:migrate:run + RUN cp -R dist/apps/spin-cycle-client dist/apps/spin-cycle/assets/ ENTRYPOINT ["node", "dist/apps/spin-cycle/main.js"] diff --git a/fly.toml b/fly.toml index 23369d7..23bb1a2 100644 --- a/fly.toml +++ b/fly.toml @@ -8,9 +8,6 @@ primary_region = 'ord' [build] -[deploy] - release_command = "npm run db:migrate:run" - [http_service] internal_port = 3000 force_https = true