Skip to content

Commit

Permalink
changing startup script to run latest migrations
Browse files Browse the repository at this point in the history
  • Loading branch information
mikefranze committed Nov 4, 2023
1 parent 4cc48f4 commit a4e4377
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,6 @@ COPY --chown=node:node --from=build /usr/src/app/domain_model domain_model
COPY --chown=node:node --from=build /usr/src/app/frontend/build /usr/src/app/frontend/build
COPY --chown=node:node --from=build /usr/src/app/backend/build /usr/src/app/backend/build
COPY --chown=node:node --from=build /usr/src/app/backend/node_modules /usr/src/app/backend/node_modules
CMD ["dumb-init", "node", "backend/build/backend/src/index.js"]

ENTRYPOINT ["dumb-init", "--"]
CMD ["npm", "run", "start"]
EXPOSE 5000
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
"main": "index.js",
"scripts": {
"test": "cd backend && npm install && npm test",
"start": "cd backend && npm start",
"start": "node ./backend/build/backend/src/migrate-to-latest.js && node ./backend/build/backend/src/index.js",
"heroku-postbuild": "cd frontend && npm install && npm run build && cd ../backend && npm install"
},
"repository": {
Expand Down

0 comments on commit a4e4377

Please sign in to comment.