mirror of
https://github.com/nextcloud/nextcloudpi.git
synced 2026-01-10 15:12:01 -03:30
library.sh,1.54.0.sh: Remove invalid trusted_proxies
Signed-off-by: Tobias K <6317548+theCalcaholic@users.noreply.github.com>
This commit is contained in:
parent
5d0f9eec91
commit
218a6584a7
2
.github/workflows/vm-tests.yml
vendored
2
.github/workflows/vm-tests.yml
vendored
@ -43,7 +43,7 @@ jobs:
|
|||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v3
|
- uses: actions/checkout@v3
|
||||||
with:
|
with:
|
||||||
path: /home/runner/actions-runner/_work/nextcloudpi/nextcloudpi
|
path: /__w/nextcloudpi/nextcloudpi
|
||||||
- name: Generate ssh keypair
|
- name: Generate ssh keypair
|
||||||
working-directory: /__w/nextcloudpi/nextcloudpi
|
working-directory: /__w/nextcloudpi/nextcloudpi
|
||||||
run: |
|
run: |
|
||||||
|
|||||||
@ -157,7 +157,8 @@ function set-nc-domain()
|
|||||||
ncc config:system:set trusted_proxies 11 --value="127.0.0.1"
|
ncc config:system:set trusted_proxies 11 --value="127.0.0.1"
|
||||||
ncc config:system:set trusted_proxies 12 --value="::1"
|
ncc config:system:set trusted_proxies 12 --value="::1"
|
||||||
# ncc config:system:set trusted_proxies 13 --value="${domain}"
|
# ncc config:system:set trusted_proxies 13 --value="${domain}"
|
||||||
ncc config:system:set trusted_proxies 14 --value="$(dig +short "${domain}")"
|
local domain_ip="$(dig +short "${domain}")"
|
||||||
|
[[ -z "$domain_ip" ]] || ncc config:system:set trusted_proxies 14 --value="$(dig +short "${domain}")"
|
||||||
sleep 5 # this seems to be required in the VM for some reason. We get `http2 error: protocol error` after ncp-upgrade-nc
|
sleep 5 # this seems to be required in the VM for some reason. We get `http2 error: protocol error` after ncp-upgrade-nc
|
||||||
for try in {1..5}
|
for try in {1..5}
|
||||||
do
|
do
|
||||||
|
|||||||
@ -9,8 +9,8 @@ fi
|
|||||||
|
|
||||||
for i in {10..15}
|
for i in {10..15}
|
||||||
do
|
do
|
||||||
proxy="$(ncc config:system:get trusted_proxies "$i")"
|
proxy="$(ncc config:system:get trusted_proxies "$i" || echo 'NONE')"
|
||||||
[[ -z "$proxy" ]] || python3 -c "import ipaddress; ipaddress.ip_address('${proxy}')" || ncc config:system:delete trusted_proxies "$i"
|
[[ "$proxy" == 'NONE' ]] || python3 -c "import ipaddress; ipaddress.ip_address('${proxy}')" || ncc config:system:delete trusted_proxies "$i"
|
||||||
done
|
done
|
||||||
|
|
||||||
apt-key adv --fetch-keys https://packages.sury.org/php/apt.gpg
|
apt-key adv --fetch-keys https://packages.sury.org/php/apt.gpg
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user