photoview: add config

This commit is contained in:
Jef Roosens 2024-10-01 14:28:28 +02:00
parent 56faa4323b
commit ad36788772
Signed by: Jef Roosens
GPG key ID: B75D4F293C7052DB
12 changed files with 191 additions and 13 deletions

View file

@ -0,0 +1,35 @@
services:
app:
image: 'viktorstrate/photoview:2.4.0'
restart: 'always'
depends_on:
db:
condition: service_healthy
environment:
PHOTOVIEW_DATABASE_DRIVER: 'postgres'
PHOTOVIEW_POSTGRES_URL: 'postgres://photoview:photoview@db/photoview?sslmode=disable'
ports:
- '8012:80'
volumes:
- '/etc/localtime:/etc/localtime:ro'
- '/etc/timezone:/etc/timezone:ro'
- '/mnt/data1/photoview/cache:/home/photoview/media-cache'
- '/mnt/data1/photos:/photos:ro'
db:
image: 'postgres:17.0-alpine'
restart: 'always'
healthcheck:
test: ["CMD", "pg_isready", "-U", "photoview"]
interval: 10s
start_period: 30s
environment:
POSTGRES_USER: 'photoview'
POSTGRES_PASSWORD: 'photoview'
POSTGRES_DB: 'photoview'
volumes:
- '/mnt/data1/photoview/postgres:/var/lib/postgresql/data'