File tree Expand file tree Collapse file tree 1 file changed +9
-7
lines changed
root/etc/s6-overlay/s6-rc.d/svc-mod-nextcloud-notify-push Expand file tree Collapse file tree 1 file changed +9
-7
lines changed Original file line number Diff line number Diff line change @@ -32,14 +32,16 @@ if [ ! -f "$NOTIFY_PUSH_BIN" ]; then
3232fi
3333
3434# add to trusted proxies
35- if ! occ config:system:get trusted_proxies | grep -q "127.0.0.1"; then
36- NO_OF_PROXIES=$(occ config:system:get trusted_proxies --output=json | jq 'length')
37- if [[ -z "${NO_OF_PROXIES}" ]]; then
38- NO_OF_PROXIES="0"
35+ for PROXY in '127.0.0.1' '::1'; do
36+ if ! occ config:system:get trusted_proxies | grep -q "${PROXY}"; then
37+ NO_OF_PROXIES=$(occ config:system:get trusted_proxies --output=json | jq 'length')
38+ if [[ -z "${NO_OF_PROXIES}" ]]; then
39+ NO_OF_PROXIES="0"
40+ fi
41+ echo "**** Adding notify_push (${PROXY}) to trusted proxies ****"
42+ occ config:system:set trusted_proxies "${NO_OF_PROXIES}" --value="${PROXY}"
3943 fi
40- echo "**** Adding notify_push to trusted proxies ****"
41- occ config:system:set trusted_proxies "${NO_OF_PROXIES}" --value=127.0.0.1
42- fi
44+ done
4345
4446# run notify-push binary
4547echo "**** Starting notify-push ****"
You can’t perform that action at this time.
0 commit comments