Skip to content

Commit

Permalink
Update Docker CMD and add nodemon for development in package.json
Browse files Browse the repository at this point in the history
  • Loading branch information
nlisgo committed Nov 7, 2024
1 parent b52e7dd commit d5235e3
Show file tree
Hide file tree
Showing 4 changed files with 831 additions and 21 deletions.
2 changes: 1 addition & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ COPY package.json package.json
COPY src/ src/

EXPOSE 3000
CMD [ "yarn", "start:dev" ]
CMD [ "yarn", "start" ]

FROM prod AS dev
CMD [ "yarn", "start:dev" ]
2 changes: 2 additions & 0 deletions docker-compose.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -11,3 +11,5 @@ services:
start_period: 5s
ports:
- 3000:5000
volumes:
- ./src:/opt/epp/src
4 changes: 3 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@
"eslint-plugin-import": "^2.31.0",
"eslint-plugin-no-only-tests": "^3.3.0",
"globals": "^15.12.0",
"nodemon": "^3.1.7",
"ts-node": "^10.9.2",
"typescript": "^5.6.3",
"typescript-eslint": "^8.13.0"
Expand All @@ -25,7 +26,8 @@
"express": "^4.21.1"
},
"scripts": {
"start:dev": "ts-node ./src/main.ts",
"start": "ts-node ./src/main.ts",
"start:dev": "nodemon ./src/main.ts",
"lint": "eslint --ext .ts src/"
}
}
Loading

0 comments on commit d5235e3

Please sign in to comment.