Skip to content

Commit

Permalink
move docker-compose command to spearate script for local run
Browse files Browse the repository at this point in the history
  • Loading branch information
przemek-nowicki committed Oct 13, 2023
1 parent 0257dc8 commit a0f263d
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 1 deletion.
2 changes: 2 additions & 0 deletions Dev.Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -11,4 +11,6 @@ RUN npm install

COPY . .

RUN chmod +x /app/scripts/docker/local-run.sh

EXPOSE 8080
2 changes: 1 addition & 1 deletion docker-compose.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ services:
build:
context: .
dockerfile: Dev.Dockerfile
command: 'npm run server:dev'
command: '/app/scripts/docker/local-run.sh'
ports:
- '8080:8080'
- '9229:9229'
Expand Down
4 changes: 4 additions & 0 deletions scripts/docker/local-run.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
#!/bin/sh

echo "Running server in development mode"
npm run server:dev || exit 1

0 comments on commit a0f263d

Please sign in to comment.