Skip to content

Commit

Permalink
Add maxmind secrets to the kustomize files
Browse files Browse the repository at this point in the history
  • Loading branch information
ubombar committed Mar 19, 2024
1 parent 60e5512 commit a5900f3
Show file tree
Hide file tree
Showing 3 changed files with 17 additions and 0 deletions.
1 change: 1 addition & 0 deletions config/crd/kustomization.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
resources:
# This creates problems! Find a better solution
# - edgenet_system_namespace.yaml
- secrets/maxmind_secret.yaml
- bases/multitenancy.edge-net.io_tenants.yaml
- bases/multitenancy.edge-net.io_tenantresourcequotas.yaml
#+kubebuilder:scaffold:crdkustomizeresource
Expand Down
11 changes: 11 additions & 0 deletions config/crd/secrets/maxmind_secret.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
# https://kubernetes.io/docs/concepts/configuration/secret/
apiVersion: v1
kind: Secret
metadata:
name: maxmind-secret
namespace: edgenet-system
type: Opaque
data:
# Specify the maxmind accountid and the access token here in base64 encoding to enable nodelabeller.
maxmind_accountid: ""
maxmind_token: ""
5 changes: 5 additions & 0 deletions config/manager/manager.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -76,6 +76,11 @@ spec:
- --disabled-reconcilers=""
image: controller
name: manager
volumeMounts:
# Try to mount the secret where it is filled in the secrets/maxmind_secret.yaml
# The controller trys to read from the 1. args, 2. environment variables, 3. the secrets in this path.
- mountPath: "/var/run/secrets/edge-net.io/maxmind-secret"
name: "maxmind-secret"
securityContext:
allowPrivilegeEscalation: false
capabilities:
Expand Down

0 comments on commit a5900f3

Please sign in to comment.