chore(docker): add healthcheck to service in docker-compose.yml and update deploy workflow to include docker compose down
This commit is contained in:
parent
ae0e7cc1a7
commit
8b0f93bf23
1
.github/workflows/deploy.yml
vendored
1
.github/workflows/deploy.yml
vendored
@ -98,5 +98,6 @@ jobs:
|
||||
cd /home/${{ secrets.VPS_USER }}/zapishis && \
|
||||
docker login -u ${{ secrets.DOCKERHUB_USERNAME }} -p ${{ secrets.DOCKERHUB_TOKEN }} && \
|
||||
docker compose pull && \
|
||||
docker compose down && \
|
||||
docker compose up -d
|
||||
"
|
||||
|
||||
@ -4,6 +4,11 @@ services:
|
||||
env_file:
|
||||
- .env
|
||||
restart: always
|
||||
healthcheck:
|
||||
test: ["CMD", "curl", "-f", "http://localhost:3000/"]
|
||||
interval: 10s
|
||||
timeout: 3s
|
||||
retries: 5
|
||||
# ports:
|
||||
# - 3000:3000
|
||||
networks:
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user