summaryrefslogtreecommitdiff
path: root/contrib
diff options
context:
space:
mode:
authorChris Evich <cevich@redhat.com>2022-01-26 13:05:50 -0500
committerChris Evich <cevich@redhat.com>2022-02-11 14:49:40 -0500
commit66a3be3709ae67ec14c0ecdfee3847066c90c9ae (patch)
tree75ae212365b40af4e9f8016850b360e17144b6cb /contrib
parent6b0d4d9158662501b8bf36a69d351abaa9265c84 (diff)
downloadpodman-66a3be3709ae67ec14c0ecdfee3847066c90c9ae.tar.gz
podman-66a3be3709ae67ec14c0ecdfee3847066c90c9ae.tar.bz2
podman-66a3be3709ae67ec14c0ecdfee3847066c90c9ae.zip
Cirrus: Add netavark/aardvark system test task
Also add a system-test that verifies netavark driver is in use when magic env. var. is set. Signed-off-by: Chris Evich <cevich@redhat.com>
Diffstat (limited to 'contrib')
-rw-r--r--contrib/cirrus/lib.sh24
-rwxr-xr-xcontrib/cirrus/setup_environment.sh2
2 files changed, 17 insertions, 9 deletions
diff --git a/contrib/cirrus/lib.sh b/contrib/cirrus/lib.sh
index ae538d23f..09a255e6f 100644
--- a/contrib/cirrus/lib.sh
+++ b/contrib/cirrus/lib.sh
@@ -214,16 +214,22 @@ setup_rootless() {
}
install_test_configs() {
- echo "Installing cni config, policy and registry config"
- req_env_vars GOSRC SCRIPT_BASE
- cd $GOSRC || exit 1
- install -v -D -m 644 ./cni/87-podman-bridge.conflist /etc/cni/net.d/
- # This config must always sort last in the list of networks (podman picks first one
- # as the default). This config prevents allocation of network address space used
- # by default in google cloud. https://cloud.google.com/vpc/docs/vpc#ip-ranges
- install -v -D -m 644 $SCRIPT_BASE/99-do-not-use-google-subnets.conflist /etc/cni/net.d/
-
+ msg "Installing ./test/registries.conf system-wide."
install -v -D -m 644 ./test/registries.conf /etc/containers/
+ if [[ "$TEST_ENVIRON" =~ netavark ]]; then
+ # belt-and-suspenders: any pre-existing CNI config. will spoil
+ # default use tof netavark (when both are installed).
+ rm -rf /etc/cni/net.d/*
+ else
+ echo "Installing cni config, policy and registry config"
+ req_env_vars GOSRC SCRIPT_BASE
+ cd $GOSRC || exit 1
+ install -v -D -m 644 ./cni/87-podman-bridge.conflist /etc/cni/net.d/
+ # This config must always sort last in the list of networks (podman picks first one
+ # as the default). This config prevents allocation of network address space used
+ # by default in google cloud. https://cloud.google.com/vpc/docs/vpc#ip-ranges
+ install -v -D -m 644 $SCRIPT_BASE/99-do-not-use-google-subnets.conflist /etc/cni/net.d/
+ fi
}
# Remove all files provided by the distro version of podman.
diff --git a/contrib/cirrus/setup_environment.sh b/contrib/cirrus/setup_environment.sh
index 36e53320c..4e9361152 100755
--- a/contrib/cirrus/setup_environment.sh
+++ b/contrib/cirrus/setup_environment.sh
@@ -173,6 +173,8 @@ case "$TEST_ENVIRON" in
done
restorecon -F -v $_pdir
+ # This is critical, it signals to all tests that netavark
+ # use is expected.
msg "Forcing NETWORK_BACKEND=netavark in all subsequent environments."
echo "NETWORK_BACKEND=netavark" >> /etc/ci_environment
fi