Update docker-compose.yml
This commit is contained in:
parent
41126309f8
commit
b4356f1182
@ -1,38 +1,40 @@
|
|||||||
version: "3.8"
|
version: "3.8"
|
||||||
|
|
||||||
services:
|
services:
|
||||||
bot:
|
bot:
|
||||||
build: .
|
build: .
|
||||||
container_name: discord-lnbits-bot
|
container_name: discord-lnbits-bot
|
||||||
env_file:
|
env_file:
|
||||||
- ./data/secrets/runtime.env
|
- .env
|
||||||
depends_on:
|
depends_on:
|
||||||
- db
|
db:
|
||||||
command: python discord_lnbits_bot.py
|
condition: service_healthy
|
||||||
restart: unless-stopped
|
restart: unless-stopped
|
||||||
|
|
||||||
web:
|
web:
|
||||||
build: .
|
build: .
|
||||||
container_name: discord-lnbits-web
|
container_name: discord-lnbits-web
|
||||||
env_file:
|
env_file:
|
||||||
- ./data/secrets/runtime.env
|
- .env
|
||||||
|
depends_on:
|
||||||
|
db:
|
||||||
|
condition: service_healthy
|
||||||
ports:
|
ports:
|
||||||
- "3000:3000"
|
- "3000:3000"
|
||||||
depends_on:
|
|
||||||
- db
|
|
||||||
command: gunicorn -b 0.0.0.0:3000 app:app
|
command: gunicorn -b 0.0.0.0:3000 app:app
|
||||||
restart: unless-stopped
|
restart: unless-stopped
|
||||||
|
|
||||||
db:
|
db:
|
||||||
image: postgres:15-alpine
|
image: postgres:15-alpine
|
||||||
container_name: lnbits_db
|
container_name: lnbits_db
|
||||||
environment:
|
env_file:
|
||||||
POSTGRES_USER: postgres
|
- .env
|
||||||
POSTGRES_PASSWORD: ${DB_PASS}
|
|
||||||
POSTGRES_DB: lnbitsdb
|
|
||||||
volumes:
|
volumes:
|
||||||
- dbdata:/var/lib/postgresql/data
|
- postgres_data:/var/lib/postgresql/data
|
||||||
|
healthcheck:
|
||||||
|
test: ["CMD-SHELL", "pg_isready -U ${DB_USER} -d ${DB_NAME}"]
|
||||||
|
interval: 10s
|
||||||
|
retries: 5
|
||||||
restart: unless-stopped
|
restart: unless-stopped
|
||||||
|
|
||||||
volumes:
|
volumes:
|
||||||
dbdata:
|
postgres_data:
|
||||||
|
Loading…
x
Reference in New Issue
Block a user