Improved Nextcloud config
parent
4a4437683e
commit
0b85900b71
|
@ -1,4 +1,4 @@
|
|||
version: '2.8'
|
||||
version: '2.4'
|
||||
|
||||
services:
|
||||
app:
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
POSTGRES_HOST=db
|
||||
POSTGRES_DB=nextcloud
|
||||
POSTGRES_USER=nextcloud
|
||||
POSTGRES_PASSWORD=pass
|
||||
POSTGRES_PASSWORD=nextcloud
|
||||
|
||||
# Redis
|
||||
REDIS_HOST=redis
|
||||
|
|
|
@ -1,17 +1,24 @@
|
|||
version: '3.5'
|
||||
version: '2.4'
|
||||
|
||||
services:
|
||||
app:
|
||||
image: 'nextcloud:20-apache'
|
||||
image: 'nextcloud:21.0.1-apache'
|
||||
restart: 'always'
|
||||
|
||||
healthcheck:
|
||||
test: 'curl -f localhost || exit 1'
|
||||
interval: '1m'
|
||||
timeout: '10s'
|
||||
retries: 3
|
||||
start_period: '10s'
|
||||
depends_on:
|
||||
- 'db'
|
||||
- 'redis'
|
||||
db:
|
||||
condition: 'service_healthy'
|
||||
redis:
|
||||
condition: 'service_healthy'
|
||||
|
||||
env_file:
|
||||
- '.env'
|
||||
labels:
|
||||
- 'com.centurylinklabs.watchtower.enable=true'
|
||||
networks:
|
||||
- 'default'
|
||||
- 'nginx'
|
||||
|
@ -21,40 +28,41 @@ services:
|
|||
- 'root:/var/www/html'
|
||||
|
||||
cron:
|
||||
image: 'nextcloud:20-apache'
|
||||
entrypoint: '/cron.sh'
|
||||
image: 'nextcloud:21.0.1-apache'
|
||||
restart: 'always'
|
||||
entrypoint: '/cron.sh'
|
||||
|
||||
depends_on:
|
||||
- 'app'
|
||||
app:
|
||||
condition: 'service_healthy'
|
||||
|
||||
env_file:
|
||||
- '.env'
|
||||
labels:
|
||||
- 'com.centurylinklabs.watchtower.enable=true'
|
||||
volumes:
|
||||
- 'config:/var/www/html/config'
|
||||
- 'data:/var/www/html/data'
|
||||
- 'root:/var/www/html'
|
||||
|
||||
db:
|
||||
image: 'postgres:13-alpine'
|
||||
image: 'postgres:13.2-alpine'
|
||||
restart: 'always'
|
||||
|
||||
environment:
|
||||
- 'POSTGRES_DB'
|
||||
- 'POSTGRES_USER'
|
||||
- 'POSTGRES_PASSWORD'
|
||||
labels:
|
||||
- 'com.centurylinklabs.watchtower.enable=true'
|
||||
- 'POSTGRES_DB=nextcloud'
|
||||
- 'POSTGRES_USER=nextcloud'
|
||||
- 'POSTGRES_PASSWORD=nextcloud'
|
||||
volumes:
|
||||
- 'db-data:/var/lib/postgresql/data'
|
||||
|
||||
redis:
|
||||
image: 'redis:6-alpine'
|
||||
image: 'redis:6.0.12-alpine'
|
||||
restart: 'always'
|
||||
|
||||
labels:
|
||||
- 'com.centurylinklabs.watchtower.enable=true'
|
||||
healthcheck:
|
||||
test: 'redis-cli -h localhost ping'
|
||||
interval: '10s'
|
||||
timeout: '5s'
|
||||
retries: 3
|
||||
|
||||
networks:
|
||||
nginx:
|
||||
|
|
Reference in New Issue