#!/bin/sh set -o errexit export PATH=${PATH}:./bin # define the OCI binary to be used. Acceptable values are `docker`, `podman`. # Defaults to `docker`. OCI_BIN="${OCI_BIN:-docker}" kind_network='kind' reg_name='kind-registry' reg_port='5000' running="$($OCI_BIN inspect -f '{{.State.Running}}' "${reg_name}" 2>/dev/null || true)" if [ "${running}" != 'true' ]; then # run registry and push the multus image $OCI_BIN run -d --restart=always -p "${reg_port}:5000" --name "${reg_name}" registry:2 $OCI_BIN build -t localhost:5000/multus:e2e -f ../images/Dockerfile .. $OCI_BIN push localhost:5000/multus:e2e fi reg_host="${reg_name}" if [ "${kind_network}" = "bridge" ]; then reg_host="$($OCI_BIN inspect -f '{{.NetworkSettings.IPAddress}}' "${reg_name}")" fi echo "Registry Host: ${reg_host}" # deploy cluster with kind cat <