diff --git a/charts/haproxy/templates/tests/test-haproxy-health.yaml b/charts/haproxy/templates/tests/test-haproxy-health.yaml index bc81891f..dd3782c7 100644 --- a/charts/haproxy/templates/tests/test-haproxy-health.yaml +++ b/charts/haproxy/templates/tests/test-haproxy-health.yaml @@ -37,6 +37,14 @@ spec: image: {{ .Values.images.tags.test }} imagePullPolicy: {{ .Values.images.pull_policy }} {{ tuple . .Values.pod.resources.test | include "helm-toolkit.snippets.kubernetes_resources" | indent 6 }} - command: ["/bin/sh", "-c", "wget --no-check-certificate --spider ${HAPROXY_URL}; exit $?"] + command: + - /bin/bash + - -c + - |- + CODE=$(curl -k -s -o /dev/null -w "%{http_code}" ${HAPROXY_URL}) + if [ $CODE -ne 000 ]; then + exit 0 + fi + exit 1 ... {{- end }} diff --git a/charts/haproxy/values.yaml b/charts/haproxy/values.yaml index 4114baab..2c772ccb 100644 --- a/charts/haproxy/values.yaml +++ b/charts/haproxy/values.yaml @@ -61,7 +61,7 @@ images: tags: anchor: gcr.io/google_containers/hyperkube-amd64:v1.10.2 haproxy: haproxy:1.8.3 - test: busybox:1.28.3 + test: python:3.6 pull_policy: "IfNotPresent" manifests: