Support tuning of the ingress fallback error pages

- If the error pages service doesn't have endpoints, ingress
  will start up a default service. Allow the port for this
  service to be tunable.

Change-Id: I3f60a7cb47570459da99fcd854c453e81330b052
This commit is contained in:
Scott Hussey 2018-12-14 14:11:02 -06:00
parent 617607e426
commit bb81a1cecd
3 changed files with 6 additions and 0 deletions

View File

@ -28,6 +28,7 @@ function start () {
--status-port="${STATUS_PORT}" \ --status-port="${STATUS_PORT}" \
--healthz-port="${HEALTHZ_PORT}" \ --healthz-port="${HEALTHZ_PORT}" \
--election-id=${RELEASE_NAME} \ --election-id=${RELEASE_NAME} \
--default-server-port=${DEFAULT_ERROR_PORT} \
--ingress-class=maas-ingress \ --ingress-class=maas-ingress \
--default-backend-service=${POD_NAMESPACE}/${ERROR_PAGE_SERVICE} \ --default-backend-service=${POD_NAMESPACE}/${ERROR_PAGE_SERVICE} \
--configmap=${POD_NAMESPACE}/maas-ingress-config \ --configmap=${POD_NAMESPACE}/maas-ingress-config \

View File

@ -252,6 +252,9 @@ spec:
value: {{ tuple "maas_ingress" "podport" "status" . | include "helm-toolkit.endpoints.endpoint_port_lookup" | quote }} value: {{ tuple "maas_ingress" "podport" "status" . | include "helm-toolkit.endpoints.endpoint_port_lookup" | quote }}
- name: ERROR_PAGE_SERVICE - name: ERROR_PAGE_SERVICE
value: {{ tuple "maas_ingress" "error_pages" . | include "helm-toolkit.endpoints.hostname_short_endpoint_lookup" | quote }} value: {{ tuple "maas_ingress" "error_pages" . | include "helm-toolkit.endpoints.hostname_short_endpoint_lookup" | quote }}
- name: DEFAULT_ERROR_PORT
value: {{ tuple "maas_ingress" "default" "ingress_default_server" . | include "helm-toolkit.endpoints.endpoint_port_lookup" | quote }}
volumeMounts: volumeMounts:
- mountPath: /tmp/maas-ingress.sh - mountPath: /tmp/maas-ingress.sh
name: maas-bin name: maas-bin

View File

@ -357,6 +357,8 @@ endpoints:
error_pages: error_pages:
default: 8080 default: 8080
podport: 10080 podport: 10080
ingress_default_server:
default: 8181
healthz: healthz:
podport: 10254 podport: 10254
status: status: