Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
30 changes: 14 additions & 16 deletions .github/workflows/build-lxd.yml
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,7 @@ jobs:
runner_label: ${{ steps.script.outputs.runner_label }}
lxc_cmd: ${{ steps.script.outputs.lxc_cmd }}
lxd_extra_profile: ${{ steps.script.outputs.lxd_extra_profile }}
ff_binary: ${{ steps.script.outputs.ff_binary }}
steps:
- name: script
id: script
Expand All @@ -45,9 +46,11 @@ jobs:
LXC_CMD="incus"
RUNNER_LABEL="ubuntu-26.04-arm64"
echo "lxd_extra_profile=network" | tee -a "$GITHUB_OUTPUT"
echo "ff_binary=/usr/bin/firefox-esr" | tee -a "$GITHUB_OUTPUT"
else
LXC_CMD="incus"
RUNNER_LABEL="ubuntu-latest"
echo "ff_binary=$(which firefox)" | tee -a "$GITHUB_OUTPUT"
fi
echo "runner_label=$RUNNER_LABEL" | tee -a $GITHUB_OUTPUT
Expand Down Expand Up @@ -151,7 +154,8 @@ jobs:
if: ${{ needs.determine-runner.outputs.runner_label != 'ubuntu-26.04-arm64' }}
run: |
sudo apt-get update
sudo apt-get install -y incus qemu-system incus-tools
sudo apt-get install -y incus qemu-system
sudo apt-get install -y incus-tools || sudo apt-get install -y incus-extra
sudo iptables -I DOCKER-USER -i incusbr0 -j ACCEPT
sudo iptables -I DOCKER-USER -o incusbr0 -m conntrack --ctstate RELATED,ESTABLISHED -j ACCEPT
sudo incus admin init --auto
Expand Down Expand Up @@ -203,7 +207,8 @@ jobs:
if: ${{ needs.determine-runner.outputs.runner_label != 'ubuntu-26.04-arm64' }}
run: |
sudo apt-get update
sudo apt-get install -y incus qemu-system incus-tools
sudo apt-get install -y incus qemu-system
sudo apt-get install -y incus-tools || sudo apt-get install -y incus-extra
sudo iptables -I DOCKER-USER -i incusbr0 -j ACCEPT
sudo iptables -I DOCKER-USER -o incusbr0 -m conntrack --ctstate RELATED,ESTABLISHED -j ACCEPT
sudo incus admin init --auto
Expand Down Expand Up @@ -232,6 +237,7 @@ jobs:
sudo mv geckodriver /usr/local/bin/
sudo chmod +x /usr/local/bin/geckodriver
echo "GECKODRIVER_PATH=/usr/local/bin/geckodriver" >> "$GITHUB_ENV"
echo "FF_BINARY_PATH=${{ needs.determine-runner.outputs.ff_binary }}" >> "$GITHUB_ENV"
geckodriver -V
- name: Setup Selenium
run: |
Expand Down Expand Up @@ -269,8 +275,6 @@ jobs:
working-directory: ./tests
run: |
set -x
export GECKODRIVER_PATH="$GECKODRIVER_PATH"
export FF_BINARY_PATH="$(which firefox)"
python="$(dirname "$PWD")/.venv/bin/python"
sudo "$LXC" exec ncp -- /usr/local/bin/ncc config:system:set overwrite.cli.url --value "https://nextcloudpi.local"
sudo "$LXC" exec ncp -- bash -c 'tail -f /var/log/ncp.log' |& awk '{ print "NCP::" $0 }' &
Expand Down Expand Up @@ -379,8 +383,6 @@ jobs:
run: |
set -x
sudo "$LXC" exec ncp -- bash -c 'tail -f /var/log/ncp.log' |& awk '{ print "NCP::" $0 }' &
export GECKODRIVER_PATH="$GECKODRIVER_PATH"
export FF_BINARY_PATH="$(which firefox)"
python="$(dirname "$PWD")/.venv/bin/python"
USE_INCUS="$USE_INCUS" "$python" system_tests.py --skip-update-test --non-interactive || {
Expand Down Expand Up @@ -424,7 +426,8 @@ jobs:
if: ${{ needs.determine-runner.outputs.runner_label != 'ubuntu-26.04-arm64' }}
run: |
sudo apt-get update
sudo apt-get install -y incus qemu-system incus-tools
sudo apt-get install -y incus qemu-system
sudo apt-get install -y incus-tools || sudo apt-get install -y incus-extra
sudo iptables -I DOCKER-USER -i incusbr0 -j ACCEPT
sudo iptables -I DOCKER-USER -o incusbr0 -m conntrack --ctstate RELATED,ESTABLISHED -j ACCEPT
sudo incus admin init --auto
Expand Down Expand Up @@ -457,6 +460,7 @@ jobs:
sudo mv geckodriver /usr/local/bin/
sudo chmod +x /usr/local/bin/geckodriver
echo "GECKODRIVER_PATH=/usr/local/bin/geckodriver" >> "$GITHUB_ENV"
echo "FF_BINARY_PATH=${{ needs.determine-runner.outputs.ff_binary }}" >> "$GITHUB_ENV"
geckodriver -V
- name: Setup Selenium
run: |
Expand Down Expand Up @@ -492,8 +496,6 @@ jobs:
working-directory: ./tests
run: |
set -x
export GECKODRIVER_PATH="$GECKODRIVER_PATH"
export FF_BINARY_PATH="$(which firefox)"
sudo "$LXC" exec ncp -- /usr/local/bin/ncc config:system:set overwrite.cli.url --value "https://nextcloudpi.local"
sudo "$LXC" exec ncp -- bash -c 'tail -f /var/log/ncp.log' |& awk '{ print "NCP::" $0 }' &
python="$(dirname "$PWD")/.venv/bin/python"
Expand Down Expand Up @@ -601,8 +603,6 @@ jobs:
run: |
set -x
sudo "$LXC" exec ncp -- bash -c 'tail -f /var/log/ncp.log' |& awk '{ print "NCP::" $0 }' &
export GECKODRIVER_PATH="$GECKODRIVER_PATH"
export FF_BINARY_PATH="$(which firefox)"
python="$(dirname "$PWD")/.venv/bin/python"
USE_INCUS="$USE_INCUS" "$python" system_tests.py --skip-update-test --non-interactive || {
Expand Down Expand Up @@ -698,8 +698,6 @@ jobs:
run: |
set -x
sudo "$LXC" exec ncp -- bash -c 'tail -f /var/log/ncp.log' |& awk '{ print "NCP::" $0 }' &
export GECKODRIVER_PATH="$GECKODRIVER_PATH"
export FF_BINARY_PATH="$(which firefox)"
python="$(dirname "$PWD")/.venv/bin/python"
USE_INCUS="$USE_INCUS" "$python" system_tests.py --skip-update-test --non-interactive || {
Expand Down Expand Up @@ -748,7 +746,8 @@ jobs:
if: ${{ needs.determine-runner.outputs.runner_label != 'ubuntu-26.04-arm64' }}
run: |
sudo apt-get update
sudo apt-get install -y incus qemu-system incus-tools
sudo apt-get install -y incus qemu-system
sudo apt-get install -y incus-tools || sudo apt-get install -y incus-extra
sudo iptables -I DOCKER-USER -i incusbr0 -j ACCEPT
sudo iptables -I DOCKER-USER -o incusbr0 -m conntrack --ctstate RELATED,ESTABLISHED -j ACCEPT
sudo incus admin init --auto
Expand Down Expand Up @@ -777,6 +776,7 @@ jobs:
sudo mv geckodriver /usr/local/bin/
sudo chmod +x /usr/local/bin/geckodriver
echo "GECKODRIVER_PATH=/usr/local/bin/geckodriver" >> "$GITHUB_ENV"
echo "FF_BINARY_PATH=${{ needs.determine-runner.outputs.ff_binary }}" >> "$GITHUB_ENV"
geckodriver -V
- name: Setup Selenium
run: |
Expand Down Expand Up @@ -814,8 +814,6 @@ jobs:
working-directory: ./tests
run: |
set -x
export GECKODRIVER_PATH="$GECKODRIVER_PATH"
export FF_BINARY_PATH="$(which firefox)"
sudo "$LXC" exec ncp -- bash -c 'tail -f /var/log/ncp.log' |& awk '{ print "NCP::" $0 }' &
sudo "$LXC" exec ncp -- bash -c 'ncc config:system:get overwrite.cli.url'
python="$(dirname "$PWD")/.venv/bin/python"
Expand Down
11 changes: 7 additions & 4 deletions bin/ncp-dist-upgrade.d/debian-12.sh
Original file line number Diff line number Diff line change
Expand Up @@ -22,15 +22,18 @@ echo "deb [signed-by=/usr/share/keyrings/debsuryorg-archive-keyring.gpg] https:/

apt-get update
apt-get upgrade -y
for aptlist in /etc/apt/sources.list /etc/apt/sources.list.d/{php.list,armbian.list,raspi.list}
for aptlist in /etc/apt/sources.list /etc/apt/sources.list.d/{php.list,armbian.list,raspi.list,armbian-config.sources,armbian.sources,debian.sources}
do
[ -f "$aptlist" ] && sed -i -e "s/bookworm/trixie/g" "$aptlist"
done
for aptlist in /etc/apt/sources.list.d/*.list
for aptlist in /etc/apt/sources.list.d/*.list /etc/apt/sources.list.d/*.sources
do
[[ "$aptlist" =~ "/etc/apt/sources.list.d/"(php|armbian|raspi)".list" ]] || {
[[ "$aptlist" =~ "/etc/apt/sources.list.d/"(php|armbian|raspi)".list" ]] \
|| [[ "$aptlist" =~ "/etc/apt/sources.list.d/"(armbian-config|armbian|debian)".sources" ]] \
|| [[ "$aptlist" =~ "/etc/apt/sources.list.d/"("*.list"|"*.sources") ]] \
|| {
echo "Disabling repositories from \"$aptlist\""
sed -i -e "s/deb/#deb/g" "$aptlist"
sed -i -e "s/deb/#deb/g" "$aptlist" || continue;
}
done
apt-get update
Expand Down
7 changes: 3 additions & 4 deletions tests/activation_tests.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,23 +13,22 @@
"""

import sys
import time
import traceback
import urllib
import os
import getopt
import configparser
import signal
from selenium import webdriver
from selenium.webdriver.common.keys import Keys
from selenium.webdriver.common.by import By
from selenium.webdriver.firefox.service import Service
from selenium.webdriver.support import expected_conditions as EC
from selenium.webdriver.support.ui import WebDriverWait
from selenium.webdriver.firefox.options import Options
from selenium.common.exceptions import UnexpectedAlertPresentException
from selenium.common.exceptions import NoSuchElementException
from selenium.common.exceptions import TimeoutException
from tempfile import TemporaryDirectory, mkdtemp
from pathlib import Path

suite_name = "activation tests"
test_cfg = 'test_cfg.txt'
Expand Down Expand Up @@ -175,7 +174,7 @@ def test_activation(IP, nc_port, admin_port, options, webdriver_exec_path=None,
print(f"Setting geckodriver from env ({os.environ['GECKODRIVER_PATH']})")
webdriver_exec_path = os.environ['GECKODRIVER_PATH']
if 'FF_BINARY_PATH' in os.environ:
print(f"Setting firefox binary from env ({os.environ['FF_BINARY_PATH']}")
print(f"Setting firefox binary from env ({os.environ['FF_BINARY_PATH']})")
options.binary_location = os.environ['FF_BINARY_PATH']
for opt, arg in opts:
if opt in ('-h', '--help'):
Expand Down
1 change: 1 addition & 0 deletions updates/1.58.0.sh
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@

set -euo pipefail

[[ -f /usr/local/etc/ncp.cfg ]] && export NCPCFG=/usr/local/etc/ncp.cfg
source /usr/local/etc/library.sh

# PHP-FPM systemd drop-in: allow write access to NCP paths blocked by ProtectSystem=full
Expand Down
Loading