Skip to content

Commit cd1998e

Browse files
authored
Merge pull request coollabsio#3199 from FranckKe/add_nextcloud_with_postgres
feat: add Nextcloud with Postgres template
2 parents 53dfda9 + a4dedb8 commit cd1998e

File tree

1 file changed

+52
-0
lines changed

1 file changed

+52
-0
lines changed
Lines changed: 52 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,52 @@
1+
# documentation: https://docs.nextcloud.com
2+
# slogan: NextCloud is a self-hosted, open-source platform that provides file storage, collaboration, and communication tools for seamless data management.
3+
# tags: cloud, collaboration, communication, filestorage, data
4+
# logo: svgs/nextcloud.svg
5+
6+
services:
7+
nextcloud:
8+
image: lscr.io/linuxserver/nextcloud:latest
9+
environment:
10+
- SERVICE_FQDN_NEXTCLOUD
11+
- PUID=1000
12+
- PGID=1000
13+
- TZ=Europe/Paris
14+
- POSTGRES_DB=${POSTGRES_DB:-nextcloud}
15+
- POSTGRES_USER=$SERVICE_USER_POSTGRES
16+
- POSTGRES_PASSWORD=$SERVICE_PASSWORD_POSTGRES
17+
- POSTGRES_HOST=postgresql
18+
- REDIS_HOST=redis
19+
- REDIS_PORT=6379
20+
volumes:
21+
- nextcloud-config:/config
22+
- nextcloud-data:/data
23+
healthcheck:
24+
test: ["CMD", "curl", "-f", "http://127.0.0.1:80"]
25+
interval: 2s
26+
timeout: 10s
27+
retries: 15
28+
postgresql:
29+
image: postgres:16-alpine
30+
volumes:
31+
- postgresql-data:/var/lib/postgresql/data
32+
environment:
33+
- POSTGRES_USER=$SERVICE_USER_POSTGRES
34+
- POSTGRES_PASSWORD=$SERVICE_PASSWORD_POSTGRES
35+
- POSTGRES_DB=${POSTGRES_DB:-nextcloud}
36+
healthcheck:
37+
test: ["CMD-SHELL", "pg_isready -U $${POSTGRES_USER} -d $${POSTGRES_DB}"]
38+
interval: 5s
39+
timeout: 20s
40+
retries: 10
41+
redis:
42+
image: "redis:7.4-alpine"
43+
volumes:
44+
- "redis-data:/data"
45+
healthcheck:
46+
test:
47+
- CMD
48+
- redis-cli
49+
- PING
50+
interval: 5s
51+
timeout: 10s
52+
retries: 20

0 commit comments

Comments
 (0)