From 04204fb5071ddc464581031d5e20e8c2fe6d9468 Mon Sep 17 00:00:00 2001 From: Sheogorath <sheogorath@shivering-isles.com> Date: Mon, 7 Feb 2022 00:41:21 +0100 Subject: [PATCH] fix(k8up): Allow metrics endpoint access from monitoring namespaces --- infrastructure/k8up/kustomization.yaml | 3 +++ infrastructure/k8up/networkpolicy.yaml | 10 ++++++++++ 2 files changed, 13 insertions(+) create mode 100644 infrastructure/k8up/networkpolicy.yaml diff --git a/infrastructure/k8up/kustomization.yaml b/infrastructure/k8up/kustomization.yaml index a3f14a8c4..d8d96baac 100644 --- a/infrastructure/k8up/kustomization.yaml +++ b/infrastructure/k8up/kustomization.yaml @@ -7,3 +7,6 @@ resources: - k8up-crd.yaml - release.yaml - ../../shared/networkpolicies/allow-from-same-namespace.yaml + - ../../shared/networkpolicies/allow-from-monitoring.yaml +patchesStrategicMerge: + - networkpolicy.yaml diff --git a/infrastructure/k8up/networkpolicy.yaml b/infrastructure/k8up/networkpolicy.yaml new file mode 100644 index 000000000..52b4c948f --- /dev/null +++ b/infrastructure/k8up/networkpolicy.yaml @@ -0,0 +1,10 @@ +--- +apiVersion: networking.k8s.io/v1 +kind: NetworkPolicy +metadata: + name: allow-from-monitoring +spec: + podSelector: + matchLabels: + app.kubernetes.io/instance: k8up + app.kubernetes.io/name: k8up -- GitLab