1
0
mirror of https://github.com/vimagick/dockerfiles.git synced 2024-12-23 01:39:27 +02:00

update nextcloud

This commit is contained in:
kev 2022-01-07 18:20:29 +08:00
parent ee3e571f9b
commit a25c932af3
5 changed files with 67 additions and 61 deletions

View File

@ -5,30 +5,6 @@ nextcloud
[Nextcloud][1] puts your data at your fingertips, under your control. [Nextcloud][1] puts your data at your fingertips, under your control.
## docker-compose.yml
```yaml
nextcloud:
image: indiehosters/nextcloud
ports:
- "127.0.0.1:9000:9000"
volumes:
- ./data/apps:/var/www/html/apps
- ./data/config:/var/www/html/config
- ./data/data:/var/www/html/data
restart: always
nginx:
image: nginx:alpine
volumes:
- ./nginx.conf:/etc/nginx/conf.d/default.conf
- ./ssl:/etc/nginx/ssl
volumes_from:
- nextcloud
net: host
restart: always
```
## Server Setup ## Server Setup
```bash ```bash

View File

@ -3,7 +3,7 @@ version: "3.8"
services: services:
nextcloud: nextcloud:
image: arm32v7/nextcloud:22 image: nextcloud:stable
ports: ports:
- "8080:80" - "8080:80"
volumes: volumes:
@ -13,14 +13,14 @@ services:
- POSTGRES_DB=nextcloud - POSTGRES_DB=nextcloud
- POSTGRES_USER=nextcloud - POSTGRES_USER=nextcloud
- POSTGRES_PASSWORD=nextcloud - POSTGRES_PASSWORD=nextcloud
- REDIS_HOST=redis
depends_on: depends_on:
- postgres - postgres
- redis
restart: unless-stopped restart: unless-stopped
postgres: postgres:
image: arm32v7/postgres:13-alpine image: postgres:14-alpine
ports:
- "5432:5432"
volumes: volumes:
- ./data/postgres:/var/lib/postgresql/data - ./data/postgres:/var/lib/postgresql/data
environment: environment:
@ -28,3 +28,10 @@ services:
- POSTGRES_PASSWORD=nextcloud - POSTGRES_PASSWORD=nextcloud
- POSTGRES_DB=nextcloud - POSTGRES_DB=nextcloud
restart: unless-stopped restart: unless-stopped
redis:
image: redis:6-alpine
command: --save 900 1
volumes:
- ./data/redis:/data
restart: unless-stopped

View File

@ -1,19 +1,37 @@
nextcloud: version: "3.8"
image: indiehosters/nextcloud
ports:
- "127.0.0.1:9000:9000"
volumes:
- ./data/apps:/var/www/html/apps
- ./data/config:/var/www/html/config
- ./data/data:/var/www/html/data
restart: always
nginx: services:
image: nginx:alpine
nextcloud:
image: nextcloud:stable
ports:
- "8080:80"
volumes: volumes:
- ./nginx.conf:/etc/nginx/conf.d/default.conf - ./data/nextcloud:/var/www/html
- ./ssl:/etc/nginx/ssl environment:
volumes_from: - POSTGRES_HOST=postgres
- nextcloud - POSTGRES_DB=nextcloud
net: host - POSTGRES_USER=nextcloud
restart: always - POSTGRES_PASSWORD=nextcloud
- REDIS_HOST=redis
depends_on:
- postgres
- redis
restart: unless-stopped
postgres:
image: postgres:14-alpine
volumes:
- ./data/postgres:/var/lib/postgresql/data
environment:
- POSTGRES_USER=nextcloud
- POSTGRES_PASSWORD=nextcloud
- POSTGRES_DB=nextcloud
restart: unless-stopped
redis:
image: redis:6-alpine
command: --save 900 1
volumes:
- ./data/redis:/data
restart: unless-stopped

View File

@ -8,13 +8,16 @@ redis
## docker-compose.yml ## docker-compose.yml
```yaml ```yaml
version: "3.8"
services:
redis: redis:
image: redis:alpine image: redis:6-alpine
command: --save 900 1
ports: ports:
- "127.0.0.1:6379:6379" - "6379:6379"
volumes: volumes:
- ./data:/data - ./data:/data
restart: always restart: unless-stopped
``` ```
[1]: https://redis.io/ [1]: https://redis.io/

View File

@ -1,8 +1,10 @@
version: "3.8"
services:
redis: redis:
image: redis:alpine image: redis:6-alpine
command: --save 900 1 command: --save 900 1
ports: ports:
- "127.0.0.1:6379:6379" - "6379:6379"
volumes: volumes:
- ./data:/data - ./data:/data
restart: always restart: unless-stopped