REFACTOR(repo): restructure monitoring folder

- and add namespace resou...
- Remove argocd/, helm-values/, ingress/ subdirectories
- Move files to parent directory (argocd.yaml, helm-values.yaml,
  ingress.yaml)
- Update helm valueFiles paths in ArgoCD Applications
- Add namespace.yaml to all applications with Goldilocks labels
- Update destination namespaces to match folder names
- Update kustomization.yaml files to reference new structure
This commit is contained in:
2025-12-29 00:49:04 +09:00
parent 01c10141a9
commit 5c4676ca9a
33 changed files with 94 additions and 32 deletions

View File

@@ -15,7 +15,7 @@ spec:
targetRevision: 1.29.0 targetRevision: 1.29.0
helm: helm:
valueFiles: valueFiles:
- $values/alertmanager/helm-values/alertmanager.yaml - $values/alertmanager/helm-values.yaml
# Values file from Git repository # Values file from Git repository
- repoURL: https://gitea0213.kro.kr/bluemayne/monitoring.git - repoURL: https://gitea0213.kro.kr/bluemayne/monitoring.git
targetRevision: main targetRevision: main
@@ -23,7 +23,7 @@ spec:
destination: destination:
server: https://kubernetes.default.svc server: https://kubernetes.default.svc
namespace: monitoring namespace: alertmanager
syncPolicy: syncPolicy:
automated: automated:

View File

@@ -2,5 +2,7 @@ apiVersion: kustomize.config.k8s.io/v1beta1
kind: Kustomization kind: Kustomization
resources: resources:
# ArgoCD Application 리소스는 infrastructure/kustomization.yaml에서 관리 # ArgoCD Application 리소스는 monitoring/kustomization.yaml에서 관리
# - argocd/alertmanager.yaml # - argocd.yaml
- namespace.yaml

View File

@@ -0,0 +1,6 @@
apiVersion: v1
kind: Namespace
metadata:
name: alertmanager
labels:
goldilocks.fairwinds.com/enabled: "true"

View File

@@ -15,7 +15,7 @@ spec:
targetRevision: 8.0.2 targetRevision: 8.0.2
helm: helm:
valueFiles: valueFiles:
- $values/goldilocks/helm-values/goldilocks.yaml - $values/goldilocks/helm-values.yaml
# Values file from Git repository # Values file from Git repository
- repoURL: https://gitea0213.kro.kr/bluemayne/monitoring.git - repoURL: https://gitea0213.kro.kr/bluemayne/monitoring.git
targetRevision: main targetRevision: main

View File

@@ -3,7 +3,7 @@ kind: Kustomization
resources: resources:
# ArgoCD Application 리소스는 monitoring/kustomization.yaml에서 관리 # ArgoCD Application 리소스는 monitoring/kustomization.yaml에서 관리
# - argocd/goldilocks.yaml # - argocd.yaml
# Goldilocks Dashboard Ingress - namespace.yaml
- ingress/goldilocks-dashboard-ingress.yaml - ingress.yaml

View File

@@ -0,0 +1,6 @@
apiVersion: v1
kind: Namespace
metadata:
name: goldilocks
labels:
goldilocks.fairwinds.com/enabled: "true"

View File

@@ -15,7 +15,7 @@ spec:
targetRevision: 10.3.0 targetRevision: 10.3.0
helm: helm:
valueFiles: valueFiles:
- $values/grafana/helm-values/grafana.yaml - $values/grafana/helm-values.yaml
# Values file from Git repository # Values file from Git repository
- repoURL: https://gitea0213.kro.kr/bluemayne/monitoring.git - repoURL: https://gitea0213.kro.kr/bluemayne/monitoring.git
targetRevision: main targetRevision: main
@@ -27,7 +27,7 @@ spec:
destination: destination:
server: https://kubernetes.default.svc server: https://kubernetes.default.svc
namespace: monitoring namespace: grafana
syncPolicy: syncPolicy:
automated: automated:

View File

@@ -2,7 +2,9 @@ apiVersion: kustomize.config.k8s.io/v1beta1
kind: Kustomization kind: Kustomization
resources: resources:
# ArgoCD Application 리소스는 infrastructure/kustomization.yaml에서 관리 # ArgoCD Application 리소스는 monitoring/kustomization.yaml에서 관리
# - argocd/grafana.yaml # - argocd.yaml
- namespace.yaml
- vault/grafana-admin-password.yaml - vault/grafana-admin-password.yaml
- ingress.yaml - ingress.yaml

6
grafana/namespace.yaml Normal file
View File

@@ -0,0 +1,6 @@
apiVersion: v1
kind: Namespace
metadata:
name: grafana
labels:
goldilocks.fairwinds.com/enabled: "true"

View File

@@ -15,7 +15,7 @@ spec:
targetRevision: 5.25.1 targetRevision: 5.25.1
helm: helm:
valueFiles: valueFiles:
- $values/kube-state-metrics/helm-values/kube-state-metrics.yaml - $values/kube-state-metrics/helm-values.yaml
# Values file from Git repository # Values file from Git repository
- repoURL: https://gitea0213.kro.kr/bluemayne/monitoring.git - repoURL: https://gitea0213.kro.kr/bluemayne/monitoring.git
targetRevision: main targetRevision: main
@@ -23,7 +23,7 @@ spec:
destination: destination:
server: https://kubernetes.default.svc server: https://kubernetes.default.svc
namespace: monitoring namespace: kube-state-metrics
syncPolicy: syncPolicy:
automated: automated:

View File

@@ -2,5 +2,7 @@ apiVersion: kustomize.config.k8s.io/v1beta1
kind: Kustomization kind: Kustomization
resources: resources:
# ArgoCD Application 리소스는 infrastructure/kustomization.yaml에서 관리 # ArgoCD Application 리소스는 monitoring/kustomization.yaml에서 관리
# - argocd/kube-state-metrics.yaml # - argocd.yaml
- namespace.yaml

View File

@@ -0,0 +1,6 @@
apiVersion: v1
kind: Namespace
metadata:
name: kube-state-metrics
labels:
goldilocks.fairwinds.com/enabled: "true"

View File

@@ -11,13 +11,13 @@ spec:
targetRevision: 6.24.0 targetRevision: 6.24.0
helm: helm:
valueFiles: valueFiles:
- $values/loki/helm-values/loki.yaml - $values/loki/helm-values.yaml
- repoURL: https://gitea0213.kro.kr/bluemayne/monitoring.git - repoURL: https://gitea0213.kro.kr/bluemayne/monitoring.git
targetRevision: HEAD targetRevision: HEAD
ref: values ref: values
destination: destination:
server: https://kubernetes.default.svc server: https://kubernetes.default.svc
namespace: logging namespace: loki
syncPolicy: syncPolicy:
automated: automated:
prune: true prune: true

View File

@@ -2,5 +2,7 @@ apiVersion: kustomize.config.k8s.io/v1beta1
kind: Kustomization kind: Kustomization
resources: resources:
# ArgoCD Application 리소스는 infrastructure/kustomization.yaml에서 관리 # ArgoCD Application 리소스는 monitoring/kustomization.yaml에서 관리
# - argocd/loki.yaml # - argocd.yaml
- namespace.yaml

6
loki/namespace.yaml Normal file
View File

@@ -0,0 +1,6 @@
apiVersion: v1
kind: Namespace
metadata:
name: loki
labels:
goldilocks.fairwinds.com/enabled: "true"

View File

@@ -15,7 +15,7 @@ spec:
targetRevision: 4.39.0 targetRevision: 4.39.0
helm: helm:
valueFiles: valueFiles:
- $values/node-exporter/helm-values/node-exporter.yaml - $values/node-exporter/helm-values.yaml
# Values file from Git repository # Values file from Git repository
- repoURL: https://gitea0213.kro.kr/bluemayne/monitoring.git - repoURL: https://gitea0213.kro.kr/bluemayne/monitoring.git
targetRevision: main targetRevision: main
@@ -23,7 +23,7 @@ spec:
destination: destination:
server: https://kubernetes.default.svc server: https://kubernetes.default.svc
namespace: monitoring namespace: node-exporter
syncPolicy: syncPolicy:
automated: automated:

View File

@@ -2,5 +2,7 @@ apiVersion: kustomize.config.k8s.io/v1beta1
kind: Kustomization kind: Kustomization
resources: resources:
# ArgoCD Application 리소스는 infrastructure/kustomization.yaml에서 관리 # ArgoCD Application 리소스는 monitoring/kustomization.yaml에서 관리
# - argocd/node-exporter.yaml # - argocd.yaml
- namespace.yaml

View File

@@ -0,0 +1,6 @@
apiVersion: v1
kind: Namespace
metadata:
name: node-exporter
labels:
goldilocks.fairwinds.com/enabled: "true"

View File

@@ -15,7 +15,7 @@ spec:
targetRevision: 80.0.0 targetRevision: 80.0.0
helm: helm:
valueFiles: valueFiles:
- $values/prometheus/helm-values/kube-prometheus-stack.yaml - $values/prometheus/helm-values.yaml
# Values file from Git repository # Values file from Git repository
- repoURL: https://gitea0213.kro.kr/bluemayne/monitoring.git - repoURL: https://gitea0213.kro.kr/bluemayne/monitoring.git
targetRevision: main targetRevision: main
@@ -27,7 +27,7 @@ spec:
destination: destination:
server: https://kubernetes.default.svc server: https://kubernetes.default.svc
namespace: monitoring namespace: prometheus
syncPolicy: syncPolicy:
automated: automated:

View File

@@ -2,6 +2,8 @@ apiVersion: kustomize.config.k8s.io/v1beta1
kind: Kustomization kind: Kustomization
resources: resources:
# ArgoCD Application 리소스는 infrastructure/kustomization.yaml에서 관리 # ArgoCD Application 리소스는 monitoring/kustomization.yaml에서 관리
# - argocd/prometheus.yaml # - argocd.yaml
- namespace.yaml
- vault/postgresql-password.yaml - vault/postgresql-password.yaml

View File

@@ -0,0 +1,6 @@
apiVersion: v1
kind: Namespace
metadata:
name: prometheus
labels:
goldilocks.fairwinds.com/enabled: "true"

View File

@@ -11,13 +11,13 @@ spec:
targetRevision: 6.16.6 targetRevision: 6.16.6
helm: helm:
valueFiles: valueFiles:
- $values/promtail/helm-values/promtail.yaml - $values/promtail/helm-values.yaml
- repoURL: https://gitea0213.kro.kr/bluemayne/monitoring.git - repoURL: https://gitea0213.kro.kr/bluemayne/monitoring.git
targetRevision: HEAD targetRevision: HEAD
ref: values ref: values
destination: destination:
server: https://kubernetes.default.svc server: https://kubernetes.default.svc
namespace: logging namespace: promtail
syncPolicy: syncPolicy:
automated: automated:
prune: true prune: true

View File

@@ -2,5 +2,7 @@ apiVersion: kustomize.config.k8s.io/v1beta1
kind: Kustomization kind: Kustomization
resources: resources:
# ArgoCD Application 리소스는 infrastructure/kustomization.yaml에서 관리 # ArgoCD Application 리소스는 monitoring/kustomization.yaml에서 관리
# - argocd/promtail.yaml # - argocd.yaml
- namespace.yaml

6
promtail/namespace.yaml Normal file
View File

@@ -0,0 +1,6 @@
apiVersion: v1
kind: Namespace
metadata:
name: promtail
labels:
goldilocks.fairwinds.com/enabled: "true"