Skip to content

Commit

Permalink
feat: switch to use published kustomize in the nidhogg repo
Browse files Browse the repository at this point in the history
  • Loading branch information
josmo committed Mar 29, 2024
1 parent 3ea4508 commit 5860506
Show file tree
Hide file tree
Showing 7 changed files with 38 additions and 308 deletions.
47 changes: 11 additions & 36 deletions gitops/components/nidhogg/kustomize/kustomization.yaml
Original file line number Diff line number Diff line change
@@ -1,44 +1,19 @@
apiVersion: kustomize.config.k8s.io/v1beta1
kind: Kustomization

# Adds namespace to all resources.
namespace: nidhogg-system

# Value of this field is prepended to the
# names of all resources, e.g. a deployment named
# "wordpress" becomes "alices-wordpress".
# Note that it should also match with the prefix (text before '-') of the namespace
# field above.
namePrefix: nidhogg-

resources:
- ./resources.yaml
- ./rbac.yaml
- ./leader-election-rbac.yaml

#patches:
# Expose the prometheus metrics on default port
# - target:
# group: apps
# version: v1
# kind: StatefulSet
# path: ./overlays/nidhogg-statefulset-prometheus-patch.yaml

images:
- name: ghcr.io/pelotech/nidhogg:v0.5.0
newTag: latest
- https://github.com/pelotech/nidhogg//kustomize?ref=v0.5.1

replacements:
- source:
patches:
- path: overlays/nidhogg-controller-manager.yaml
target:
group: apps
kind: StatefulSet
name: nidhogg-controller-manager
version: v1
kind: Secret
name: webhook-server-secret
fieldPath: metadata.name
targets:
- select:
group: apps
version: v1
kind: StatefulSet
name: controller-manager
fieldPaths:
- spec.template.spec.containers.0.env.[name=SECRET_NAME].value
- path: overlays/nidhogg-config-patch.yaml
target:
kind: ConfigMap
name: nidhogg-config
28 changes: 0 additions & 28 deletions gitops/components/nidhogg/kustomize/leader-election-rbac.yaml

This file was deleted.

Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
apiVersion: v1
data:
config.json: |
{
"taintNamePrefix": "nidhogg.uswitch.com",
"taintRemovalDelayInSeconds": 10,
"nodeSelector": [
"pelo.tech/multi-home-networking"
],
"daemonsets": [
{
"name": "kube-multus-ds",
"namespace": "kube-system"
}
]
}
kind: ConfigMap
metadata:
name: nidhogg-config
namespace: nidhogg-system
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
- op: add
path: /spec/template/spec/tolerations
value:
- effect: NoSchedule
operator: Exists
- key: CriticalAddonsOnly
operator: Exists

This file was deleted.

105 changes: 0 additions & 105 deletions gitops/components/nidhogg/kustomize/rbac.yaml

This file was deleted.

121 changes: 0 additions & 121 deletions gitops/components/nidhogg/kustomize/resources.yaml

This file was deleted.

0 comments on commit 5860506

Please sign in to comment.