📦 NEW: Added All Data Files
This commit is contained in:
157
docker-compose.yaml
Normal file
157
docker-compose.yaml
Normal file
@@ -0,0 +1,157 @@
|
||||
version: "2.1"
|
||||
services:
|
||||
postgres:
|
||||
restart: always
|
||||
image: "postgres:15.1-alpine"
|
||||
container_name: phoenixDB
|
||||
ports:
|
||||
- "5432:5432"
|
||||
environment:
|
||||
- DEBUG=false
|
||||
- POSTGRES_DB=phoenix
|
||||
- "POSTGRES_PASSWORD=${POSTGRES_PASSWORD}"
|
||||
volumes:
|
||||
- "db-data:/var/lib/postgresql/data"
|
||||
healthcheck:
|
||||
test:
|
||||
- CMD-SHELL
|
||||
- pg_isready -U postgres
|
||||
interval: 5s
|
||||
timeout: 2s
|
||||
retries: 5
|
||||
networks:
|
||||
- postgres
|
||||
pgadmin:
|
||||
restart: always
|
||||
image: dpage/pgadmin4
|
||||
container_name: pgadmin_container
|
||||
environment:
|
||||
PGADMIN_DEFAULT_EMAIL: "pgadmin4@pgadmin.org"
|
||||
PGADMIN_DEFAULT_PASSWORD: '${PGADMIN_DEFAULT_PASSWORD}'
|
||||
PGADMIN_CONFIG_SERVER_MODE: 'False'
|
||||
ports:
|
||||
- "${PGADMIN_PORT:-5050}:80"
|
||||
volumes:
|
||||
- "pgadmin:/var/lib/pgadmin"
|
||||
networks:
|
||||
- postgres
|
||||
phoenix-app:
|
||||
restart: always
|
||||
image: "dennx/phoenix-app:alpha"
|
||||
container_name: phoenixAppProd
|
||||
volumes:
|
||||
- "/opt/containers/phx/app_custom:/usr/share/nginx/html/assets/custom"
|
||||
- "/opt/containers/phx/nginx/nginx.conf:/etc/nginx/nginx.conf"
|
||||
# - phxnginx:/etc/nginx
|
||||
ports:
|
||||
- "8081:80"
|
||||
# - "443:443"
|
||||
labels:
|
||||
- "traefik.enable=true"
|
||||
- "traefik.http.routers.phxalpha.entrypoints=https"
|
||||
- "traefik.http.routers.phxalpha.rule=Host(`alpha.phx-erp.de`)"
|
||||
- "traefik.http.routers.phxalpha.middlewares=secHeaders@file"
|
||||
- "traefik.http.routers.phxalpha.tls=true"
|
||||
- "traefik.http.routers.phxalpha.tls.certresolver=http"
|
||||
- "traefik.http.routers.phxalpha.service=phxalpha"
|
||||
- "traefik.http.services.phxalpha.loadbalancer.server.port=80"
|
||||
- "traefik.docker.network=proxy"
|
||||
|
||||
- "traefik.http.routers.phxalpha-insecure.entrypoints=http"
|
||||
- "traefik.http.routers.phxalpha-insecure.rule=Host(`alpha.phx-erp.de`)"
|
||||
- "traefik.http.routers.phxalpha-insecure.tls=false"
|
||||
networks:
|
||||
- proxy
|
||||
- postgres
|
||||
depends_on:
|
||||
- phoenix-system
|
||||
phoenix-system:
|
||||
restart: always
|
||||
image: "dennx/phoenix-system:alpha"
|
||||
# container_name: phoenixSystemProd
|
||||
# env_file: .env
|
||||
environment:
|
||||
- DB_HOST=phoenixDB
|
||||
- "DB_PASSWORD=${POSTGRES_PASSWORD}"
|
||||
- DB_USERNAME=postgres
|
||||
- "SUPER_ADMIN_USER_PASSWORD=${SUPER_ADMIN_USER_PASSWORD}"
|
||||
- RUN_JOB_QUEUE=${RUN_JOB_QUEUE}
|
||||
- SMTP_TYPE=${SMTP_TYPE}
|
||||
- SMTP_NAME=${SMTP_NAME}
|
||||
- SMTP_HOST=${SMTP_HOST}
|
||||
- SMTP_PORT=${SMTP_PORT}
|
||||
- SMTP_SECURE=${SMTP_SECURE}
|
||||
- SMTP_USER=${SMTP_USER}
|
||||
- SMTP_PASS=${SMTP_PASS}
|
||||
- SMTP_LOGGING=${SMTP_LOGGING}
|
||||
- SMTP_DEBUG=${SMTP_DEBUG}
|
||||
- SMTP_TLS_REJECT_UNAUTHORIZED=${SMTP_TLS_REJECT_UNAUTHORIZED}
|
||||
- SMTP_SECURE_CONNECTION=${SMTP_SECURE_CONNECTION}
|
||||
- SMTP_IGNORE_TLS=${SMTP_IGNORE_TLS}
|
||||
- ENV_MODE=${ENV_MODE}
|
||||
command: ["npm", "run", "start:server"]
|
||||
# ports:
|
||||
# - "3000:3000"
|
||||
# - "3400:3400"
|
||||
# - "9615:9615"
|
||||
# - "587:587" # Email Port
|
||||
depends_on:
|
||||
postgres:
|
||||
condition: service_healthy
|
||||
volumes:
|
||||
- "asset-data:/usr/src/app/packages/dev-server/assets"
|
||||
- "/opt/containers/phx/server_custom:/usr/src/app/packages/dev-server/custom"
|
||||
networks:
|
||||
- postgres
|
||||
deploy:
|
||||
replicas: 2
|
||||
phoenix-worker:
|
||||
restart: always
|
||||
image: "dennx/phoenix-system:alpha"
|
||||
environment:
|
||||
- DB_HOST=phoenixDB
|
||||
- "DB_PASSWORD=${POSTGRES_PASSWORD}"
|
||||
- DB_USERNAME=postgres
|
||||
- "SUPER_ADMIN_USER_PASSWORD=${SUPER_ADMIN_USER_PASSWORD}"
|
||||
- REDIS_PASSWORD=${REDIS_PASSWORD}
|
||||
command: ["npm", "run", "start:worker"]
|
||||
depends_on:
|
||||
postgres:
|
||||
condition: service_healthy
|
||||
volumes:
|
||||
# - "/opt/containers/phx/assets:/usr/src/app/packages/dev-server/custo/assets"
|
||||
# - "asset-data:/usr/src/app/packages/dev-server/assets"
|
||||
- "/opt/containers/phx/server_custom:/usr/src/app/packages/dev-server/custom"
|
||||
networks:
|
||||
- postgres
|
||||
|
||||
phoenix-redis:
|
||||
image: 'bitnami/redis:latest'
|
||||
container_name: redis
|
||||
#command: redis-server --save 20 1 --appendonly no --requirepass ${REDIS_PASSWORD} --loglevel warning
|
||||
command: /opt/bitnami/scripts/redis/run.sh --maxmemory 100mb
|
||||
user: root
|
||||
# privileged: true
|
||||
# ports:
|
||||
# - 6379:6379
|
||||
restart: always
|
||||
environment:
|
||||
# REDIS_APPENDFSYNC: "always"
|
||||
ALLOW_EMPTY_PASSWORD: "no"
|
||||
# REDIS_DISABLE_COMMANDS: FLUSHDB,FLUSHALL,CONFIG
|
||||
REDIS_PASSWORD: ${REDIS_PASSWORD}
|
||||
networks:
|
||||
- postgres
|
||||
volumes:
|
||||
- /opt/containers/phx/redis/data:/bitnami/redis/data
|
||||
volumes:
|
||||
db-data: null
|
||||
app-data: null
|
||||
asset-data: null
|
||||
pgadmin: null
|
||||
|
||||
networks:
|
||||
postgres:
|
||||
driver: bridge
|
||||
proxy:
|
||||
external: true
|
||||
Reference in New Issue
Block a user