This is merely a historical archive of years 2008-2021, before the migration to mailman3.
A maintained and still updated list archive can be found at https://lists.osmocom.org/hyperkitty/list/gerrit-log@lists.osmocom.org/.
osmith gerrit-no-reply at lists.osmocom.orgosmith has uploaded this change for review. ( https://gerrit.osmocom.org/c/docker-playground/+/14781
Change subject: debian-repo-install-test: run systemd services
......................................................................
debian-repo-install-test: run systemd services
Run systemd services of Osmocom programs, to check if any are not
starting properly. Use a whitelist to determine which services must
start up, because some are currently broken.
Modify the docker run command to support changing the CPU scheduling
policy/priority in systemd service files (used by osmo-bts).
Related: OS#3369
Change-Id: Ie6385f85560fefa7e7c9dca72cb5e2e914d4507a
---
M debian-repo-install-test/jenkins.sh
M debian-repo-install-test/testdata/repo-install-test.sh
2 files changed, 58 insertions(+), 1 deletion(-)
git pull ssh://gerrit.osmocom.org:29418/docker-playground refs/changes/81/14781/1
diff --git a/debian-repo-install-test/jenkins.sh b/debian-repo-install-test/jenkins.sh
index 909aa1f..647d66b 100755
--- a/debian-repo-install-test/jenkins.sh
+++ b/debian-repo-install-test/jenkins.sh
@@ -11,7 +11,9 @@
fi
# Run the container
-# Note that this does not output anything. For debugging, add -it and remove &.
+# * This does not output anything, for debugging add -it and remove &.
+# * /run, /tmp, cgroups, SYS_ADMIN: needed for systemd
+# * SYS_NICE: needed for changing CPUScheduling{Policy,Priority} (osmo-bts systemd service files)
docker run --rm \
-v "$PWD/testdata:/testdata:ro" \
-v "$VOL_BASE_DIR:/data" \
@@ -22,6 +24,7 @@
--tmpfs /tmp \
-v /sys/fs/cgroup:/sys/fs/cgroup:ro \
--cap-add SYS_ADMIN \
+ --cap-add SYS_NICE \
"$REPO_USER/debian-stretch-systemd" \
/lib/systemd/systemd &
sleep 1
diff --git a/debian-repo-install-test/testdata/repo-install-test.sh b/debian-repo-install-test/testdata/repo-install-test.sh
index 38a982f..bbd2352 100755
--- a/debian-repo-install-test/testdata/repo-install-test.sh
+++ b/debian-repo-install-test/testdata/repo-install-test.sh
@@ -1,5 +1,29 @@
#!/bin/sh -ex
+# Systemd services that must start up successfully after installing all packages (OS#3369)
+# Disabled services:
+# * osmo-ctrl2cgi (missing config: /etc/osmocom/ctrl2cgi.ini)
+# * osmo-trap2cgi (missing config: /etc/osmocom/%N.ini)
+# * osmo-sgsn (port 2123 already used by osmo-ggsn)
+# * osmo-pcu (expects missing /tmp/pcu_bts socket)
+# * osmo-hnbgw (tries to listen on 10.23.24.1)
+# * osmo-bts-virtual (unit_id is not matching osmo-bsc's config)
+SERVICES="
+ osmo-bsc
+ osmo-gbproxy
+ osmo-ggsn
+ osmo-gtphub
+ osmo-hlr
+ osmo-mgw
+ osmo-msc
+ osmo-pcap-server
+ osmo-pcap-client
+ osmo-sip-connector
+ osmo-stp
+"
+# Services working in nightly, but not yet in latest
+SERVICES_NIGHTLY=""
+
HTTP="http://download.opensuse.org/repositories/network:/osmocom:/$FEED/Debian_9.0/"
OBS="obs://build.opensuse.org/network:osmocom:$FEED/Debian_9.0"
@@ -80,7 +104,37 @@
osmo-trx-usrp1
}
+services_check() {
+ local service
+ local services_feed="$SERVICES"
+ local failed=""
+
+ if [ "$FEED" = "nightly" ]; then
+ services_feed="$services_feed $SERVICES_NIGHTLY"
+ fi
+
+ systemctl start $services_feed
+ sleep 2
+
+ for service in $services_feed; do
+ if ! systemctl --no-pager -l status $service; then
+ failed="$failed $service"
+ fi
+ done
+
+ systemctl stop $services_feed
+
+ if [ -n "$failed" ]; then
+ set +x
+ echo
+ echo "ERROR: services failed to start: $failed"
+ echo
+ exit 1
+ fi
+}
+
check_env
configure_osmocom_repo
install_repo_packages
test_binaries
+services_check
--
To view, visit https://gerrit.osmocom.org/c/docker-playground/+/14781
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: docker-playground
Gerrit-Branch: master
Gerrit-Change-Id: Ie6385f85560fefa7e7c9dca72cb5e2e914d4507a
Gerrit-Change-Number: 14781
Gerrit-PatchSet: 1
Gerrit-Owner: osmith <osmith at sysmocom.de>
Gerrit-MessageType: newchange
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osmocom.org/pipermail/gerrit-log/attachments/20190715/1feb0eb8/attachment.htm>