Skip to content

Commit

Permalink
e2e: Allow testing custom cni and dp image
Browse files Browse the repository at this point in the history
Let `run-e2e-conformance-virtual-ocp.sh` and
`run-e2e-conformance-virtual-cluster.sh` deploy clusters
with specific SRIOV CNI and Device Plugin images. This will
enable other projects to have full end-to-end test CI with
operator's suite.

Signed-off-by: Andrea Panattoni <apanatto@redhat.com>
  • Loading branch information
zeeke committed Oct 10, 2023
1 parent 44afc00 commit e8cf842
Show file tree
Hide file tree
Showing 2 changed files with 29 additions and 0 deletions.
15 changes: 15 additions & 0 deletions hack/run-e2e-conformance-virtual-cluster.sh
Original file line number Diff line number Diff line change
Expand Up @@ -254,6 +254,21 @@ podman push --tls-verify=false "${SRIOV_NETWORK_OPERATOR_IMAGE}"
podman push --tls-verify=false "${SRIOV_NETWORK_CONFIG_DAEMON_IMAGE}"
podman push --tls-verify=false "${SRIOV_NETWORK_WEBHOOK_IMAGE}"

if [[ -v LOCAL_SRIOV_CNI_IMAGE ]]; then
export SRIOV_CNI_IMAGE="$controller_ip:5000//sriov-cni:latest"
echo "## Pushing ${LOCAL_SRIOV_CNI_IMAGE} to cluster iamge ${SRIOV_CNI_IMAGE}"
podman tag ${LOCAL_SRIOV_CNI_IMAGE} ${SRIOV_CNI_IMAGE}
podman push ${SRIOV_CNI_IMAGE}
fi

if [[ -v LOCAL_SRIOV_DEVICE_PLUGIN_IMAGE ]]; then
export SRIOV_DEVICE_PLUGIN_IMAGE="$controller_ip:5000//sriov-network-device-plugin:latest"
echo "## Pushing ${LOCAL_SRIOV_DEVICE_PLUGIN_IMAGE} to cluster iamge ${SRIOV_SRIOV_DEVICE_PLUGIN_IMAGE}"
podman tag ${LOCAL_SRIOV_DEVICE_PLUGIN_IMAGE} ${SRIOV_SRIOV_DEVICE_PLUGIN_IMAGE}
podman push ${SRIOV_DEVICE_PLUGIN_IMAGE}
fi


# remove the crio bridge and let flannel to recreate
kcli ssh $cluster_name-ctlplane-0 << EOF
sudo su
Expand Down
14 changes: 14 additions & 0 deletions hack/run-e2e-conformance-virtual-ocp.sh
Original file line number Diff line number Diff line change
Expand Up @@ -204,6 +204,20 @@ podman push --tls-verify=false "${SRIOV_NETWORK_OPERATOR_IMAGE}"
podman push --tls-verify=false "${SRIOV_NETWORK_CONFIG_DAEMON_IMAGE}"
podman push --tls-verify=false "${SRIOV_NETWORK_WEBHOOK_IMAGE}"

if [[ -v LOCAL_SRIOV_CNI_IMAGE ]]; then
export SRIOV_CNI_IMAGE="$registry/$NAMESPACE/sriov-cni:latest"
echo "## Pushing ${LOCAL_SRIOV_CNI_IMAGE} to cluster iamge ${SRIOV_CNI_IMAGE}"
podman tag ${LOCAL_SRIOV_CNI_IMAGE} ${SRIOV_CNI_IMAGE}
podman push ${SRIOV_CNI_IMAGE}
fi

if [[ -v LOCAL_SRIOV_DEVICE_PLUGIN_IMAGE ]]; then
export SRIOV_DEVICE_PLUGIN_IMAGE="$registry/$NAMESPACE/sriov-network-device-plugin:latest"
echo "## Pushing ${LOCAL_SRIOV_DEVICE_PLUGIN_IMAGE} to cluster iamge ${SRIOV_SRIOV_DEVICE_PLUGIN_IMAGE}"
podman tag ${LOCAL_SRIOV_DEVICE_PLUGIN_IMAGE} ${SRIOV_SRIOV_DEVICE_PLUGIN_IMAGE}
podman push ${SRIOV_DEVICE_PLUGIN_IMAGE}
fi

podman logout $registry

echo "## apply CRDs"
Expand Down

0 comments on commit e8cf842

Please sign in to comment.