0
0
opnxng-deploy-playbook/templates/compose/teddit.yaml.j2

72 lines
1.8 KiB
Plaintext
Raw Normal View History

2023-11-06 10:39:27 +08:00
# {{ ansible_managed }}
version: '3.7'
services:
teddit-warp:
image: caomingjun/warp
container_name: teddit-warp
restart: always
environment:
- WARP_SLEEP=2
cap_add:
- NET_ADMIN
sysctls:
- net.ipv6.conf.all.disable_ipv6=0
- net.ipv4.conf.all.src_valid_mark=1
volumes:
- {{ docker_dir }}/teddit:/var/lib/cloudflare-warp
ports:
- 8881:8080
- 6379:6379
networks:
- teddit
2023-11-06 10:39:27 +08:00
teddit:
container_name: teddit
image: teddit/teddit:latest
security_opt:
- no-new-privileges
environment:
- PUID=1000
- PGID=1000
- TZ=Asia/Singapore
- DOMAIN=i.opnxng.com
- USE_HELMET=true
- USE_HELMET_HSTS=true
- TRUST_PROXY=true
- REDIS_HOST=localhost
# - REDIS_HOST=teddit-redis
2023-11-06 10:39:27 +08:00
- THEME=dark
- FLAIRS_ENABLED=false
- API_ENABLED=false
- SUGGESTED_SUBREDDITS=["Saved", "Selfhosted", "Linux", "Privacy", "DataHoarder"]
2024-02-18 21:16:27 +08:00
- DOMAIN_REPLACEMENTS=[["quora.com","q.opnxng.com."],["imgur.com","r.opnxng.com"]]
restart: unless-stopped
2023-11-06 10:39:27 +08:00
healthcheck:
test: ["CMD", "wget" ,"--no-verbose", "--tries=1", "--spider", "http://localhost:8080/about"]
interval: 1m
timeout: 3s
depends_on:
- teddit-redis
logging:
driver: none
volumes:
- {{ docker_dir }}/teddit/topbar.pug:/teddit/views/includes/topbar.pug
- {{ docker_dir }}/teddit/about.pug:/teddit/views/about.pug
network_mode: "service:teddit-warp"
2023-11-06 10:39:27 +08:00
teddit-redis:
container_name: teddit-redis
image: redis:alpine
command: redis-server
environment:
- PUID=1000
- PGID=1000
- TZ=Asia/Singapore
- REDIS_REPLICATION_MODE=master
restart: unless-stopped
network_mode: "service:teddit-warp"
2023-11-06 10:39:27 +08:00
networks:
2023-11-10 05:28:42 +08:00
teddit:
name: teddit