Skip to content

Commit

Permalink
feat(kube-nas): setup kubelet-csr-approver and metrics-server
Browse files Browse the repository at this point in the history
  • Loading branch information
tyriis committed Oct 15, 2023
1 parent cccc6b9 commit ea0cf53
Show file tree
Hide file tree
Showing 8 changed files with 110 additions and 0 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
---
# yaml-language-server: $schema=https://raw.githubusercontent.com/fluxcd-community/flux2-schemas/main/helmrelease-helm-v2beta1.json
apiVersion: helm.toolkit.fluxcd.io/v2beta1
kind: HelmRelease
metadata:
name: kubelet-csr-approver
namespace: kube-system
spec:
interval: 30m
chart:
spec:
chart: kubelet-csr-approver
version: 1.0.5
sourceRef:
kind: HelmRepository
name: postfinance-charts
namespace: flux-system
interval: 30m
values:
providerRegex: |
^(kube-nas)$
replicas: 1
bypassDnsResolution: true
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
---
# yaml-language-server: $schema=https://json.schemastore.org/kustomization
apiVersion: kustomize.config.k8s.io/v1beta1
kind: Kustomization
namespace: kube-system
resources:
- ./helm-release.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
---
# yaml-language-server: $schema=https://raw.githubusercontent.com/fluxcd-community/flux2-schemas/main/kustomization-kustomize-v1beta2.json
apiVersion: kustomize.toolkit.fluxcd.io/v1beta2
kind: Kustomization
metadata:
name: apps-kubelet-csr-approver
namespace: flux-system
labels:
substitution.flux.home.arpa/enabled: "true"
spec:
interval: 10m
path: ./kubernetes/kube-nas/apps/kube-system/kubelet-csr-approver/app
prune: true
sourceRef:
kind: GitRepository
name: home-ops
wait: true
timeout: 3m
8 changes: 8 additions & 0 deletions kubernetes/kube-nas/apps/kube-system/kustomization.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
---
# yaml-language-server: $schema=https://json.schemastore.org/kustomization
apiVersion: kustomize.config.k8s.io/v1beta1
kind: Kustomization
resources:
- ./namespace.yaml
- ./kubelet-csr-approver/flux-sync.yaml
- ./metrics-server/flux-sync.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
---
# yaml-language-server: $schema=https://raw.githubusercontent.com/fluxcd-community/flux2-schemas/main/helmrelease-helm-v2beta1.json
apiVersion: helm.toolkit.fluxcd.io/v2beta1
kind: HelmRelease
metadata:
name: metrics-server
spec:
interval: 30m
chart:
spec:
chart: metrics-server
version: 3.11.0
sourceRef:
kind: HelmRepository
name: metrics-server-charts
namespace: flux-system
interval: 30m
values:
metrics:
enabled: true
serviceMonitor:
# TODO: enable me after mini prom setup
enabled: false
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
---
# yaml-language-server: $schema=https://json.schemastore.org/kustomization
apiVersion: kustomize.config.k8s.io/v1beta1
kind: Kustomization
namespace: kube-system
resources:
- ./helm-release.yaml
17 changes: 17 additions & 0 deletions kubernetes/kube-nas/apps/kube-system/metrics-server/flux-sync.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
---
# yaml-language-server: $schema=https://raw.githubusercontent.com/fluxcd-community/flux2-schemas/main/kustomization-kustomize-v1beta2.json
apiVersion: kustomize.toolkit.fluxcd.io/v1beta2
kind: Kustomization
metadata:
name: apps-metrics-server
namespace: flux-system
labels:
substitution.flux.home.arpa/enabled: "true"
spec:
interval: 10m
path: ./kubernetes/kube-nas/apps/kube-system/metrics-server/app
prune: true
sourceRef:
kind: GitRepository
name: home-ops
wait: true
7 changes: 7 additions & 0 deletions kubernetes/kube-nas/apps/kube-system/namespace.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
---
apiVersion: v1
kind: Namespace
metadata:
name: kube-system
labels:
kustomize.toolkit.fluxcd.io/prune: disabled

0 comments on commit ea0cf53

Please sign in to comment.