aboutsummaryrefslogtreecommitdiff
path: root/test/system/260-sdnotify.bats
diff options
context:
space:
mode:
authorEd Santiago <santiago@redhat.com>2020-08-13 14:55:10 -0600
committerEd Santiago <santiago@redhat.com>2020-08-13 19:16:25 -0600
commit60ab5f3ae66e04be83ec4f83ad4b29b6e294110c (patch)
treee9cb4bfb904a2ee3c79da25ba7e71e45bc75db71 /test/system/260-sdnotify.bats
parent81499a5c470797221abca6facbfe27ccf7c6cbdb (diff)
downloadpodman-60ab5f3ae66e04be83ec4f83ad4b29b6e294110c.tar.gz
podman-60ab5f3ae66e04be83ec4f83ad4b29b6e294110c.tar.bz2
podman-60ab5f3ae66e04be83ec4f83ad4b29b6e294110c.zip
system tests: enable sdnotify tests
Oops. PR #6693 (sdnotify) added tests, but they were disabled due to broken crun on f31. I tried for three weeks to get a magic CI:IMG PR to update crun on the CI VMs ... but in that time I forgot to actually enable those new tests. This PR removes a 'skip', replacing it with a check that systemd is running plus one more to make sure our runtime is crun. It looks like sdnotify just doesn't work on Ubuntu (it hangs), and my guess is that it's a crun/runc issue. I also changed the test image from fedora:latest to :31, because, sigh, fedora:latest removed the systemd-notify tool. WARNING WARNING WARNING: the symptom of a missing systemd-notify is that podman will hang forever, not even stopped by the timeout command in podman_run! (Filed: #7316). This means that if the sdnotify-in-container test ever fails, the symptom will be that Cirrus itself will time out (2 hours?). This is horrible. I don't know what to do about it other than push for a fix for 7316. Signed-off-by: Ed Santiago <santiago@redhat.com>
Diffstat (limited to 'test/system/260-sdnotify.bats')
-rw-r--r--test/system/260-sdnotify.bats13
1 files changed, 10 insertions, 3 deletions
diff --git a/test/system/260-sdnotify.bats b/test/system/260-sdnotify.bats
index c37eea15a..6bc9fc02e 100644
--- a/test/system/260-sdnotify.bats
+++ b/test/system/260-sdnotify.bats
@@ -12,8 +12,15 @@ _SOCAT_LOG=
function setup() {
skip_if_remote
- # TODO: remove this once CI systems have newer crun and container-selinux
- skip "TEMPORARY SKIP - until CI systems get new crun, container-selinux"
+ # Skip if systemd is not running
+ systemctl list-units &>/dev/null || skip "systemd not available"
+
+ # sdnotify fails with runc 1.0.0-3-dev2 on Ubuntu. Let's just
+ # assume that we work only with crun, nothing else.
+ run_podman info --format '{{ .Host.OCIRuntime.Name }}'
+ if [[ "$output" != "crun" ]]; then
+ skip "this test only works with crun, not '$output'"
+ fi
basic_setup
}
@@ -107,7 +114,7 @@ function _assert_mainpid_is_conmon() {
@test "sdnotify : container" {
# Sigh... we need to pull a humongous image because it has systemd-notify.
# FIXME: is there a smaller image we could use?
- _FEDORA=registry.fedoraproject.org/fedora:latest
+ _FEDORA=registry.fedoraproject.org/fedora:31
# Pull that image. Retry in case of flakes.
run_podman pull $_FEDORA || \