mirror of
https://github.com/MHSanaei/3x-ui.git
synced 2026-04-14 19:45:47 +00:00
- Add SQLite/PostgreSQL switching via panel UI and env variables - Introduce portable .xui-backup format for cross-backend backups - Add connection pooling and PrepareStmt cache for PostgreSQL - Fix raw SQL double-quote bug breaking queries on PostgreSQL - Fix GORM record-not-found log spam on every Xray config poll - Add database section to Settings with full EN/RU i18n
41 lines
980 B
YAML
41 lines
980 B
YAML
services:
|
|
3xui:
|
|
build:
|
|
context: .
|
|
dockerfile: ./Dockerfile
|
|
container_name: 3xui_app
|
|
# hostname: yourhostname <- optional
|
|
volumes:
|
|
- $PWD/db/:/etc/x-ui/
|
|
- $PWD/cert/:/root/cert/
|
|
environment:
|
|
XRAY_VMESS_AEAD_FORCED: "false"
|
|
XUI_ENABLE_FAIL2BAN: "true"
|
|
# XUI_DB_DRIVER: "postgres"
|
|
# XUI_DB_MODE: "external"
|
|
# XUI_DB_HOST: "127.0.0.1"
|
|
# XUI_DB_PORT: "5432"
|
|
# XUI_DB_NAME: "xui"
|
|
# XUI_DB_USER: "xui"
|
|
# XUI_DB_PASSWORD: "change-me"
|
|
# XUI_DB_SSLMODE: "disable"
|
|
tty: true
|
|
network_mode: host
|
|
restart: unless-stopped
|
|
depends_on:
|
|
- postgres
|
|
postgres:
|
|
image: postgres:17-alpine
|
|
container_name: 3xui_postgres
|
|
environment:
|
|
POSTGRES_DB: xui
|
|
POSTGRES_USER: xui
|
|
POSTGRES_PASSWORD: change-me
|
|
volumes:
|
|
- postgres_data:/var/lib/postgresql/data
|
|
ports:
|
|
- "5432:5432"
|
|
restart: unless-stopped
|
|
|
|
volumes:
|
|
postgres_data:
|