summaryrefslogtreecommitdiffstats
path: root/test/test-functions
diff options
context:
space:
mode:
authorFrantisek Sumsal <frantisek@sumsal.cz>2019-01-12 10:48:13 +0100
committerFrantisek Sumsal <frantisek@sumsal.cz>2019-01-12 11:44:39 +0100
commitd7283fc157ceb3360b21f27eee87dd794aa50f06 (patch)
treef295b4a5e54f0e44712a5652dcde65197683657e /test/test-functions
parenttest: bump QEMU_SMP to 4 when running under ASan/UBSan (diff)
downloadsystemd-d7283fc157ceb3360b21f27eee87dd794aa50f06.tar.xz
systemd-d7283fc157ceb3360b21f27eee87dd794aa50f06.zip
test: limit environments for systemd-hwdb-update under ASan
Diffstat (limited to '')
-rw-r--r--test/test-functions3
1 files changed, 2 insertions, 1 deletions
diff --git a/test/test-functions b/test/test-functions
index d9ecc65661..498dc82b18 100644
--- a/test/test-functions
+++ b/test/test-functions
@@ -360,8 +360,9 @@ printf "[Service]\nEnvironment=ASAN_OPTIONS=\$DEFAULT_ASAN_OPTIONS:log_path=/sys
# 90s isn't enough for some services to finish when literally everything is run
# under ASan+UBSan in containers, which, in turn, are run in VMs.
+# Let's limit which environments such services should be executed in.
mkdir -p /etc/systemd/system/systemd-hwdb-update.service.d
-printf "[Service]\nTimeoutSec=180s\n" >/etc/systemd/system/systemd-hwdb-update.service.d/timeout.conf
+printf "[Unit]\nConditionVirtualization=container\n\n[Service]\nTimeoutSec=180s\n" >/etc/systemd/system/systemd-hwdb-update.service.d/env-override.conf
export ASAN_OPTIONS=\$DEFAULT_ASAN_OPTIONS:log_path=/systemd.asan.log UBSAN_OPTIONS=\$DEFAULT_UBSAN_OPTIONS
exec $ROOTLIBDIR/systemd "\$@"