Add ingress status update functionality to support various deployment modes
- Introduced `ingressStatus` configuration in Helm values to enable status updates and customize deployment modes (auto, daemonset, nodeport, clusterip). - Implemented logic in the processor to detect deployment mode, retrieve ingress addresses, and update ingress status dynamically. - Updated Kubernetes manifests to grant required permissions for `ingresses/status` operations and pass necessary environment variables for configuration. - Adjusted Helm templates and associated Kubernetes examples to reflect the new ingress status update capability.
This commit is contained in:
parent
c8f8320cfe
commit
542fab1607
8 changed files with 312 additions and 37 deletions
|
|
@ -17,7 +17,7 @@ rules:
|
|||
resources:
|
||||
# - configmaps
|
||||
# - endpoints
|
||||
# - nodes
|
||||
- nodes
|
||||
- pods
|
||||
- services
|
||||
- namespaces
|
||||
|
|
@ -31,19 +31,18 @@ rules:
|
|||
- "networking.k8s.io"
|
||||
resources:
|
||||
- ingresses
|
||||
# - ingresses/status
|
||||
- ingresses/status
|
||||
- ingressclasses
|
||||
verbs:
|
||||
- get
|
||||
- list
|
||||
- watch
|
||||
# - apiGroups:
|
||||
# - "extensions"
|
||||
# - "networking.k8s.io"
|
||||
# resources:
|
||||
# - ingresses/status
|
||||
# verbs:
|
||||
# - update
|
||||
- apiGroups:
|
||||
- "networking.k8s.io"
|
||||
resources:
|
||||
- ingresses/status
|
||||
verbs:
|
||||
- patch
|
||||
- apiGroups:
|
||||
- ""
|
||||
resources:
|
||||
|
|
|
|||
|
|
@ -77,4 +77,18 @@ spec:
|
|||
{{- if .Values.easyhaproxy.certbot.email }}
|
||||
- name: EASYHAPROXY_CERTBOT_EMAIL
|
||||
value: {{ .Values.easyhaproxy.certbot.email }}
|
||||
{{ end }}
|
||||
{{- end }}
|
||||
- name: POD_NAMESPACE
|
||||
valueFrom:
|
||||
fieldRef:
|
||||
fieldPath: metadata.namespace
|
||||
- name: EASYHAPROXY_UPDATE_INGRESS_STATUS
|
||||
value: {{ .Values.ingressStatus.enabled | quote }}
|
||||
- name: EASYHAPROXY_DEPLOYMENT_MODE
|
||||
value: {{ .Values.ingressStatus.deploymentMode | quote }}
|
||||
{{- if .Values.ingressStatus.externalHostname }}
|
||||
- name: EASYHAPROXY_EXTERNAL_HOSTNAME
|
||||
value: {{ .Values.ingressStatus.externalHostname | quote }}
|
||||
{{- end }}
|
||||
- name: EASYHAPROXY_STATUS_UPDATE_INTERVAL
|
||||
value: {{ .Values.ingressStatus.updateInterval | quote }}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue