mirror of
https://github.com/TheFunny/TelegramTwitterMediaBot.git
synced 2026-09-23 23:32:05 +00:00
- Replace the mtime-touch stub-rebuild hack with cargo clean -p (a future-dated host file could silently ship the stub binary) - Optional FFMPEG_SHA256 build arg verified before extraction - Drop the redundant libssl3/libcrypto copies and the root supplementary group; strip the release binary; add a webhook-mode healthcheck to the compose example
75 lines
1.8 KiB
Plaintext
75 lines
1.8 KiB
Plaintext
services:
|
|
nginx-proxy:
|
|
image: nginxproxy/nginx-proxy:1.11.6-alpine
|
|
restart: always
|
|
ports:
|
|
- '80:80'
|
|
- '443:443'
|
|
volumes:
|
|
- /var/run/docker.sock:/tmp/docker.sock:ro
|
|
- certs:/etc/nginx/certs:ro
|
|
- html:/usr/share/nginx/html:ro
|
|
networks: [proxy]
|
|
labels:
|
|
- 'com.github.nginx-proxy.nginx'
|
|
container_name: nginx-proxy
|
|
|
|
acme-companion:
|
|
image: nginxproxy/acme-companion
|
|
restart: always
|
|
environment:
|
|
DEFAULT_EMAIL: ''
|
|
volumes:
|
|
- /var/run/docker.sock:/var/run/docker.sock:ro
|
|
- certs:/etc/nginx/certs:rw
|
|
- html:/usr/share/nginx/html:rw
|
|
- acme:/etc/acme.sh
|
|
networks: [proxy]
|
|
container_name: acme-companion
|
|
depends_on:
|
|
- nginx-proxy
|
|
|
|
tgxmb:
|
|
image: yoursfunny/telegram-twitter-media-bot:latest
|
|
restart: always
|
|
environment:
|
|
LOCAL_USER_ID: '1000'
|
|
TELOXIDE_TOKEN: ''
|
|
BOT_ADMIN: ''
|
|
PIXIV_REFRESH_TOKEN: ''
|
|
TWITTER_AUTH_TOKEN: ''
|
|
EDIT_MESSAGE_TTL_SECONDS: '86400'
|
|
LINK_CACHE_TTL_SECONDS: '604800'
|
|
RUST_LOG: 'info'
|
|
VIRTUAL_HOST: '<YOUR_DOMAIN>'
|
|
VIRTUAL_PORT: '8443'
|
|
# ACME_HOST: 'your.domain.com'
|
|
WEBHOOK: 'true'
|
|
WEBHOOK_LISTEN: '0.0.0.0'
|
|
WEBHOOK_PORT: '8443'
|
|
WEBHOOK_URL: 'https://<YOUR_DOMAIN>/'
|
|
WEBHOOK_SECRET_TOKEN: ''
|
|
volumes:
|
|
- ./data:/app/data
|
|
networks: [proxy]
|
|
depends_on:
|
|
- nginx-proxy
|
|
container_name: tgxmb
|
|
# Webhook mode only: the bot listens on WEBHOOK_PORT; nginx-proxy shows
|
|
# 502s while this is down, so surface it to the orchestrator.
|
|
healthcheck:
|
|
test: ["CMD-SHELL", "bash -c 'exec 3<>/dev/tcp/127.0.0.1/8443'"]
|
|
interval: 30s
|
|
timeout: 5s
|
|
retries: 3
|
|
start_period: 10s
|
|
|
|
volumes:
|
|
certs:
|
|
html:
|
|
acme:
|
|
|
|
networks:
|
|
proxy:
|
|
name: proxy
|