mirror of
https://github.com/nextcloud/nextcloudpi.git
synced 2026-01-10 15:12:01 -03:30
library.sh: Remove invalid trusted_proxy
Signed-off-by: Tobias Knöppler <6317548+theCalcaholic@users.noreply.github.com> Signed-off-by: Tobias K <6317548+theCalcaholic@users.noreply.github.com>
This commit is contained in:
parent
68e2e2d7ac
commit
242ca671f9
1
.github/workflows/build-lxd.yml
vendored
1
.github/workflows/build-lxd.yml
vendored
@ -327,7 +327,6 @@ jobs:
|
||||
runs-on: [ubuntu-20.04]
|
||||
env:
|
||||
VERSION: "${{ inputs.git_ref || github.ref }}"
|
||||
ARTIFACT_NAME: "${{ needs.build-previous.outputs.artifact_name }}"
|
||||
LXC: "${{ needs.determine-runner.outputs.lxc_cmd }}"
|
||||
PREVIOUS_IMAGE_URL: "https://github.com/nextcloud/nextcloudpi/releases/download/v1.53.2/NextcloudPi_LXD_x86_v1.53.2.tar.gz"
|
||||
steps:
|
||||
|
||||
@ -156,7 +156,7 @@ function set-nc-domain()
|
||||
if is_ncp_activated && is_app_enabled notify_push; then
|
||||
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 13 --value="${domain}"
|
||||
# ncc config:system:set trusted_proxies 13 --value="${domain}"
|
||||
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
|
||||
for try in {1..5}
|
||||
|
||||
@ -7,5 +7,11 @@ then
|
||||
sed -i -e 's/^PermitRootLogin.*$/PermitRootLogin No/' /etc/ssh/sshd_config
|
||||
fi
|
||||
|
||||
for i in {10..15}
|
||||
do
|
||||
proxy="$(ncc config:system:get trusted_proxies "$i")"
|
||||
[[ -z "$proxy" ]] || python3 -c "import ipaddress; ipaddress.ip_address('${proxy}')" || ncc config:system:delete trusted_proxies "$i"
|
||||
done
|
||||
|
||||
apt-get update
|
||||
apt-get install --no-install-recommends -y tmux
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user