Refactor nextcloud/template.json for improved structure

This commit is contained in:
gyurix
2025-05-25 11:20:49 +02:00
parent b9770f4ec9
commit 71c800db43
2 changed files with 315 additions and 267 deletions

View File

@@ -27,7 +27,9 @@
"TYPE": "rw" "TYPE": "rw"
} }
], ],
"ENV_FILES": [ "/etc/user/secret/nextcloud/nextcloud.json" ], "ENV_FILES": [
"/etc/user/secret/nextcloud/nextcloud.json"
],
"EXTRA": "--rm", "EXTRA": "--rm",
"DEPEND": "null", "DEPEND": "null",
"START_ON_BOOT": "false", "START_ON_BOOT": "false",
@@ -37,7 +39,7 @@
"POST_START": "null" "POST_START": "null"
}, },
{ {
"IMAGE": "mariadb:latest", "IMAGE": "alpine/mariadb",
"UPDATE": "true", "UPDATE": "true",
"NAME": "nextcloudmysql-db", "NAME": "nextcloudmysql-db",
"MEMORY": "256M", "MEMORY": "256M",
@@ -63,11 +65,19 @@
} }
], ],
"READYNESS": [ "READYNESS": [
{"tcp": "3306"}, {
{"HTTP": ""}, "tcp": "3306"
{"EXEC": "/ready.sh"} },
{
"HTTP": ""
},
{
"EXEC": "/ready.sh"
}
],
"ENV_FILES": [
"/etc/user/secret/nextcloud/nextcloud.json"
], ],
"ENV_FILES": [ "/etc/user/secret/nextcloud/nextcloud.json" ],
"EXTRA": "--restart always", "EXTRA": "--restart always",
"DEPEND": "null", "DEPEND": "null",
"START_ON_BOOT": "false", "START_ON_BOOT": "false",
@@ -90,9 +100,15 @@
} }
], ],
"READYNESS": [ "READYNESS": [
{"tcp": ""}, {
{"HTTP": ""}, "tcp": ""
{"EXEC": "/ready.sh"} },
{
"HTTP": ""
},
{
"EXEC": "/ready.sh"
}
], ],
"EXTRA": "--restart always", "EXTRA": "--restart always",
"DEPEND": "null", "DEPEND": "null",
@@ -102,13 +118,15 @@
"POST_START": "null" "POST_START": "null"
}, },
{ {
"IMAGE": "registry.format.hu/nextcloud-php-fpm:26", "IMAGE": "nextcloud:VERSION",
"UPDATE": "true", "UPDATE": "true",
"NAME": "nextcloudphp-fpm", "NAME": "nextcloudphp-fpm",
"MEMORY": "1024M", "MEMORY": "1024M",
"NETWORK": "nextcloud-net", "NETWORK": "nextcloud-net",
"SELECTOR": "nextcloudphp-fpm", "SELECTOR": "nextcloudphp-fpm",
"DNS": [ "coredns" ], "DNS": [
"coredns"
],
"VOLUMES": [ "VOLUMES": [
{ {
"SOURCE": "nextcloud", "SOURCE": "nextcloud",
@@ -139,17 +157,29 @@
} }
], ],
"READYNESS": [ "READYNESS": [
{"tcp": ""}, {
{"HTTP": ""}, "tcp": ""
{"EXEC": "/ready.sh"} },
{
"HTTP": ""
},
{
"EXEC": "/ready.sh"
}
],
"ENV_FILES": [
"/etc/user/secret/nextcloud/nextcloud.json"
], ],
"ENV_FILES": [ "/etc/user/secret/nextcloud/nextcloud.json" ],
"EXTRA": "--user www-data --restart always", "EXTRA": "--user www-data --restart always",
"DEPEND": "null", "DEPEND": "null",
"START_ON_BOOT": "false", "START_ON_BOOT": "false",
"CMD": "null", "CMD": "null",
"PRE_START": [ "firewall-nextcloud-server-dns" ], "PRE_START": [
"POST_START": ["firewall-nextcloud-server-smtp"] "firewall-nextcloud-server-dns"
],
"POST_START": [
"firewall-nextcloud-server-smtp"
]
}, },
{ {
"IMAGE": "registry.format.hu/nextcloud-nginx:1.23.1", "IMAGE": "registry.format.hu/nextcloud-nginx:1.23.1",
@@ -159,7 +189,9 @@
"MEMORY": "128M", "MEMORY": "128M",
"NETWORK": "nextcloud-net", "NETWORK": "nextcloud-net",
"SELECTOR": "nextcloudnginx", "SELECTOR": "nextcloudnginx",
"DNS": [ "coredns" ], "DNS": [
"coredns"
],
"VOLUMES": [ "VOLUMES": [
{ {
"SOURCE": "nextcloud", "SOURCE": "nextcloud",
@@ -185,15 +217,23 @@
} }
], ],
"READYNESS": [ "READYNESS": [
{"tcp": ""}, {
{"HTTP": ""}, "tcp": ""
{"EXEC": "/ready.sh"} },
{
"HTTP": ""
},
{
"EXEC": "/ready.sh"
}
], ],
"EXTRA": "--restart always", "EXTRA": "--restart always",
"DEPEND": "null", "DEPEND": "null",
"START_ON_BOOT": "false", "START_ON_BOOT": "false",
"CMD": "null", "CMD": "null",
"PRE_START": [ "firewall-nextcloud-dns" ], "PRE_START": [
"firewall-nextcloud-dns"
],
"POST_START": [ "POST_START": [
"firewall-nextcloud", "firewall-nextcloud",
"domain-nextcloud" "domain-nextcloud"

View File

@@ -44,6 +44,14 @@
"generated": "", "generated": "",
"advanced": "true" "advanced": "true"
}, },
{
"title": "Nextcloud version",
"description": "Please give the currently deployed Nextcloud version: (leave it currenbt and it will be set automatically)",
"key": "VERSION",
"value": "26.0.13-fpm-alpine",
"info": "Please keep in mind you can't upgrade major version without skipping a version!",
"advanced": "true"
},
{ {
"description": "MYSQL username", "description": "MYSQL username",
"key": "MARIADB_USER", "key": "MARIADB_USER",