summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorOliver Smith <osmith@sysmocom.de>2020-05-26 15:12:29 +0200
committerosmith <osmith@sysmocom.de>2020-05-28 09:53:22 +0000
commit2774c914387d1539efc6d551483b863e97bdae9a (patch)
tree68d2d9df78f355a84b3edce10976057253483822
parent913a61b1f745a0d4a03f900927f866e4576aa13b (diff)
repo-install-test: integrate
Make the script run from its new location. Related: OS#4563 Change-Id: Ib6fbc4b9487a84e0c28cd8b0622ddc2d5b1dfe14
-rw-r--r--.gitignore1
-rwxr-xr-xscripts/repo-install-test.sh10
-rwxr-xr-xscripts/repo-install-test/run-inside-docker.sh2
3 files changed, 7 insertions, 6 deletions
diff --git a/.gitignore b/.gitignore
index 459f2c9..d6be3b5 100644
--- a/.gitignore
+++ b/.gitignore
@@ -10,6 +10,7 @@ _temp/
_deps/
_release_tarballs/
_docker_playground
+_repo_install_test_data/
# osmocom-nightly-packages.sh
nightly-3g_*
diff --git a/scripts/repo-install-test.sh b/scripts/repo-install-test.sh
index c0c38c5..a93fb23 100755
--- a/scripts/repo-install-test.sh
+++ b/scripts/repo-install-test.sh
@@ -1,5 +1,5 @@
#!/bin/sh
-. ../jenkins-common.sh
+. "$(dirname "$0")/common.sh"
docker_images_require "debian-repo-install-test"
[ -z "$FEED" ] && FEED="nightly"
@@ -30,8 +30,8 @@ fi
# * /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" \
+ -v "$OSMO_CI_DIR/scripts/repo-install-test:/repo-install-test:ro" \
+ -v "$OSMO_CI_DIR/_repo_install_test_data:/data" \
--name "$CONTAINER" \
-e FEED="$FEED" \
-e container=docker \
@@ -40,12 +40,12 @@ docker run --rm \
-v /sys/fs/cgroup:/sys/fs/cgroup:ro \
--cap-add SYS_ADMIN \
--cap-add SYS_NICE \
- "$REPO_USER/debian-repo-install-test" \
+ "$USER/debian-repo-install-test" \
/lib/systemd/systemd &
check_if_systemd_is_running
# Run the test script
-docker exec "$CONTAINER" /testdata/repo-install-test.sh
+docker exec "$CONTAINER" /repo-install-test/run-inside-docker.sh
ret="$?"
# Interactive shell
diff --git a/scripts/repo-install-test/run-inside-docker.sh b/scripts/repo-install-test/run-inside-docker.sh
index 63e1819..135d2d6 100755
--- a/scripts/repo-install-test/run-inside-docker.sh
+++ b/scripts/repo-install-test/run-inside-docker.sh
@@ -59,7 +59,7 @@ install_repo_packages() {
> /data/osmocom_packages_all.txt
# Remove comments from blacklist.txt (and sort it)
- grep -v "^#" /testdata/blacklist.txt | sort -u > /data/blacklist.txt
+ grep -v "^#" /repo-install-test/blacklist.txt | sort -u > /data/blacklist.txt
# Install all repo packages which are not on the blacklist
comm -23 /data/osmocom_packages_all.txt \