diff options
author | Chris Evich <cevich@redhat.com> | 2021-09-15 13:45:08 -0400 |
---|---|---|
committer | Chris Evich <cevich@redhat.com> | 2021-09-27 10:37:31 -0400 |
commit | f76fa3475d247bb60f7d1fd40eecc487b97b9c18 (patch) | |
tree | aa3e02e8b2350872f1e1f1fc1945d215190e7959 /contrib/cirrus/runner.sh | |
parent | e27470ba97ae3dda32fb06b408da786f2b25a25d (diff) | |
download | podman-f76fa3475d247bb60f7d1fd40eecc487b97b9c18.tar.gz podman-f76fa3475d247bb60f7d1fd40eecc487b97b9c18.tar.bz2 podman-f76fa3475d247bb60f7d1fd40eecc487b97b9c18.zip |
Cirrus: Add gitlab podman runner test
Add execution of the downstream gitlab-runner tests using
rootless podman through the magic of socket-level
docker compatibility. Include a comment suggesting how
to temporarily disable the test in case it fails beyond
podman code scope.
Signed-off-by: Chris Evich <cevich@redhat.com>
Diffstat (limited to 'contrib/cirrus/runner.sh')
-rwxr-xr-x | contrib/cirrus/runner.sh | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/contrib/cirrus/runner.sh b/contrib/cirrus/runner.sh index 128398c38..22a66dd08 100755 --- a/contrib/cirrus/runner.sh +++ b/contrib/cirrus/runner.sh @@ -286,6 +286,23 @@ function _run_release() { msg "All OK" } + +function _run_gitlab() { + rootless_uid=$(id -u) + systemctl enable --now --user podman.socket + export DOCKER_HOST=unix:///run/user/${rootless_uid}/podman/podman.sock + export CONTAINER_HOST=$DOCKER_HOST + cd $GOPATH/src/gitlab.com/gitlab-org/gitlab-runner + set +e + go test -v ./executors/docker |& tee $GOSRC/gitlab-runner-podman.log + ret=$? + set -e + # This file is collected and parsed by Cirrus-CI so must be in $GOSRC + cat $GOSRC/gitlab-runner-podman.log | \ + go-junit-report > $GOSRC/gitlab-runner-podman.xml + return $ret +} + logformatter() { if [[ "$CI" == "true" ]]; then # Use similar format as human-friendly task name from .cirrus.yml |