Skip to content

Commit 7c67048

Browse files
committed
K8S-513 check root ingress for rancher
1 parent e1c0760 commit 7c67048

File tree

1 file changed

+17
-2
lines changed

1 file changed

+17
-2
lines changed

manifest.jps

Lines changed: 17 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -997,11 +997,26 @@ addons:
997997
return:
998998
type: warning
999999
message: Rancher Platforms requires 'nginx' ingress controller! The current ingress controller is '${globals.ingress-dir}'
1000+
- cmd[${nodes.k8sm.master.id}]: |-
1001+
kubectl delete -f ${baseUrl}/addons/ingress/${globals.ingress-dir}/helloworld-ingress.yaml ||:
1002+
kubectl delete -f ${baseUrl}/addons/helloworld.yaml ||:
1003+
- cmd[${nodes.k8sm.master.id}]: |-
1004+
http_code=$(curl -Lks -o /dev/null -w "%{http_code}" "${env.url}")
1005+
ret_code=$?
1006+
if [ ${ret_code} -ne 0 ]; then
1007+
echo "An error occurred while accessing the [endpoint](${env.url})"
1008+
elif [ ${http_code} -eq 200 ]; then
1009+
echo "The [endpoint](${env.url}) is already taken"
1010+
elif [ ${http_code} -ne 404 ]; then
1011+
echo "The [endpoint](${env.url}) is present and answered with HTTP code ${http_code}"
1012+
fi
1013+
- if ('${response.out}'):
1014+
return:
1015+
type: warning
1016+
message: Cannot deploy Rancher UI! ${response.out}.
10001017
- cmd[${nodes.k8sm.master.id}]: |-
10011018
helm repo add rancher-stable https://releases.rancher.com/server-charts/stable
10021019
helm repo update
1003-
kubectl delete -f ${baseUrl}/addons/ingress/${globals.ingress-dir}/helloworld-ingress.yaml
1004-
kubectl delete -f ${baseUrl}/addons/helloworld.yaml
10051020
helm install rancher rancher-stable/rancher --create-namespace --namespace cattle-system --set tls=external
10061021
kubectl -n cattle-system rollout status deploy/rancher
10071022
- message.email.send:

0 commit comments

Comments
 (0)