Add PostgreSQL, user/squad management, remove private domains from docs
This commit is contained in:
+23
-2
@@ -1,4 +1,20 @@
|
||||
services:
|
||||
db:
|
||||
image: postgres:16-alpine
|
||||
container_name: tgvpn-db
|
||||
restart: unless-stopped
|
||||
environment:
|
||||
POSTGRES_USER: tgvpn
|
||||
POSTGRES_PASSWORD: tgvpn
|
||||
POSTGRES_DB: tgvpn
|
||||
volumes:
|
||||
- pgdata:/var/lib/postgresql/data
|
||||
healthcheck:
|
||||
test: ["CMD-SHELL", "pg_isready -U tgvpn -d tgvpn"]
|
||||
interval: 5s
|
||||
timeout: 5s
|
||||
retries: 5
|
||||
|
||||
bot:
|
||||
build:
|
||||
context: .
|
||||
@@ -6,9 +22,14 @@ services:
|
||||
image: tgvpn-bot:latest
|
||||
container_name: tgvpn-bot
|
||||
restart: unless-stopped
|
||||
depends_on:
|
||||
db:
|
||||
condition: service_healthy
|
||||
env_file:
|
||||
- .env
|
||||
environment:
|
||||
BOT_DEBUG: ${BOT_DEBUG:-false}
|
||||
# Long polling — исходящие HTTPS к api.telegram.org
|
||||
# ports не нужны, пока нет webhook
|
||||
DATABASE_URL: postgres://tgvpn:tgvpn@db:5432/tgvpn?sslmode=disable
|
||||
|
||||
volumes:
|
||||
pgdata:
|
||||
|
||||
Reference in New Issue
Block a user