2020-02-18 23:55:06 -05:00
|
|
|
# WARNING: This is a DEVELOPMENT docker-compose file, it should not be used for production.
|
|
|
|
services:
|
2023-03-21 19:41:59 -04:00
|
|
|
|
2024-10-15 09:54:39 -04:00
|
|
|
fullstack:
|
2024-12-23 17:57:54 -05:00
|
|
|
image: npm2dev:core
|
|
|
|
container_name: npm2dev.core
|
2020-02-18 23:55:06 -05:00
|
|
|
build:
|
|
|
|
context: ./
|
|
|
|
dockerfile: ./dev/Dockerfile
|
|
|
|
ports:
|
|
|
|
- 3080:80
|
|
|
|
- 3081:81
|
|
|
|
- 3443:443
|
2020-10-06 09:16:45 -04:00
|
|
|
networks:
|
2024-10-13 07:54:58 -04:00
|
|
|
nginx_proxy_manager:
|
|
|
|
aliases:
|
|
|
|
- website1.example.com
|
|
|
|
- website2.example.com
|
|
|
|
- website3.example.com
|
2020-02-18 23:55:06 -05:00
|
|
|
environment:
|
2023-03-20 02:56:52 -04:00
|
|
|
PUID: 1000
|
|
|
|
PGID: 1000
|
2020-11-07 07:24:01 -05:00
|
|
|
FORCE_COLOR: 1
|
2023-03-21 02:53:39 -04:00
|
|
|
# specifically for dev:
|
|
|
|
DEBUG: 'true'
|
|
|
|
DEVELOPMENT: 'true'
|
|
|
|
LE_STAGING: 'true'
|
|
|
|
# db:
|
2024-12-23 17:57:54 -05:00
|
|
|
# DB_MYSQL_HOST: 'db'
|
|
|
|
# DB_MYSQL_PORT: '3306'
|
|
|
|
# DB_MYSQL_USER: 'npm'
|
|
|
|
# DB_MYSQL_PASSWORD: 'npm'
|
|
|
|
# DB_MYSQL_NAME: 'npm'
|
|
|
|
# db-postgres:
|
|
|
|
DB_POSTGRES_HOST: 'db-postgres'
|
|
|
|
DB_POSTGRES_PORT: '5432'
|
|
|
|
DB_POSTGRES_USER: 'npm'
|
|
|
|
DB_POSTGRES_PASSWORD: 'npmpass'
|
|
|
|
DB_POSTGRES_NAME: 'npm'
|
2020-11-07 07:24:01 -05:00
|
|
|
# DB_SQLITE_FILE: "/data/database.sqlite"
|
|
|
|
# DISABLE_IPV6: "true"
|
2024-10-15 21:06:29 -04:00
|
|
|
# Required for DNS Certificate provisioning testing:
|
|
|
|
LE_SERVER: 'https://ca.internal/acme/acme/directory'
|
|
|
|
REQUESTS_CA_BUNDLE: '/etc/ssl/certs/NginxProxyManager.crt'
|
2020-02-18 23:55:06 -05:00
|
|
|
volumes:
|
|
|
|
- npm_data:/data
|
|
|
|
- le_data:/etc/letsencrypt
|
2024-10-15 21:06:29 -04:00
|
|
|
- './dev/resolv.conf:/etc/resolv.conf:ro'
|
2020-10-08 07:38:20 -04:00
|
|
|
- ../backend:/app
|
|
|
|
- ../frontend:/app/frontend
|
|
|
|
- ../global:/app/global
|
2024-10-15 21:06:29 -04:00
|
|
|
healthcheck:
|
|
|
|
test: ["CMD", "/usr/bin/check-health"]
|
|
|
|
interval: 10s
|
|
|
|
timeout: 3s
|
2020-02-18 23:55:06 -05:00
|
|
|
depends_on:
|
|
|
|
- db
|
2024-12-23 17:57:54 -05:00
|
|
|
- db-postgres
|
|
|
|
- authentik
|
|
|
|
- authentik-worker
|
|
|
|
- authentik-ldap
|
2020-02-18 23:55:06 -05:00
|
|
|
working_dir: /app
|
|
|
|
|
|
|
|
db:
|
|
|
|
image: jc21/mariadb-aria
|
2024-12-23 17:57:54 -05:00
|
|
|
container_name: npm2dev.db
|
2021-11-02 06:33:22 -04:00
|
|
|
ports:
|
|
|
|
- 33306:3306
|
2020-10-06 09:16:45 -04:00
|
|
|
networks:
|
|
|
|
- nginx_proxy_manager
|
2020-02-18 23:55:06 -05:00
|
|
|
environment:
|
2023-03-21 02:53:39 -04:00
|
|
|
MYSQL_ROOT_PASSWORD: 'npm'
|
|
|
|
MYSQL_DATABASE: 'npm'
|
|
|
|
MYSQL_USER: 'npm'
|
|
|
|
MYSQL_PASSWORD: 'npm'
|
2020-02-18 23:55:06 -05:00
|
|
|
volumes:
|
|
|
|
- db_data:/var/lib/mysql
|
|
|
|
|
2024-12-23 17:57:54 -05:00
|
|
|
db-postgres:
|
|
|
|
image: postgres:latest
|
|
|
|
container_name: npm2dev.db-postgres
|
|
|
|
networks:
|
|
|
|
- nginx_proxy_manager
|
|
|
|
environment:
|
|
|
|
POSTGRES_USER: 'npm'
|
|
|
|
POSTGRES_PASSWORD: 'npmpass'
|
|
|
|
POSTGRES_DB: 'npm'
|
|
|
|
volumes:
|
|
|
|
- psql_data:/var/lib/postgresql/data
|
|
|
|
- ./ci/postgres:/docker-entrypoint-initdb.d
|
|
|
|
|
2024-10-15 21:06:29 -04:00
|
|
|
stepca:
|
|
|
|
image: jc21/testca
|
2024-12-23 17:57:54 -05:00
|
|
|
container_name: npm2dev.stepca
|
2024-10-15 21:06:29 -04:00
|
|
|
volumes:
|
|
|
|
- './dev/resolv.conf:/etc/resolv.conf:ro'
|
|
|
|
- '/etc/localtime:/etc/localtime:ro'
|
|
|
|
networks:
|
|
|
|
nginx_proxy_manager:
|
|
|
|
aliases:
|
|
|
|
- ca.internal
|
|
|
|
|
|
|
|
dnsrouter:
|
|
|
|
image: jc21/dnsrouter
|
2024-12-23 17:57:54 -05:00
|
|
|
container_name: npm2dev.dnsrouter
|
2024-10-15 21:06:29 -04:00
|
|
|
volumes:
|
|
|
|
- ./dev/dnsrouter-config.json.tmp:/dnsrouter-config.json:ro
|
|
|
|
networks:
|
|
|
|
- nginx_proxy_manager
|
|
|
|
|
2024-10-09 04:05:15 -04:00
|
|
|
swagger:
|
|
|
|
image: swaggerapi/swagger-ui:latest
|
2024-12-23 17:57:54 -05:00
|
|
|
container_name: npm2dev.swagger
|
2024-10-09 04:05:15 -04:00
|
|
|
ports:
|
|
|
|
- 3082:80
|
|
|
|
environment:
|
|
|
|
URL: "http://npm:81/api/schema"
|
|
|
|
PORT: '80'
|
|
|
|
depends_on:
|
2024-10-15 09:54:39 -04:00
|
|
|
- fullstack
|
2024-10-09 04:05:15 -04:00
|
|
|
|
2024-10-13 07:54:58 -04:00
|
|
|
squid:
|
|
|
|
image: ubuntu/squid
|
2024-12-23 17:57:54 -05:00
|
|
|
container_name: npm2dev.squid
|
2024-10-13 07:54:58 -04:00
|
|
|
volumes:
|
|
|
|
- './dev/squid.conf:/etc/squid/squid.conf:ro'
|
2024-10-15 21:06:29 -04:00
|
|
|
- './dev/resolv.conf:/etc/resolv.conf:ro'
|
2024-10-13 07:54:58 -04:00
|
|
|
- '/etc/localtime:/etc/localtime:ro'
|
|
|
|
networks:
|
|
|
|
- nginx_proxy_manager
|
|
|
|
ports:
|
|
|
|
- 8128:3128
|
|
|
|
|
2024-10-15 21:06:29 -04:00
|
|
|
pdns:
|
|
|
|
image: pschiffe/pdns-mysql
|
2024-12-23 17:57:54 -05:00
|
|
|
container_name: npm2dev.pdns
|
2024-10-15 21:06:29 -04:00
|
|
|
volumes:
|
|
|
|
- '/etc/localtime:/etc/localtime:ro'
|
|
|
|
environment:
|
|
|
|
PDNS_master: 'yes'
|
|
|
|
PDNS_api: 'yes'
|
|
|
|
PDNS_api_key: 'npm'
|
|
|
|
PDNS_webserver: 'yes'
|
|
|
|
PDNS_webserver_address: '0.0.0.0'
|
|
|
|
PDNS_webserver_password: 'npm'
|
|
|
|
PDNS_webserver-allow-from: '127.0.0.0/8,192.0.0.0/8,10.0.0.0/8,172.0.0.0/8'
|
|
|
|
PDNS_version_string: 'anonymous'
|
|
|
|
PDNS_default_ttl: 1500
|
|
|
|
PDNS_allow_axfr_ips: '127.0.0.0/8,192.0.0.0/8,10.0.0.0/8,172.0.0.0/8'
|
|
|
|
PDNS_gmysql_host: pdns-db
|
|
|
|
PDNS_gmysql_port: 3306
|
|
|
|
PDNS_gmysql_user: pdns
|
|
|
|
PDNS_gmysql_password: pdns
|
|
|
|
PDNS_gmysql_dbname: pdns
|
|
|
|
depends_on:
|
|
|
|
- pdns-db
|
|
|
|
networks:
|
|
|
|
nginx_proxy_manager:
|
|
|
|
aliases:
|
|
|
|
- ns1.pdns
|
|
|
|
- ns2.pdns
|
|
|
|
|
|
|
|
pdns-db:
|
|
|
|
image: mariadb
|
2024-12-23 17:57:54 -05:00
|
|
|
container_name: npm2dev.pdns-db
|
2024-10-15 21:06:29 -04:00
|
|
|
environment:
|
|
|
|
MYSQL_ROOT_PASSWORD: 'pdns'
|
|
|
|
MYSQL_DATABASE: 'pdns'
|
|
|
|
MYSQL_USER: 'pdns'
|
|
|
|
MYSQL_PASSWORD: 'pdns'
|
|
|
|
volumes:
|
|
|
|
- 'pdns_mysql:/var/lib/mysql'
|
|
|
|
- '/etc/localtime:/etc/localtime:ro'
|
|
|
|
- './dev/pdns-db.sql:/docker-entrypoint-initdb.d/01_init.sql:ro'
|
|
|
|
networks:
|
|
|
|
- nginx_proxy_manager
|
|
|
|
|
|
|
|
cypress:
|
2024-12-23 17:57:54 -05:00
|
|
|
image: npm2dev:cypress
|
|
|
|
container_name: npm2dev.cypress
|
2024-10-15 21:06:29 -04:00
|
|
|
build:
|
|
|
|
context: ../
|
|
|
|
dockerfile: test/cypress/Dockerfile
|
|
|
|
environment:
|
|
|
|
HTTP_PROXY: 'squid:3128'
|
|
|
|
HTTPS_PROXY: 'squid:3128'
|
|
|
|
volumes:
|
|
|
|
- '../test/results:/results'
|
|
|
|
- './dev/resolv.conf:/etc/resolv.conf:ro'
|
|
|
|
- '/etc/localtime:/etc/localtime:ro'
|
|
|
|
command: cypress run --browser chrome --config-file=cypress/config/ci.js
|
|
|
|
networks:
|
|
|
|
- nginx_proxy_manager
|
|
|
|
|
2024-12-23 17:57:54 -05:00
|
|
|
authentik-redis:
|
|
|
|
image: 'redis:alpine'
|
|
|
|
container_name: npm2dev.authentik-redis
|
|
|
|
command: --save 60 1 --loglevel warning
|
|
|
|
networks:
|
|
|
|
- nginx_proxy_manager
|
|
|
|
restart: unless-stopped
|
|
|
|
healthcheck:
|
|
|
|
test: ['CMD-SHELL', 'redis-cli ping | grep PONG']
|
|
|
|
start_period: 20s
|
|
|
|
interval: 30s
|
|
|
|
retries: 5
|
|
|
|
timeout: 3s
|
|
|
|
volumes:
|
|
|
|
- redis_data:/data
|
|
|
|
|
|
|
|
authentik:
|
|
|
|
image: ghcr.io/goauthentik/server:2024.10.1
|
|
|
|
container_name: npm2dev.authentik
|
|
|
|
restart: unless-stopped
|
|
|
|
command: server
|
|
|
|
networks:
|
|
|
|
- nginx_proxy_manager
|
|
|
|
env_file:
|
|
|
|
- ci.env
|
2024-12-24 03:19:52 -05:00
|
|
|
ports:
|
|
|
|
- 9000:9000
|
2024-12-23 17:57:54 -05:00
|
|
|
depends_on:
|
|
|
|
- authentik-redis
|
|
|
|
- db-postgres
|
|
|
|
|
|
|
|
authentik-worker:
|
|
|
|
image: ghcr.io/goauthentik/server:2024.10.1
|
|
|
|
container_name: npm2dev.authentik-worker
|
|
|
|
restart: unless-stopped
|
|
|
|
command: worker
|
|
|
|
networks:
|
|
|
|
- nginx_proxy_manager
|
|
|
|
env_file:
|
|
|
|
- ci.env
|
|
|
|
depends_on:
|
|
|
|
- authentik-redis
|
|
|
|
- db-postgres
|
|
|
|
|
|
|
|
authentik-ldap:
|
|
|
|
image: ghcr.io/goauthentik/ldap:2024.10.1
|
|
|
|
container_name: npm2dev.authentik-ldap
|
|
|
|
networks:
|
|
|
|
- nginx_proxy_manager
|
|
|
|
environment:
|
|
|
|
AUTHENTIK_HOST: 'http://authentik:9000'
|
|
|
|
AUTHENTIK_INSECURE: 'true'
|
|
|
|
AUTHENTIK_TOKEN: 'wKYZuRcI0ETtb8vWzMCr04oNbhrQUUICy89hSpDln1OEKLjiNEuQ51044Vkp'
|
|
|
|
restart: unless-stopped
|
|
|
|
depends_on:
|
|
|
|
- authentik
|
|
|
|
|
2020-02-18 23:55:06 -05:00
|
|
|
volumes:
|
|
|
|
npm_data:
|
2024-12-23 17:57:54 -05:00
|
|
|
name: npm2dev_core_data
|
2020-02-18 23:55:06 -05:00
|
|
|
le_data:
|
2024-12-23 17:57:54 -05:00
|
|
|
name: npm2dev_le_data
|
2020-02-18 23:55:06 -05:00
|
|
|
db_data:
|
2024-12-23 17:57:54 -05:00
|
|
|
name: npm2dev_db_data
|
2024-10-15 21:06:29 -04:00
|
|
|
pdns_mysql:
|
2024-12-23 17:57:54 -05:00
|
|
|
name: npnpm2dev_pdns_mysql
|
|
|
|
psql_data:
|
|
|
|
name: npm2dev_psql_data
|
|
|
|
redis_data:
|
|
|
|
name: npm2dev_redis_data
|
2020-10-06 09:16:45 -04:00
|
|
|
|
|
|
|
networks:
|
|
|
|
nginx_proxy_manager:
|
2024-12-23 17:57:54 -05:00
|
|
|
name: npm2dev_network
|