Skip to content

Commit

Permalink
Add minikube support for local tests
Browse files Browse the repository at this point in the history
  • Loading branch information
rhkp committed May 15, 2024
1 parent 3f4ea45 commit c608a73
Show file tree
Hide file tree
Showing 3 changed files with 20 additions and 4 deletions.
11 changes: 9 additions & 2 deletions experimental-e2e-tests-on-ubuntu-vm/cluster-up.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,15 @@
set -x
set -e

kind delete cluster
kind create cluster
if [ "$CLUSTER_TYPE" == "minikube" ]; then
echo "Using minikube cluster"
minikube delete
minikube start
else
echo "Using kind cluster"
kind delete cluster
kind create cluster
fi

kubectl apply -f https://raw.githubusercontent.com/operator-framework/operator-lifecycle-manager/master/deploy/upstream/quickstart/crds.yaml
# give the apiserver time
Expand Down
9 changes: 7 additions & 2 deletions experimental-e2e-tests-on-ubuntu-vm/mtav6v7.sh
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,12 @@ make WORKFLOW_ID="$WORKFLOW_ID" REGISTRY_REPO="$REGISTRY_REPO" LOCAL_TEST=true f

# Load workflow image
docker save quay.io/rhkp/serverless-workflow-"$WORKFLOW_ID":latest -o serverless-workflow-"$WORKFLOW_ID".tar
kind load image-archive serverless-workflow-"$WORKFLOW_ID".tar

if [ "$CLUSTER_TYPE" == "minikube" ]; then
minikube image load serverless-workflow-"$WORKFLOW_ID".tar
else
kind load image-archive serverless-workflow-"$WORKFLOW_ID".tar
fi

# Copy generated manifests
rm -rf ./manifests
Expand Down Expand Up @@ -57,4 +62,4 @@ if [ "$WORKFLOW_ID" == "mtav6.2.2" ]; then
./e2e/mtav6.2.2.sh
else
./e2e/mtav7.0.2.sh
fi
fi
4 changes: 4 additions & 0 deletions experimental-e2e-tests-on-ubuntu-vm/ubuntuvm.sh
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,10 @@ sudo wget https://github.com/mikefarah/yq/releases/latest/download/yq_linux_amd6
chmod +x ./kind
sudo mv ./kind /usr/local/bin/kind

# minikube
curl -LO https://storage.googleapis.com/minikube/releases/latest/minikube_latest_amd64.deb
sudo dpkg -i minikube_latest_amd64.deb

# kubectl
curl -LO https://dl.k8s.io/release/v1.30.0/bin/linux/amd64/kubectl
sudo install -o root -g root -m 0755 kubectl /usr/local/bin/kubectl
Expand Down

0 comments on commit c608a73

Please sign in to comment.