chore(docker-compose.prod.yml): use strapi-shared-network only

This commit is contained in:
Artur
2024-12-03 15:01:54 -03:00
parent ef511b3b61
commit 120dff935d

View File

@@ -1,5 +1,5 @@
services: services:
cloudflared: strapi-cloudflared:
image: cloudflare/cloudflared:latest image: cloudflare/cloudflared:latest
container_name: strapi-cloudflared container_name: strapi-cloudflared
restart: unless-stopped restart: unless-stopped
@@ -8,18 +8,18 @@ services:
TUNNEL_TOKEN: ${CLOUDFLARE_TUNNEL_TOKEN} TUNNEL_TOKEN: ${CLOUDFLARE_TUNNEL_TOKEN}
REAL_IP_HEADER: Cf-Connecting-Ip REAL_IP_HEADER: Cf-Connecting-Ip
networks: networks:
- internal - strapi-shared-network
depends_on: depends_on:
- nginx - strapi-nginx
nginx: strapi-nginx:
image: nginx:1 image: nginx:1
container_name: strapi-nginx container_name: strapi-nginx
restart: unless-stopped restart: unless-stopped
volumes: volumes:
- ./nginx.conf:/etc/nginx/nginx.conf - ./nginx.conf:/etc/nginx/nginx.conf
networks: networks:
- internal - strapi-shared-network
depends_on: depends_on:
- strapi - strapi
@@ -57,12 +57,11 @@ services:
- ./package-lock.json:/opt/package-lock.json - ./package-lock.json:/opt/package-lock.json
- ./public/uploads:/opt/app/public/uploads - ./public/uploads:/opt/app/public/uploads
networks: networks:
- internal
- strapi-shared-network - strapi-shared-network
depends_on: depends_on:
- postgres - strapi-postgres
postgres: strapi-postgres:
container_name: strapi-postgres container_name: strapi-postgres
image: postgres:16-alpine image: postgres:16-alpine
restart: unless-stopped restart: unless-stopped
@@ -72,12 +71,12 @@ services:
POSTGRES_PASSWORD: ${DATABASE_PASSWORD} POSTGRES_PASSWORD: ${DATABASE_PASSWORD}
volumes: volumes:
- "strapi_postgres_data:/var/lib/postgresql/data" - "strapi_postgres_data:/var/lib/postgresql/data"
networks:
- strapi-shared-network
volumes: volumes:
strapi_postgres_data: strapi_postgres_data:
networks: networks:
internal:
driver: bridge
strapi-shared-network: strapi-shared-network:
external: true external: true