Skip to content

Commit f60a1f8

Browse files
tedhtchangopenshift-ci[bot]
authored andcommitted
pull image from quay.io
1 parent 12e9903 commit f60a1f8

File tree

1 file changed

+39
-39
lines changed

1 file changed

+39
-39
lines changed

Diff for: hack/run-e2e-kind.sh

+39-39
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ export LOG_LEVEL=${TEST_LOG_LEVEL:-2}
3131
export CLEANUP_CLUSTER=${CLEANUP_CLUSTER:-"true"}
3232
export CLUSTER_CONTEXT="--name test"
3333
# Using older image due to older version of kubernetes cluster"
34-
export IMAGE_ECHOSERVER="kicbase/echo-server:1.0"
34+
export IMAGE_ECHOSERVER="quay.io/project-codeflare/echo-server:1.0"
3535
export IMAGE_UBUNTU_LATEST="ubuntu:latest"
3636
export IMAGE_UBI_LATEST="registry.access.redhat.com/ubi8/ubi:latest"
3737
export IMAGE_BUSY_BOX_LATEST="k8s.gcr.io/busybox:latest"
@@ -49,7 +49,7 @@ export KUTTL_TEST_SUITES=("${ROOT_DIR}/test/kuttl-test.yaml" "${ROOT_DIR}/test/k
4949
DUMP_LOGS="true"
5050

5151
function update_test_host {
52-
52+
5353
local arch="$(go env GOARCH)"
5454
if [ -z $arch ]
5555
then
@@ -67,43 +67,43 @@ function update_test_host {
6767

6868
which kubectl >/dev/null 2>&1
6969
if [ $? -ne 0 ]
70-
then
70+
then
7171
sudo apt-get install -y --allow-unauthenticated kubectl
72-
[ $? -ne 0 ] && echo "Failed to install kubectl" && exit 1
73-
echo "kubectl was sucessfully installed."
74-
fi
75-
72+
[ $? -ne 0 ] && echo "Failed to install kubectl" && exit 1
73+
echo "kubectl was sucessfully installed."
74+
fi
75+
7676
which kind >/dev/null 2>&1
77-
if [ $? -ne 0 ]
77+
if [ $? -ne 0 ]
7878
then
7979
# Download kind binary (0.20.0)
8080
echo "Downloading and installing kind...."
8181
sudo curl -o /usr/local/bin/kind -L https://github.com/kubernetes-sigs/kind/releases/download/v0.20.0/kind-linux-${arch} && \
82-
sudo chmod +x /usr/local/bin/kind
83-
[ $? -ne 0 ] && echo "Failed to download kind" && exit 1
84-
echo "Kind was sucessfully installed."
82+
sudo chmod +x /usr/local/bin/kind
83+
[ $? -ne 0 ] && echo "Failed to download kind" && exit 1
84+
echo "Kind was sucessfully installed."
8585
fi
8686

8787
which helm >/dev/null 2>&1
8888
if [ $? -ne 0 ]
89-
then
89+
then
9090
# Installing helm3
9191
echo "Downloading and installing helm..."
92-
curl -fsSL -o ${ROOT_DIR}/get_helm.sh https://raw.githubusercontent.com/helm/helm/main/scripts/get-helm-3 &&
92+
curl -fsSL -o ${ROOT_DIR}/get_helm.sh https://raw.githubusercontent.com/helm/helm/main/scripts/get-helm-3 &&
9393
chmod 700 ${ROOT_DIR}/get_helm.sh && ${ROOT_DIR}/get_helm.sh
9494
[ $? -ne 0 ] && echo "Failed to download and install helm" && exit 1
9595
echo "Helm was sucessfully installed."
9696
rm -rf ${ROOT_DIR}/get_helm.sh
9797
fi
98-
98+
9999
kubectl kuttl version >/dev/null 2>&1
100100
if [ $? -ne 0 ]
101101
then
102102
if [[ "$arch" == "amd64" ]]
103-
then
103+
then
104104
local kuttl_arch="x86_64"
105105
else
106-
local kuttl_arch=$arch
106+
local kuttl_arch=$arch
107107
fi
108108
# Download kuttl plugin
109109
echo "Downloading and installing kuttl...."
@@ -119,7 +119,7 @@ function update_test_host {
119119
function check-prerequisites {
120120
echo "checking prerequisites"
121121
which kind >/dev/null 2>&1
122-
if [ $? -ne 0 ]
122+
if [ $? -ne 0 ]
123123
then
124124
echo "kind not installed, exiting."
125125
exit 1
@@ -133,7 +133,7 @@ function check-prerequisites {
133133
echo "kubectl not installed, exiting."
134134
exit 1
135135
else
136-
echo -n "found kubectl, " && kubectl version
136+
echo -n "found kubectl, " && kubectl version
137137
fi
138138
kubectl kuttl version >/dev/null 2>&1
139139
if [ $? -ne 0 ]
@@ -143,7 +143,7 @@ function check-prerequisites {
143143
else
144144
echo -n "found kuttl plugin for kubectl, " && kubectl kuttl version
145145
fi
146-
146+
147147
if [[ $IMAGE_REPOSITORY_MCAD == "" ]]
148148
then
149149
echo "No MCAD image was provided."
@@ -155,25 +155,25 @@ function check-prerequisites {
155155
else
156156
echo "end to end test with ${IMAGE_MCAD}."
157157
fi
158-
158+
159159
which helm >/dev/null 2>&1
160160
if [ $? -ne 0 ]
161161
then
162162
echo "helm not installed, exiting."
163163
exit 1
164164
else
165165
echo -n "found helm, " && helm version --short
166-
fi
166+
fi
167+
167168

168-
169169
which helm >/dev/null 2>&1
170170
if [ $? -ne 0 ]
171171
then
172172
echo "helm not installed, exiting."
173173
exit 1
174174
else
175175
echo -n "found helm, " && helm version --short
176-
fi
176+
fi
177177

178178
}
179179

@@ -193,7 +193,7 @@ function kind-up-cluster {
193193
fi
194194
CLUSTER_STARTED="true"
195195

196-
docker pull ${IMAGE_ECHOSERVER}
196+
docker pull ${IMAGE_ECHOSERVER}
197197
if [ $? -ne 0 ]
198198
then
199199
echo "Failed to pull ${IMAGE_ECHOSERVER}"
@@ -213,14 +213,14 @@ function kind-up-cluster {
213213
echo "Failed to pull ${IMAGE_UBI_LATEST}"
214214
exit 1
215215
fi
216-
216+
217217
docker pull ${IMAGE_BUSY_BOX_LATEST}
218218
if [ $? -ne 0 ]
219219
then
220220
echo "Failed to pull ${IMAGE_BUSY_BOX_LATEST}"
221221
exit 1
222222
fi
223-
223+
224224
if [[ "$MCAD_IMAGE_PULL_POLICY" = "Always" ]]
225225
then
226226
docker pull ${IMAGE_MCAD}
@@ -245,7 +245,7 @@ function kind-up-cluster {
245245
echo "Failed to load image ${image} in cluster"
246246
exit 1
247247
fi
248-
done
248+
done
249249
}
250250

251251
# clean up
@@ -256,7 +256,7 @@ function cleanup {
256256
then
257257
echo "Cluster was not started, nothing more to do."
258258
return
259-
fi
259+
fi
260260

261261
if [[ ${DUMP_LOGS} == "true" ]]
262262
then
@@ -303,15 +303,15 @@ function cleanup {
303303
kubectl logs ${mcad_pod} -n kube-system
304304
fi
305305
fi
306-
306+
307307
rm -f kubeconfig
308-
308+
309309
if [[ $CLEANUP_CLUSTER == "true" ]]
310310
then
311-
kind delete cluster ${CLUSTER_CONTEXT}
312-
else
313-
echo "Cluster requested to stay up, not deleting cluster"
314-
fi
311+
kind delete cluster ${CLUSTER_CONTEXT}
312+
else
313+
echo "Cluster requested to stay up, not deleting cluster"
314+
fi
315315
}
316316

317317
function undeploy_mcad_helm {
@@ -348,10 +348,10 @@ function mcad-up {
348348
function setup-mcad-env {
349349
echo "Installing Podgroup CRD"
350350
kubectl apply -f https://raw.githubusercontent.com/kubernetes-sigs/scheduler-plugins/277b6bdec18f8a9e9ccd1bfeaf4b66495bfc6f92/config/crd/bases/scheduling.sigs.k8s.io_podgroups.yaml
351-
351+
352352
# Turn off master taints
353353
kubectl taint nodes --all node-role.kubernetes.io/control-plane:NoSchedule-
354-
354+
355355
# This is meant to orchestrate initial cluster configuration such that accounting tests can be consistent
356356
echo "Orchestrate cluster..."
357357
echo "kubectl cordon test-worker"
@@ -369,7 +369,7 @@ function setup-mcad-env {
369369
echo "Waiting for pod in the kube-system namespace to be ready to become ready"
370370
while [[ $(kubectl get pods -n kube-system -o 'jsonpath={..status.conditions[?(@.type=="Ready")].status}' | tr ' ' '\n' | sort -u) != "True" ]]
371371
do
372-
echo -n "." && sleep 1;
372+
echo -n "." && sleep 1;
373373
done
374374
}
375375

@@ -451,15 +451,15 @@ function kuttl-tests {
451451
then
452452
echo "Failed to delete quotasubtrees for test: '${kuttl_test}'"
453453
exit 1
454-
fi
454+
fi
455455
undeploy_mcad_helm
456456
done
457457
rm -f kubeconfig
458458
}
459459

460460
trap cleanup EXIT
461461
update_test_host
462-
check-prerequisites
462+
check-prerequisites
463463
kind-up-cluster
464464
extend-resources
465465
setup-mcad-env

0 commit comments

Comments
 (0)