Modernized Firefly config

pull/10/head
Jef Roosens 2021-04-23 14:29:34 +02:00
parent 94bd72ee39
commit 0172b193a1
Signed by: Jef Roosens
GPG Key ID: B580B976584B5F30
2 changed files with 11 additions and 16 deletions

View File

@ -63,7 +63,7 @@ DB_HOST=db
DB_PORT=5432 DB_PORT=5432
DB_DATABASE=firefly DB_DATABASE=firefly
DB_USERNAME=firefly DB_USERNAME=firefly
DB_PASSWORD=password DB_PASSWORD=firefly
# MySQL supports SSL. You can configure it here. # MySQL supports SSL. You can configure it here.
# If you use Docker or similar, you can set these variables from a file by appending them with _FILE # If you use Docker or similar, you can set these variables from a file by appending them with _FILE

View File

@ -6,24 +6,23 @@ services:
context: '.' context: '.'
args: args:
- 'LOCALE=$DEFAULT_LOCALE' - 'LOCALE=$DEFAULT_LOCALE'
image: 'firefly-iii-cron:latest' image: 'chewingbever/firefly-iii-cron:latest'
restart: 'always' restart: 'always'
healthcheck: healthcheck:
test: 'curl -f localhost:8080 || exit 1' test: 'curl -f localhost:8080 || exit 1'
interval: '1m' interval: '1m'
timeout: '10s' timeout: '10s'
retries: 3 retries: 3
start_period: '10s' start_period: '10s'
depends_on: depends_on:
db: db:
condition: 'service_healthy' condition: 'service_healthy'
redis: redis:
condition: 'service_healthy' condition: 'service_healthy'
env_file: env_file:
- '.env' - '.env'
labels:
- 'com.centurylinklabs.watchtower.enable=true'
networks: networks:
- 'nginx' - 'nginx'
- 'default' - 'default'
@ -31,25 +30,24 @@ services:
- 'upload:/var/www/html/storage/upload' - 'upload:/var/www/html/storage/upload'
db: db:
image: 'postgres:13-alpine' image: 'postgres:13.2-alpine'
restart: 'always' restart: 'always'
healthcheck: healthcheck:
test: 'pg_isready -U $DB_USERNAME' test: 'pg_isready -U firefly'
interval: '10s' interval: '10s'
timeout: '5s' timeout: '5s'
retries: 5 retries: 5
start_period: '0s'
environment: environment:
- 'POSTGRES_DB=$DB_DATABASE' - 'POSTGRES_DB=firefly'
- 'POSTGRES_PASSWORD=$DB_PASSWORD' - 'POSTGRES_PASSWORD=firefly'
- 'POSTGRES_USER=$DB_USERNAME' - 'POSTGRES_USER=firefly'
labels:
- 'com.centurylinklabs.watchtower.enable=true'
volumes: volumes:
- 'db-data:/var/lib/postgresql/data' - 'db-data:/var/lib/postgresql/data'
redis: redis:
image: 'redis:6-alpine' image: 'redis:6.0.12-alpine'
restart: 'always' restart: 'always'
healthcheck: healthcheck:
test: 'redis-cli -h localhost ping' test: 'redis-cli -h localhost ping'
@ -57,9 +55,6 @@ services:
timeout: '5s' timeout: '5s'
retries: 3 retries: 3
labels:
- 'com.centurylinklabs.watchtower.enable=true'
networks: networks:
nginx: nginx:
external: true external: true