Skip to content

Commit

Permalink
fix: adapted patch for mutating webhook to correctly add release name…
Browse files Browse the repository at this point in the history
…space to exclusions (#1044)

Signed-off-by: Florian Bacher <florian.bacher@dynatrace.com>
  • Loading branch information
bacherfl committed Mar 15, 2023
1 parent 90052bc commit d7cfc17
Show file tree
Hide file tree
Showing 2 changed files with 24 additions and 2 deletions.
2 changes: 1 addition & 1 deletion helm/chart/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ annotations:
artifacthub.io/operator: "true"
artifacthub.io/operatorCapabilities: "Full Lifecycle"

kubeVersion: ">= 1.24.0"
kubeVersion: ">= 1.24.0-0"
# A chart can be either an 'application' or a 'library' chart.
#
# Application charts are a collection of templates that can be packaged into versioned archives
Expand Down
24 changes: 23 additions & 1 deletion helm/overlay/kustomization.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -21,5 +21,27 @@ patches:
- '{{ .Release.Namespace }}'
target:
kind: MutatingWebhookConfiguration
name: "(mutating-webhook-configuration)"
name: "(lifecycle-mutating-webhook-configuration)"
- patch: |
- op: replace
path: '/spec/service/namespace'
value: '{{ .Release.Namespace }}'
- op: replace
path: '/spec/service/name'
value: '{{ include "chart.fullname" . }}-metrics-operator-service'
target:
kind: APIService
name: "(v1beta2.custom.metrics.k8s.io)"
- patch: |
- op: replace
path: '/spec/service/namespace'
value: '{{ .Release.Namespace }}'
- op: replace
path: '/spec/service/name'
value: '{{ include "chart.fullname" . }}-metrics-operator-service'
target:
kind: APIService
name: "(v1beta1.custom.metrics.k8s.io)"

0 comments on commit d7cfc17

Please sign in to comment.