mirror of
https://litchi.icu/ngc2207/judge4c-docker-compose.git
synced 2025-05-18 09:56:34 +00:00
static ip & nextjs development
This commit is contained in:
parent
f3105b8cac
commit
299dfd7ff8
@ -2,6 +2,10 @@ networks:
|
||||
judge4c-network:
|
||||
name: judge4c-network
|
||||
driver: bridge
|
||||
ipam:
|
||||
config:
|
||||
- subnet: 172.20.0.0/16
|
||||
gateway: 172.20.0.1
|
||||
|
||||
volumes:
|
||||
judge4c-gitea-vol:
|
||||
@ -21,7 +25,8 @@ services:
|
||||
POSTGRES_DB: ${POSTGRES_DB}
|
||||
restart: always
|
||||
networks:
|
||||
- judge4c-network
|
||||
judge4c-network:
|
||||
ipv4_address: 172.20.0.10
|
||||
volumes:
|
||||
- judge4c-postgres-vol:/var/lib/postgresql/data
|
||||
healthcheck:
|
||||
@ -35,13 +40,14 @@ services:
|
||||
container_name: judge4c-gitea
|
||||
environment:
|
||||
DB_TYPE: postgres
|
||||
DB_HOST: judge4c-postgres:5432
|
||||
DB_HOST: 172.20.0.10
|
||||
DB_NAME: ${POSTGRES_DB}
|
||||
DB_USER: ${POSTGRES_USER}
|
||||
DB_PASSWD: ${POSTGRES_PASSWORD}
|
||||
restart: always
|
||||
networks:
|
||||
- judge4c-network
|
||||
judge4c-network:
|
||||
ipv4_address: 172.20.0.11
|
||||
volumes:
|
||||
- judge4c-gitea-vol:/data
|
||||
- /etc/timezone:/etc/timezone:ro
|
||||
@ -49,3 +55,35 @@ services:
|
||||
depends_on:
|
||||
judge4c-postgres:
|
||||
condition: service_healthy
|
||||
|
||||
judge4c-nextjs:
|
||||
image: oven/bun:canary
|
||||
container_name: judge4c-nextjs
|
||||
working_dir: /app
|
||||
environment:
|
||||
NODE_ENV: production
|
||||
POSTGRES_USER: ${POSTGRES_USER}
|
||||
POSTGRES_PASSWORD: ${POSTGRES_PASSWORD}
|
||||
POSTGRES_DB: ${POSTGRES_DB}
|
||||
AUTH_URL: ${AUTH_URL}
|
||||
AUTH_SECRET: ${AUTH_SECRET}
|
||||
AUTH_GITEA_URL: ${AUTH_GITEA_URL}
|
||||
AUTH_GITEA_ID: ${0d37fbf9-c075-4aba-9473-876a7e537135}
|
||||
AUTH_GITEA_SECRET: ${gto_jfbp3fncw4bpw5brq4tmtfx4lyxdnpa3eo642ujg3adedbazasiq}
|
||||
networks:
|
||||
judge4c-network:
|
||||
ipv4_address: 172.20.0.12
|
||||
volumes:
|
||||
- /home/ngc/Documents/judge4c:/app
|
||||
command:
|
||||
- bash
|
||||
- -c
|
||||
- |
|
||||
rm -rf /app/.next
|
||||
rm -rf /app/cache
|
||||
bun run build
|
||||
bun next telemetry disable
|
||||
bun run start
|
||||
depends_on:
|
||||
- judge4c-postgres
|
||||
- judge4c-gitea
|
Loading…
Reference in New Issue
Block a user