Files
smarthost-proxy/smarthost-proxy.json
gyurix 55dade2f34
All checks were successful
continuous-integration/drone/push Build is passing
replaced safebox
2025-03-05 17:25:36 +01:00

184 lines
4.2 KiB
JSON

{
"main": {
"SERVICE_NAME": "smarthost-proxy",
"DOMAIN": "null"
},
"networks": [
{
"NAME": "smarthost-loadbalancer",
"DRIVER": "bridge",
"SUBNET": "172.18.103.0/24",
"RANGE": "172.18.103.0/24",
"GATEWAY": "172.18.103.1"
},
{
"NAME": "smarthost_backend-1",
"DRIVER": "bridge",
"SUBNET": "172.18.104.0/24",
"RANGE": "172.18.104.0/24",
"GATEWAY": "172.18.104.1"
},
{
"NAME": "smarthost_backend-2",
"DRIVER": "bridge",
"SUBNET": "172.18.105.0/24",
"RANGE": "172.18.105.0/24",
"GATEWAY": "172.18.105.1"
}
],
"containers": [
{
"IMAGE": "safebox/haproxy",
"NAME": "smarthost_loadbalancer",
"SCALE": "",
"SELECTOR": "smarthostloadbalancer",
"UPDATE": "true",
"ROLES": "smarthost-frontend-proxy",
"MEMORY": "256M",
"NETWORK": "smarthost-loadbalancer",
"DNS": [ "coredns" ],
"READYNESS": [
{"tcp": "80"},
{"HTTP": "8080"},
{"EXEC": "/ready.sh"}
],
"PORTS": [
{
"SOURCE": "null",
"DEST": "80",
"TYPE": "tcp"
},
{
"SOURCE": "null",
"DEST": "443",
"TYPE": "tcp"
}
],
"VOLUMES": [
{
"SOURCE": "/etc/system/config/smarthost-proxy/loadbalancer/haproxy.cfg",
"DEST": "/etc/haproxy/haproxy.cfg",
"TYPE": "rw"
},
{
"SOURCE": "/etc/system/log/smarthost-proxy/loadbalancer",
"DEST": "/var/log/haproxy",
"TYPE": "rw"
}
],
"READYNESS": [
{"tcp": "80"},
{"HTTP": "8080"},
{"EXEC": "/ready.sh"}
],
"ENV_FILES": [ "/etc/system/config/proxy.json" ],
"EXTRA": "--restart unless-stopped --log-opt max-size=500m --label ROLES=loadbalancer" ,
"DEPEND": [ ],
"START_ON_BOOT": "true",
"CMD": "null",
"PRE_START": [ ],
"POST_START": [ "firewall-smarthost-loadbalancer-dns", "firewall-letsencrypt", "firewall-smarthostloadbalancer-from-publicbackend" ]
},
{
"IMAGE": "safebox/nginx",
"NAME": "smarthost_backend-1",
"UPDATE": "true",
"ROLES": "smarthost-backend-proxy",
"MEMORY": "64M",
"NETWORK": "smarthost_backend-1",
"DNS": [ "coredns" ],
"SELECTOR": "smarthostbackend-1",
"PORTS": [
{
"SOURCE": "null",
"DEST": "80",
"TYPE": "tcp"
},
{
"SOURCE": "null",
"DEST": "443",
"TYPE": "tcp"
}
],
"VOLUMES": [
{
"SOURCE": "/etc/system/config/smarthost-proxy/nginx",
"DEST": "/etc/nginx/conf.d",
"TYPE": "ro"
},
{
"SOURCE": "/etc/system/data/ssl/keys",
"DEST": "/etc/ssl/keys",
"TYPE": "ro"
},
{
"SOURCE": "/etc/system/log/smarthost-proxy/backend-1",
"DEST": "/var/log/nginx",
"TYPE": "rw"
}
],
"READYNESS": [
{"tcp": "80"},
{"HTTP": "8080"},
{"EXEC": "/ready.sh"}
],
"EXTRA": "--restart unless-stopped",
"DEPEND": "null",
"START_ON_BOOT": "true",
"CMD": "null",
"PRE_START": ["firewall-smarthost-backend-dns"],
"POST_START": [ "firewall-smarthost-to-backend" ]
},
{
"IMAGE": "safebox/nginx",
"NAME": "smarthost_backend-2",
"UPDATE": "true",
"ROLES": "smarthost-backend-proxy",
"DNS": [ "coredns" ],
"MEMORY": "64M",
"NETWORK": "smarthost_backend-2",
"SELECTOR": "smarthostbackend-2",
"PORTS": [
{
"SOURCE": "null",
"DEST": "80",
"TYPE": "tcp"
},
{
"SOURCE": "null",
"DEST": "443",
"TYPE": "tcp"
}
],
"VOLUMES": [
{
"SOURCE": "/etc/system/config/smarthost-proxy/nginx",
"DEST": "/etc/nginx/conf.d",
"TYPE": "ro"
},
{
"SOURCE": "/etc/system/data/ssl/keys",
"DEST": "/etc/ssl/keys",
"TYPE": "ro"
},
{
"SOURCE": "/etc/system/log/smarthost-proxy/backend-2",
"DEST": "/var/log/nginx",
"TYPE": "rw"
}
],
"READYNESS": [
{"tcp": "80"},
{"HTTP": "8080"},
{"EXEC": "/ready.sh"}
],
"EXTRA": "--restart unless-stopped",
"DEPEND": "null",
"START_ON_BOOT": "true",
"CMD": "null",
"PRE_START": ["firewall-smarthost-backend-dns"],
"POST_START": [ "firewall-smarthost-to-backend" ]
}
]
}