Refactor docker-compose files

This commit is contained in:
2022-08-29 14:37:55 +03:00
parent 7b0636312c
commit 9c051ed370
28 changed files with 624 additions and 700 deletions

View File

@@ -3,85 +3,36 @@ version: '3.9'
services:
ghost:
image: ghost
container_name: ghost
restart: unless-stopped
volumes:
- '/home/nick/configs/ghost/ghost:/var/lib/ghost/content'
- '/home/nick/configs/ghost:/var/lib/ghost/content'
environment:
url: ${URL}
url: https://blog.karaolidis.com
database__client: mysql
database__connection__host: db
database__connection__user: ghost
database__connection__database: ghost
database__connection__password: ghost
networks:
- proxy
- ghost
- default
- routing
depends_on:
- db
user: '1000:1000'
commento:
image: caroga/commentoplusplus
container_name: commento
db:
image: mysql
restart: unless-stopped
environment:
COMMENTO_ORIGIN: 'https://stats.karaolidis.com/comments/'
COMMENTO_CDN_PREFIX: 'https://stats.karaolidis.com/comments/'
COMMENTO_PORT: 8080
COMMENTO_POSTGRES: postgres://postgres:postgres@commento_db:5432/commento?sslmode=disable
COMMENTO_SMTP_HOST: '${SMTP_HOST}'
COMMENTO_SMTP_PORT: '${SMTP_PORT}'
COMMENTO_SMTP_USERNAME: '${SMTP_USER}'
COMMENTO_SMTP_PASSWORD: '${SMTP_PASSWORD}'
COMMENTO_SMTP_FROM_ADDRESS: '${SMTP_FROM}'
COMMENTO_FORBID_NEW_OWNERS: 'true'
networks:
- proxy
- ghost
depends_on:
- commento_db
commento_db:
image: postgres:13.4
container_name: commento_db
restart: unless-stopped
environment:
POSTGRES_DB: commento
POSTGRES_USER: postgres
POSTGRES_PASSWORD: postgres
volumes:
- '/home/nick/configs/ghost/commento:/var/lib/postgresql/data'
networks:
- ghost
user: '1000:1000'
umami:
image: ghcr.io/mikecao/umami:postgresql-latest
container_name: umami
restart: unless-stopped
- '/home/nick/configs/ghost/db:/var/lib/mysql'
environment:
DATABASE_URL: postgresql://umami:umami@umami_db:5432/umami
DATABASE_TYPE: postgresql
HASH_SALT: ${SALT}
TRACKER_SCRIPT_NAME: u
depends_on:
- umami_db
networks:
- proxy
- ghost
umami_db:
image: postgres:13.4
container_name: umami_db
restart: unless-stopped
environment:
POSTGRES_DB: umami
POSTGRES_USER: umami
POSTGRES_PASSWORD: umami
volumes:
- '/home/nick/configs/ghost/umami/schema.postgresql.sql:/docker-entrypoint-initdb.d/schema.postgresql.sql:ro'
- '/home/nick/configs/ghost/umami/data:/var/lib/postgresql/data'
networks:
- ghost
MYSQL_USER: ghost
MYSQL_DATABASE: ghost
MYSQL_PASSWORD: ghost
MYSQL_RANDOM_ROOT_PASSWORD: yes
user: '1000:1000'
networks:
proxy:
routing:
external: true
name: proxy
ghost:
name: ghost
name: routing