cicd 11
Some checks failed
Build and Deploy / build-and-deploy (push) Failing after 1m17s

This commit is contained in:
Gal Podlipnik 2025-06-12 16:55:06 +02:00
parent 2d8ea729de
commit 541065bb2c

View File

@ -54,40 +54,40 @@ jobs:
- name: Create docker-compose.yml - name: Create docker-compose.yml
run: | run: |
cat > docker-compose.yml << 'EOL' cat > docker-compose.yml << 'EOL'
services: services:
backend: backend:
image: harbor.galpodlipnik.com/chat-app/backend:latest image: harbor.galpodlipnik.com/chat-app/backend:latest
restart: always restart: always
# Instead of env_file, define the environment variables directly # Instead of env_file, define the environment variables directly
environment: environment:
- NODE_ENV=production - NODE_ENV=production
- PORT=3000 - PORT=3000
- CORS_ORIGIN=http://localhost:5173 - CORS_ORIGIN=http://localhost:5173
- DATABASE_URL=${DATABASE_URL} - DATABASE_URL=${DATABASE_URL}
- JWT_SECRET=${JWT_SECRET} - JWT_SECRET=${JWT_SECRET}
networks: networks:
- chat-network - chat-network
healthcheck: healthcheck:
test: ["CMD", "wget", "-qO-", "http://localhost:3000/health"] test: ["CMD", "wget", "-qO-", "http://localhost:3000/health"]
interval: 10s interval: 10s
timeout: 5s timeout: 5s
retries: 5 retries: 5
frontend: frontend:
image: harbor.galpodlipnik.com/chat-app/frontend:latest image: harbor.galpodlipnik.com/chat-app/frontend:latest
restart: always restart: always
ports: ports:
- "5173:80" - "5173:80"
depends_on: depends_on:
backend: backend:
condition: service_healthy condition: service_healthy
networks: networks:
- chat-network - chat-network
networks: networks:
chat-network: chat-network:
driver: bridge driver: bridge
EOL EOL
- name: Deploy with SSH - name: Deploy with SSH
uses: appleboy/ssh-action@master uses: appleboy/ssh-action@master