diff --git a/Makefile b/Makefile index 78c0625..89ed8fe 100644 --- a/Makefile +++ b/Makefile @@ -22,13 +22,13 @@ REGISTRY_IS_OCI = $(shell echo $(REGISTRY_REPO) | grep -q oci && echo true || ec TEMPLATE_FOLDERS = $(patsubst $(TEMPLATES_DIR)/%,%,$(wildcard $(TEMPLATES_DIR)/*)) -COLLECTORS_VERSION=$(shell $(YQ) '.version' $(TEMPLATES_DIR)/motel-collectors/Chart.yaml) -STORAGE_VERSION=$(shell $(YQ) '.version' $(TEMPLATES_DIR)/motel-storage/Chart.yaml) +COLLECTORS_VERSION=$(shell $(YQ) '.version' $(TEMPLATES_DIR)/kof-collectors/Chart.yaml) +STORAGE_VERSION=$(shell $(YQ) '.version' $(TEMPLATES_DIR)/kof-storage/Chart.yaml) USER_EMAIL=$(shell git config user.email) -STORAGE_DOMAIN = $(USER)-storage.$(MOTEL_DNS) -MOTEL_STORAGE_NAME = motel-storage -MOTEL_STORAGE_NS = motel +STORAGE_DOMAIN = $(USER)-storage.$(KOF_DNS) +KOF_STORAGE_NAME = kof-storage +KOF_STORAGE_NG = kof dev: mkdir -p dev @@ -42,6 +42,7 @@ package-chart-%: lint-chart-% .PHONY: helm-package helm-package: $(CHARTS_PACKAGE_DIR) $(EXTENSION_CHARTS_PACKAGE_DIR) + rm -rf $(CHARTS_PACKAGE_DIR) @make $(patsubst %,package-chart-%,$(TEMPLATE_FOLDERS)) .PHONY: helm-push @@ -78,66 +79,66 @@ helm-push: helm-package done .PHONY: dev-operators-deploy -dev-operators-deploy: dev ## Deploy motel-operators helm chart to the K8s cluster specified in ~/.kube/config - cp -f $(TEMPLATES_DIR)/motel-operators/values.yaml dev/operators-values.yaml - $(HELM) upgrade -i motel-operators ./charts/motel-operators --create-namespace -n motel -f dev/operators-values.yaml +dev-operators-deploy: dev ## Deploy kof-operators helm chart to the K8s cluster specified in ~/.kube/config + cp -f $(TEMPLATES_DIR)/kof-operators/values.yaml dev/operators-values.yaml + $(HELM) upgrade -i kof-operators ./charts/kof-operators --create-namespace -n kof -f dev/operators-values.yaml .PHONY: dev-collectors-deploy -dev-collectors-deploy: dev ## Deploy motel-collector helm chart to the K8s cluster specified in ~/.kube/config - cp -f $(TEMPLATES_DIR)/motel-collectors/values.yaml dev/collectors-values.yaml - @$(YQ) eval -i '.motel.logs.endpoint = "http://$(MOTEL_STORAGE_NAME)-victoria-logs-single-server.$(MOTEL_STORAGE_NS):9428/insert/opentelemetry/v1/logs"' dev/collectors-values.yaml - @$(YQ) eval -i '.motel.metrics.endpoint = "http://vminsert-cluster.$(MOTEL_STORAGE_NS):8480/insert/0/prometheus/api/v1/write"' dev/collectors-values.yaml - @$(YQ) eval -i '.opencost.opencost.prometheus.external.url = "http://vmselect-cluster.$(MOTEL_STORAGE_NS):8481/select/0/prometheus"' dev/collectors-values.yaml - $(HELM) upgrade -i motel-collectors ./charts/motel-collectors --create-namespace -n motel -f dev/collectors-values.yaml +dev-collectors-deploy: dev ## Deploy kof-collector helm chart to the K8s cluster specified in ~/.kube/config + cp -f $(TEMPLATES_DIR)/kof-collectors/values.yaml dev/collectors-values.yaml + @$(YQ) eval -i '.kof.logs.endpoint = "http://$(KOF_STORAGE_NAME)-victoria-logs-single-server.$(KOF_STORAGE_NG):9428/insert/opentelemetry/v1/logs"' dev/collectors-values.yaml + @$(YQ) eval -i '.kof.metrics.endpoint = "http://vminsert-cluster.$(KOF_STORAGE_NG):8480/insert/0/prometheus/api/v1/write"' dev/collectors-values.yaml + @$(YQ) eval -i '.opencost.opencost.prometheus.external.url = "http://vmselect-cluster.$(KOF_STORAGE_NG):8481/select/0/prometheus"' dev/collectors-values.yaml + $(HELM) upgrade -i kof-collectors ./charts/kof-collectors --create-namespace -n kof -f dev/collectors-values.yaml .PHONY: dev-storage-deploy -dev-storage-deploy: dev ## Deploy motel-storage helm chart to the K8s cluster specified in ~/.kube/config - cp -f $(TEMPLATES_DIR)/motel-storage/values.yaml dev/storage-values.yaml +dev-storage-deploy: dev ## Deploy kof-storage helm chart to the K8s cluster specified in ~/.kube/config + cp -f $(TEMPLATES_DIR)/kof-storage/values.yaml dev/storage-values.yaml @$(YQ) eval -i '.grafana.ingress.enabled = false' dev/storage-values.yaml @$(YQ) eval -i '.victoriametrics.vmcluster.replicaCount = 1' dev/storage-values.yaml @$(YQ) eval -i '.global.storageClass = "standard"' dev/storage-values.yaml @$(YQ) eval -i '.["victoria-logs-single"].server.persistentVolume.storageClassName = "standard"' dev/storage-values.yaml - $(HELM) upgrade -i $(MOTEL_STORAGE_NAME) ./charts/motel-storage --create-namespace -n $(MOTEL_STORAGE_NS) -f dev/storage-values.yaml + $(HELM) upgrade -i $(KOF_STORAGE_NAME) ./charts/kof-storage --create-namespace -n $(KOF_STORAGE_NG) -f dev/storage-values.yaml .PHONY: dev-ms-deploy-aws dev-ms-deploy-aws: dev ## Deploy Mothership helm chart to the K8s cluster specified in ~/.kube/config for a remote storage cluster - cp -f $(TEMPLATES_DIR)/motel-mothership/values.yaml dev/mothership-values.yaml - @$(YQ) eval -i '.hmc.installTemplates = true' dev/mothership-values.yaml + cp -f $(TEMPLATES_DIR)/kof-mothership/values.yaml dev/mothership-values.yaml + @$(YQ) eval -i '.kcm.installTemplates = true' dev/mothership-values.yaml @$(YQ) eval -i '.grafana.logSources = [{"name": "$(USER)-storage", "url": "https://vmauth.$(STORAGE_DOMAIN)/vls", "type": "victoriametrics-logs-datasource", "auth": {"credentials_secret_name": "grafana-admin-credentials"}}]' dev/mothership-values.yaml @$(YQ) eval -i '.promxy.config.serverGroups = [{"clusterName": "$(USER)-storage", "targets": ["vmauth.$(STORAGE_DOMAIN):443"], "auth": {"credentials_secret_name": "grafana-admin-credentials"}}]' dev/mothership-values.yaml - @$(YQ) eval -i '.hmc.motel.charts.collectors.version = "$(COLLECTORS_VERSION)"' dev/mothership-values.yaml - @$(YQ) eval -i '.hmc.motel.charts.storage.version = "$(STORAGE_VERSION)"' dev/mothership-values.yaml + @$(YQ) eval -i '.kcm.kof.charts.collectors.version = "$(COLLECTORS_VERSION)"' dev/mothership-values.yaml + @$(YQ) eval -i '.kcm.kof.charts.storage.version = "$(STORAGE_VERSION)"' dev/mothership-values.yaml @if [ "$(REGISTRY_REPO)" = "oci://127.0.0.1:$(REGISTRY_PORT)/charts" ]; then \ - $(YQ) eval -i '.hmc.motel.repo.url = "oci://$(REGISTRY_NAME):5000/charts"' dev/mothership-values.yaml; \ - $(YQ) eval -i '.hmc.motel.repo.insecure = true' dev/mothership-values.yaml; \ - $(YQ) eval -i '.hmc.motel.repo.type = "oci"' dev/mothership-values.yaml; \ + $(YQ) eval -i '.kcm.kof.repo.url = "oci://$(REGISTRY_NAME):5000/charts"' dev/mothership-values.yaml; \ + $(YQ) eval -i '.kcm.kof.repo.insecure = true' dev/mothership-values.yaml; \ + $(YQ) eval -i '.kcm.kof.repo.type = "oci"' dev/mothership-values.yaml; \ else \ - $(YQ) eval -i '.hmc.motel.repo.url = "$(REGISTRY_REPO)"' dev/mothership-values.yaml; \ + $(YQ) eval -i '.kcm.kof.repo.url = "$(REGISTRY_REPO)"' dev/mothership-values.yaml; \ fi; \ - $(HELM) upgrade -i motel ./charts/motel-mothership -n motel --create-namespace -f dev/mothership-values.yaml + $(HELM) upgrade -i kof ./charts/kof-mothership -n kof --create-namespace -f dev/mothership-values.yaml .PHONY: dev-storage-deploy-aws -dev-storage-deploy-aws: dev ## Deploy Regional Managed cluster using HMC +dev-storage-deploy-aws: dev ## Deploy Regional Managed cluster using KCM cp -f demo/cluster/aws-storage.yaml dev/aws-storage.yaml @$(YQ) eval -i '.metadata.name = "$(USER)-aws-storage"' dev/aws-storage.yaml - @$(YQ) '.spec.services[] | select(.name == "motel-storage") | .values' dev/aws-storage.yaml > dev/motel-storage-values.yaml - @$(YQ) eval -i '.["cert-manager"].email = "$(USER_EMAIL)"' dev/motel-storage-values.yaml - @$(YQ) eval -i '.victoriametrics.vmauth.ingress.host = "vmauth.$(STORAGE_DOMAIN)"' dev/motel-storage-values.yaml - @$(YQ) eval -i '.grafana.ingress.host = "grafana.$(STORAGE_DOMAIN)"' dev/motel-storage-values.yaml - @$(YQ) eval -i '.["external-dns"].enabled = true' dev/motel-storage-values.yaml - @$(YQ) eval -i '(.spec.services[] | select(.name == "motel-storage")).values |= load_str("dev/motel-storage-values.yaml")' dev/aws-storage.yaml + @$(YQ) '.spec.services[] | select(.name == "kof-storage") | .values' dev/aws-storage.yaml > dev/kof-storage-values.yaml + @$(YQ) eval -i '.["cert-manager"].email = "$(USER_EMAIL)"' dev/kof-storage-values.yaml + @$(YQ) eval -i '.victoriametrics.vmauth.ingress.host = "vmauth.$(STORAGE_DOMAIN)"' dev/kof-storage-values.yaml + @$(YQ) eval -i '.grafana.ingress.host = "grafana.$(STORAGE_DOMAIN)"' dev/kof-storage-values.yaml + @$(YQ) eval -i '.["external-dns"].enabled = true' dev/kof-storage-values.yaml + @$(YQ) eval -i '(.spec.services[] | select(.name == "kof-storage")).values |= load_str("dev/kof-storage-values.yaml")' dev/aws-storage.yaml kubectl apply -f dev/aws-storage.yaml .PHONY: dev-managed-deploy-aws -dev-managed-deploy-aws: dev ## Deploy Regional Managed cluster using HMC +dev-managed-deploy-aws: dev ## Deploy Regional Managed cluster using KCM cp -f demo/cluster/aws-managed.yaml dev/aws-managed.yaml @$(YQ) eval -i '.metadata.name = "$(USER)-aws-managed"' dev/aws-managed.yaml - @$(YQ) '.spec.services[] | select(.name == "motel-collectors") | .values' dev/aws-managed.yaml > dev/motel-managed-values.yaml - @$(YQ) eval -i '.opencost.opencost.prometheus.external.url = "https://vmauth.$(STORAGE_DOMAIN)/vm/select/0/prometheus"' dev/motel-managed-values.yaml - @$(YQ) eval -i '.motel.logs.endpoint = "https://vmauth.$(STORAGE_DOMAIN)/vls/insert/opentelemetry/v1/logs"' dev/motel-managed-values.yaml - @$(YQ) eval -i '.motel.metrics.endpoint = "https://vmauth.$(STORAGE_DOMAIN)/vm/insert/0/prometheus/api/v1/write"' dev/motel-managed-values.yaml - @$(YQ) eval -i '(.spec.services[] | select(.name == "motel-collectors")).values |= load_str("dev/motel-managed-values.yaml")' dev/aws-managed.yaml + @$(YQ) '.spec.services[] | select(.name == "kof-collectors") | .values' dev/aws-managed.yaml > dev/kof-managed-values.yaml + @$(YQ) eval -i '.opencost.opencost.prometheus.external.url = "https://vmauth.$(STORAGE_DOMAIN)/vm/select/0/prometheus"' dev/kof-managed-values.yaml + @$(YQ) eval -i '.kof.logs.endpoint = "https://vmauth.$(STORAGE_DOMAIN)/vls/insert/opentelemetry/v1/logs"' dev/kof-managed-values.yaml + @$(YQ) eval -i '.kof.metrics.endpoint = "https://vmauth.$(STORAGE_DOMAIN)/vm/insert/0/prometheus/api/v1/write"' dev/kof-managed-values.yaml + @$(YQ) eval -i '(.spec.services[] | select(.name == "kof-collectors")).values |= load_str("dev/kof-managed-values.yaml")' dev/aws-managed.yaml kubectl apply -f dev/aws-managed.yaml ## Tool Binaries diff --git a/README.md b/README.md index e3ba587..564aae7 100644 --- a/README.md +++ b/README.md @@ -1,15 +1,16 @@ -# Mirantis OpenTelemery -This repo contains 4 charts to deploy a monitoring stack using HMC and get metrics into storage clusters, data from which is then aggregated into single grafana interface. +# K0rdent Observability and FinOps +This repo contains 4 charts to deploy an observability stack using [k0rdent](https://github.com/K0rdent/kcm) and get [OpenTelemetry](https://opentelemetry.io/) data into storage clusters aggregated into single grafana interface. + ![alt text](docs/otel.png) ## Mothership chart * central grafana interface * promxy to forward calls to multiple downstream regional metrics servers * local victoriametrics storage for alerting record rules -* hmc helmchart definitions and service templates to deploy storage and collectors charts into managedclusters +* k0rdent helmchart definitions and service templates to deploy storage and collectors charts into managedclusters ### Demo deployment -In `demo/demo-mothership-values.yaml` set your target ingress names that you are going to use for your regional clusters, but they can always be changed after the fact +In `demo/demo-mothership-values.yaml` set your target ingress names that you are going to use for your storage clusters, but they can always be changed after the fact Create secrets for grafana admin user and storage clusters datasources endpoint access. By default the secret below be reused everywhere, but it is customizable. @@ -19,7 +20,7 @@ kind: Secret apiVersion: v1 metadata: name: grafana-admin-credentials - namespace: motel + namespace: kof stringData: GF_SECURITY_ADMIN_USER: username # Grafana username GF_SECURITY_ADMIN_PASSWORD: password # Grafana password @@ -27,13 +28,16 @@ type: Opaque ``` ```bash -helm repo add motel https://mirantis.github.io/motel/ +helm repo add kof https://mirantis.github.io/kof/ helm repo update -helm upgrade -i motel motel/motel-mothership -n motel -f demo/demo-mothership-values.yaml +helm upgrade -i kof-mothership kof/kof-mothership -n kof -f demo/demo-mothership-values.yaml ``` ## Storage chart -* Grafana - region-specific Grafana instance, deployed and configured with grafana-operator + +Deploys metrics and logs [VictoriaMetrics](https://victoriametrics.com/) storages. + +* Grafana - storage-cluster scoped Grafana instance, deployed and configured with grafana-operator * vmcluster - metrics storage, ingestion, querying * vmlogs - logs storage * vmauth - auth frontend for metrics and logs ingestion and query services @@ -42,7 +46,7 @@ helm upgrade -i motel motel/motel-mothership -n motel -f demo/demo-mothership-va - cert-manager - ingress-nginx -To deploy storage `managedcluster` configure desired ingress names for vmauth and regional Grafana in it's values for the `motel-storage` template. +To deploy storage `clusterdeployment` configure desired ingress names for vmauth and regional Grafana in it's values for the `kof-storage` template. `demo/cluster/aws-storage.yaml` contains example definitions ```bash @@ -50,7 +54,7 @@ kubectl apply -f demo/cluster/aws-storage.yaml # you can check helm chart deployment status using ClusterSummary object: kubectl get clustersummaries.config.projectsveltos.io -n hmc-system ``` -Once the storage managedcluster is ready - retrieve its kubeconfig and get loadbalancer IP/DNS name for your ingress-nginx service. +Once the storage clusterdeploymet is ready - retrieve its kubeconfig and get loadbalancer IP/DNS name for your ingress-nginx service. ```bash kubectl get secret -n hmc-system aws-storage-kubeconfig -o jsonpath={.data.value} | base64 -d > /tmp/hmc-aws-storage-kubeconfig.yaml @@ -74,7 +78,7 @@ This chart pre-installs all required CRDs to create Opentelemetry Collectors for ## Collectors chart * opentelemetry-collectors - [OpenTelemetry Collector](https://opentelemetry.io/docs/collector/) configured to monitor logs and metrics and send them to a storage cluster -To deploy operators and collectors to a `managedcluster` configure ingress names for storage vmauth in its values for the `motel-collectors` template. +To deploy operators and collectors to a `clusterdeployment` configure ingress names for storage vmauth in its values for the `kof-collectors` template. ``` kubectl apply -f demo/cluster/aws-managed.yaml diff --git a/charts/motel-collectors/Chart.lock b/charts/kof-collectors/Chart.lock similarity index 100% rename from charts/motel-collectors/Chart.lock rename to charts/kof-collectors/Chart.lock diff --git a/charts/motel-collectors/Chart.yaml b/charts/kof-collectors/Chart.yaml similarity index 96% rename from charts/motel-collectors/Chart.yaml rename to charts/kof-collectors/Chart.yaml index b9f4ffe..faf3b17 100644 --- a/charts/motel-collectors/Chart.yaml +++ b/charts/kof-collectors/Chart.yaml @@ -1,5 +1,5 @@ apiVersion: v2 -name: motel-collectors +name: kof-collectors description: A Helm chart that deploys OpenTelemetryCollector resources version: 0.0.1 appVersion: "1.0" diff --git a/charts/motel-collectors/templates/_helpers.tpl b/charts/kof-collectors/templates/_helpers.tpl similarity index 51% rename from charts/motel-collectors/templates/_helpers.tpl rename to charts/kof-collectors/templates/_helpers.tpl index 00d78f5..3a10f5d 100644 --- a/charts/motel-collectors/templates/_helpers.tpl +++ b/charts/kof-collectors/templates/_helpers.tpl @@ -1,12 +1,12 @@ {{- /* Basic auth extensions */ -}} {{- define "basic_auth_extensions" -}} {{- range tuple "metrics" "logs" }} -{{- $secret := (lookup "v1" "Secret" $.Release.Namespace (index $.Values "motel" . "credentials_secret_name")) }} +{{- $secret := (lookup "v1" "Secret" $.Release.Namespace (index $.Values "kof" . "credentials_secret_name")) }} {{- if $secret }} basicauth/{{ . }}: client_auth: - username: {{ index $secret.data (index $.Values "motel" . "username_key") | b64dec | quote }} - password: {{ index $secret.data (index $.Values "motel" . "password_key") | b64dec | quote }} + username: {{ index $secret.data (index $.Values "kof" . "username_key") | b64dec | quote }} + password: {{ index $secret.data (index $.Values "kof" . "password_key") | b64dec | quote }} {{- end }} {{- end }} {{- end }} diff --git a/charts/motel-collectors/templates/opentelemetry/clusterrolebindings/k8s-cluster-collector.yaml b/charts/kof-collectors/templates/opentelemetry/clusterrolebindings/k8s-cluster-collector.yaml similarity index 100% rename from charts/motel-collectors/templates/opentelemetry/clusterrolebindings/k8s-cluster-collector.yaml rename to charts/kof-collectors/templates/opentelemetry/clusterrolebindings/k8s-cluster-collector.yaml diff --git a/charts/motel-collectors/templates/opentelemetry/clusterrolebindings/node-exporter-ta.yaml b/charts/kof-collectors/templates/opentelemetry/clusterrolebindings/node-exporter-ta.yaml similarity index 100% rename from charts/motel-collectors/templates/opentelemetry/clusterrolebindings/node-exporter-ta.yaml rename to charts/kof-collectors/templates/opentelemetry/clusterrolebindings/node-exporter-ta.yaml diff --git a/charts/motel-collectors/templates/opentelemetry/clusterroles/k8s-cluster-collector.yaml b/charts/kof-collectors/templates/opentelemetry/clusterroles/k8s-cluster-collector.yaml similarity index 100% rename from charts/motel-collectors/templates/opentelemetry/clusterroles/k8s-cluster-collector.yaml rename to charts/kof-collectors/templates/opentelemetry/clusterroles/k8s-cluster-collector.yaml diff --git a/charts/motel-collectors/templates/opentelemetry/clusterroles/node-exporter-ta.yaml b/charts/kof-collectors/templates/opentelemetry/clusterroles/node-exporter-ta.yaml similarity index 100% rename from charts/motel-collectors/templates/opentelemetry/clusterroles/node-exporter-ta.yaml rename to charts/kof-collectors/templates/opentelemetry/clusterroles/node-exporter-ta.yaml diff --git a/charts/motel-collectors/templates/opentelemetry/collector.yaml b/charts/kof-collectors/templates/opentelemetry/collector.yaml similarity index 94% rename from charts/motel-collectors/templates/opentelemetry/collector.yaml rename to charts/kof-collectors/templates/opentelemetry/collector.yaml index 2f7228a..1e72c80 100644 --- a/charts/motel-collectors/templates/opentelemetry/collector.yaml +++ b/charts/kof-collectors/templates/opentelemetry/collector.yaml @@ -41,7 +41,7 @@ spec: exporters: debug: {} prometheusremotewrite: - endpoint: {{ .Values.motel.metrics.endpoint }} + endpoint: {{ .Values.kof.metrics.endpoint }} tls: insecure: true auth: @@ -49,7 +49,7 @@ spec: otlphttp: auth: authenticator: basicauth/logs - logs_endpoint: {{ .Values.motel.logs.endpoint }} + logs_endpoint: {{ .Values.kof.logs.endpoint }} extensions: {{- include "basic_auth_extensions" . | nindent 6 }} diff --git a/charts/motel-collectors/templates/opentelemetry/node-collector.yaml b/charts/kof-collectors/templates/opentelemetry/node-collector.yaml similarity index 98% rename from charts/motel-collectors/templates/opentelemetry/node-collector.yaml rename to charts/kof-collectors/templates/opentelemetry/node-collector.yaml index 67d71d7..486ba29 100644 --- a/charts/motel-collectors/templates/opentelemetry/node-collector.yaml +++ b/charts/kof-collectors/templates/opentelemetry/node-collector.yaml @@ -132,7 +132,7 @@ spec: exporters: prometheusremotewrite: - endpoint: {{ .Values.motel.metrics.endpoint }} + endpoint: {{ .Values.kof.metrics.endpoint }} tls: insecure: true auth: @@ -140,7 +140,7 @@ spec: otlphttp: auth: authenticator: basicauth/logs - logs_endpoint: {{ .Values.motel.logs.endpoint }} + logs_endpoint: {{ .Values.kof.logs.endpoint }} debug: verbosity: detailed diff --git a/charts/motel-collectors/templates/opentelemetry/serviceaccounts/k8s-cluster-collector.yaml b/charts/kof-collectors/templates/opentelemetry/serviceaccounts/k8s-cluster-collector.yaml similarity index 100% rename from charts/motel-collectors/templates/opentelemetry/serviceaccounts/k8s-cluster-collector.yaml rename to charts/kof-collectors/templates/opentelemetry/serviceaccounts/k8s-cluster-collector.yaml diff --git a/charts/motel-collectors/templates/opentelemetry/serviceaccounts/node-exporter-ta.yaml b/charts/kof-collectors/templates/opentelemetry/serviceaccounts/node-exporter-ta.yaml similarity index 100% rename from charts/motel-collectors/templates/opentelemetry/serviceaccounts/node-exporter-ta.yaml rename to charts/kof-collectors/templates/opentelemetry/serviceaccounts/node-exporter-ta.yaml diff --git a/charts/motel-collectors/values.yaml b/charts/kof-collectors/values.yaml similarity index 99% rename from charts/motel-collectors/values.yaml rename to charts/kof-collectors/values.yaml index c202c26..8c58439 100644 --- a/charts/motel-collectors/values.yaml +++ b/charts/kof-collectors/values.yaml @@ -1,7 +1,7 @@ global: clusterLabel: clusterName clusterName: mothership -motel: +kof: logs: endpoint: http://victoria-logs-single-server:9428/insert/opentelemetry/v1/logs credentials_secret_name: grafana-admin-credentials diff --git a/charts/motel-mothership/Chart.lock b/charts/kof-mothership/Chart.lock similarity index 100% rename from charts/motel-mothership/Chart.lock rename to charts/kof-mothership/Chart.lock diff --git a/charts/motel-mothership/Chart.yaml b/charts/kof-mothership/Chart.yaml similarity index 97% rename from charts/motel-mothership/Chart.yaml rename to charts/kof-mothership/Chart.yaml index 6cba835..96845bf 100644 --- a/charts/motel-mothership/Chart.yaml +++ b/charts/kof-mothership/Chart.yaml @@ -1,5 +1,5 @@ apiVersion: v2 -name: motel-mothership +name: kof-mothership description: A Helm chart that deploys Grafana, Promxy, and VictoriaMetrics. version: 0.1.6 appVersion: "1.0" diff --git a/charts/motel-mothership/files/dashboards/kubernetes-views-global.yaml b/charts/kof-mothership/files/dashboards/kubernetes-views-global.yaml similarity index 100% rename from charts/motel-mothership/files/dashboards/kubernetes-views-global.yaml rename to charts/kof-mothership/files/dashboards/kubernetes-views-global.yaml diff --git a/charts/motel-mothership/files/dashboards/kubernetes-views-namespaces.yaml b/charts/kof-mothership/files/dashboards/kubernetes-views-namespaces.yaml similarity index 100% rename from charts/motel-mothership/files/dashboards/kubernetes-views-namespaces.yaml rename to charts/kof-mothership/files/dashboards/kubernetes-views-namespaces.yaml diff --git a/charts/motel-mothership/files/dashboards/kubernetes-views-nodes.yaml b/charts/kof-mothership/files/dashboards/kubernetes-views-nodes.yaml similarity index 100% rename from charts/motel-mothership/files/dashboards/kubernetes-views-nodes.yaml rename to charts/kof-mothership/files/dashboards/kubernetes-views-nodes.yaml diff --git a/charts/motel-mothership/files/dashboards/kubernetes-views-pods.yaml b/charts/kof-mothership/files/dashboards/kubernetes-views-pods.yaml similarity index 100% rename from charts/motel-mothership/files/dashboards/kubernetes-views-pods.yaml rename to charts/kof-mothership/files/dashboards/kubernetes-views-pods.yaml diff --git a/charts/motel-mothership/files/dashboards/node-exporter-full.yaml b/charts/kof-mothership/files/dashboards/node-exporter-full.yaml similarity index 100% rename from charts/motel-mothership/files/dashboards/node-exporter-full.yaml rename to charts/kof-mothership/files/dashboards/node-exporter-full.yaml diff --git a/charts/motel-mothership/files/dashboards/opencost-cost-reporter-basic-overview.yaml b/charts/kof-mothership/files/dashboards/opencost-cost-reporter-basic-overview.yaml similarity index 100% rename from charts/motel-mothership/files/dashboards/opencost-cost-reporter-basic-overview.yaml rename to charts/kof-mothership/files/dashboards/opencost-cost-reporter-basic-overview.yaml diff --git a/charts/motel-mothership/files/dashboards/opencost-cost-reporter-detailed-overview.yaml b/charts/kof-mothership/files/dashboards/opencost-cost-reporter-detailed-overview.yaml similarity index 100% rename from charts/motel-mothership/files/dashboards/opencost-cost-reporter-detailed-overview.yaml rename to charts/kof-mothership/files/dashboards/opencost-cost-reporter-detailed-overview.yaml diff --git a/charts/motel-mothership/files/rules/etcd.yaml b/charts/kof-mothership/files/rules/etcd.yaml similarity index 100% rename from charts/motel-mothership/files/rules/etcd.yaml rename to charts/kof-mothership/files/rules/etcd.yaml diff --git a/charts/motel-mothership/files/rules/general.rules.yaml b/charts/kof-mothership/files/rules/general.rules.yaml similarity index 100% rename from charts/motel-mothership/files/rules/general.rules.yaml rename to charts/kof-mothership/files/rules/general.rules.yaml diff --git a/charts/motel-mothership/files/rules/k8s.rules.container_cpu_limits.yaml b/charts/kof-mothership/files/rules/k8s.rules.container_cpu_limits.yaml similarity index 100% rename from charts/motel-mothership/files/rules/k8s.rules.container_cpu_limits.yaml rename to charts/kof-mothership/files/rules/k8s.rules.container_cpu_limits.yaml diff --git a/charts/motel-mothership/files/rules/k8s.rules.container_cpu_requests.yaml b/charts/kof-mothership/files/rules/k8s.rules.container_cpu_requests.yaml similarity index 100% rename from charts/motel-mothership/files/rules/k8s.rules.container_cpu_requests.yaml rename to charts/kof-mothership/files/rules/k8s.rules.container_cpu_requests.yaml diff --git a/charts/motel-mothership/files/rules/k8s.rules.container_cpu_usage_seconds_total.yaml b/charts/kof-mothership/files/rules/k8s.rules.container_cpu_usage_seconds_total.yaml similarity index 100% rename from charts/motel-mothership/files/rules/k8s.rules.container_cpu_usage_seconds_total.yaml rename to charts/kof-mothership/files/rules/k8s.rules.container_cpu_usage_seconds_total.yaml diff --git a/charts/motel-mothership/files/rules/k8s.rules.container_memory_cache.yaml b/charts/kof-mothership/files/rules/k8s.rules.container_memory_cache.yaml similarity index 100% rename from charts/motel-mothership/files/rules/k8s.rules.container_memory_cache.yaml rename to charts/kof-mothership/files/rules/k8s.rules.container_memory_cache.yaml diff --git a/charts/motel-mothership/files/rules/k8s.rules.container_memory_limits.yaml b/charts/kof-mothership/files/rules/k8s.rules.container_memory_limits.yaml similarity index 100% rename from charts/motel-mothership/files/rules/k8s.rules.container_memory_limits.yaml rename to charts/kof-mothership/files/rules/k8s.rules.container_memory_limits.yaml diff --git a/charts/motel-mothership/files/rules/k8s.rules.container_memory_requests.yaml b/charts/kof-mothership/files/rules/k8s.rules.container_memory_requests.yaml similarity index 100% rename from charts/motel-mothership/files/rules/k8s.rules.container_memory_requests.yaml rename to charts/kof-mothership/files/rules/k8s.rules.container_memory_requests.yaml diff --git a/charts/motel-mothership/files/rules/k8s.rules.container_memory_rss.yaml b/charts/kof-mothership/files/rules/k8s.rules.container_memory_rss.yaml similarity index 100% rename from charts/motel-mothership/files/rules/k8s.rules.container_memory_rss.yaml rename to charts/kof-mothership/files/rules/k8s.rules.container_memory_rss.yaml diff --git a/charts/motel-mothership/files/rules/k8s.rules.container_memory_swap.yaml b/charts/kof-mothership/files/rules/k8s.rules.container_memory_swap.yaml similarity index 100% rename from charts/motel-mothership/files/rules/k8s.rules.container_memory_swap.yaml rename to charts/kof-mothership/files/rules/k8s.rules.container_memory_swap.yaml diff --git a/charts/motel-mothership/files/rules/k8s.rules.container_memory_working_set_bytes.yaml b/charts/kof-mothership/files/rules/k8s.rules.container_memory_working_set_bytes.yaml similarity index 100% rename from charts/motel-mothership/files/rules/k8s.rules.container_memory_working_set_bytes.yaml rename to charts/kof-mothership/files/rules/k8s.rules.container_memory_working_set_bytes.yaml diff --git a/charts/motel-mothership/files/rules/k8s.rules.pod_owner.yaml b/charts/kof-mothership/files/rules/k8s.rules.pod_owner.yaml similarity index 100% rename from charts/motel-mothership/files/rules/k8s.rules.pod_owner.yaml rename to charts/kof-mothership/files/rules/k8s.rules.pod_owner.yaml diff --git a/charts/motel-mothership/files/rules/kube-prometheus-general.rules.yaml b/charts/kof-mothership/files/rules/kube-prometheus-general.rules.yaml similarity index 100% rename from charts/motel-mothership/files/rules/kube-prometheus-general.rules.yaml rename to charts/kof-mothership/files/rules/kube-prometheus-general.rules.yaml diff --git a/charts/motel-mothership/files/rules/kube-prometheus-node-recording.rules.yaml b/charts/kof-mothership/files/rules/kube-prometheus-node-recording.rules.yaml similarity index 100% rename from charts/motel-mothership/files/rules/kube-prometheus-node-recording.rules.yaml rename to charts/kof-mothership/files/rules/kube-prometheus-node-recording.rules.yaml diff --git a/charts/motel-mothership/files/rules/kube-state-metrics.yaml b/charts/kof-mothership/files/rules/kube-state-metrics.yaml similarity index 100% rename from charts/motel-mothership/files/rules/kube-state-metrics.yaml rename to charts/kof-mothership/files/rules/kube-state-metrics.yaml diff --git a/charts/motel-mothership/files/rules/kubelet.rules.yaml b/charts/kof-mothership/files/rules/kubelet.rules.yaml similarity index 100% rename from charts/motel-mothership/files/rules/kubelet.rules.yaml rename to charts/kof-mothership/files/rules/kubelet.rules.yaml diff --git a/charts/motel-mothership/files/rules/kubernetes-apps.yaml b/charts/kof-mothership/files/rules/kubernetes-apps.yaml similarity index 100% rename from charts/motel-mothership/files/rules/kubernetes-apps.yaml rename to charts/kof-mothership/files/rules/kubernetes-apps.yaml diff --git a/charts/motel-mothership/files/rules/kubernetes-resources.yaml b/charts/kof-mothership/files/rules/kubernetes-resources.yaml similarity index 100% rename from charts/motel-mothership/files/rules/kubernetes-resources.yaml rename to charts/kof-mothership/files/rules/kubernetes-resources.yaml diff --git a/charts/motel-mothership/files/rules/kubernetes-storage.yaml b/charts/kof-mothership/files/rules/kubernetes-storage.yaml similarity index 100% rename from charts/motel-mothership/files/rules/kubernetes-storage.yaml rename to charts/kof-mothership/files/rules/kubernetes-storage.yaml diff --git a/charts/motel-mothership/files/rules/kubernetes-system-apiserver.yaml b/charts/kof-mothership/files/rules/kubernetes-system-apiserver.yaml similarity index 100% rename from charts/motel-mothership/files/rules/kubernetes-system-apiserver.yaml rename to charts/kof-mothership/files/rules/kubernetes-system-apiserver.yaml diff --git a/charts/motel-mothership/files/rules/kubernetes-system-kubelet.yaml b/charts/kof-mothership/files/rules/kubernetes-system-kubelet.yaml similarity index 100% rename from charts/motel-mothership/files/rules/kubernetes-system-kubelet.yaml rename to charts/kof-mothership/files/rules/kubernetes-system-kubelet.yaml diff --git a/charts/motel-mothership/files/rules/kubernetes-system.yaml b/charts/kof-mothership/files/rules/kubernetes-system.yaml similarity index 100% rename from charts/motel-mothership/files/rules/kubernetes-system.yaml rename to charts/kof-mothership/files/rules/kubernetes-system.yaml diff --git a/charts/motel-mothership/files/rules/node-exporter.rules.yaml b/charts/kof-mothership/files/rules/node-exporter.rules.yaml similarity index 100% rename from charts/motel-mothership/files/rules/node-exporter.rules.yaml rename to charts/kof-mothership/files/rules/node-exporter.rules.yaml diff --git a/charts/motel-mothership/files/rules/node-exporter.yaml b/charts/kof-mothership/files/rules/node-exporter.yaml similarity index 100% rename from charts/motel-mothership/files/rules/node-exporter.yaml rename to charts/kof-mothership/files/rules/node-exporter.yaml diff --git a/charts/motel-mothership/files/rules/node-network.yaml b/charts/kof-mothership/files/rules/node-network.yaml similarity index 100% rename from charts/motel-mothership/files/rules/node-network.yaml rename to charts/kof-mothership/files/rules/node-network.yaml diff --git a/charts/motel-mothership/files/rules/node.rules.yaml b/charts/kof-mothership/files/rules/node.rules.yaml similarity index 100% rename from charts/motel-mothership/files/rules/node.rules.yaml rename to charts/kof-mothership/files/rules/node.rules.yaml diff --git a/charts/motel-mothership/templates/_helpers.tpl b/charts/kof-mothership/templates/_helpers.tpl similarity index 100% rename from charts/motel-mothership/templates/_helpers.tpl rename to charts/kof-mothership/templates/_helpers.tpl diff --git a/charts/motel-mothership/templates/config/vm-ingress-list.yaml b/charts/kof-mothership/templates/config/vm-ingress-list.yaml similarity index 100% rename from charts/motel-mothership/templates/config/vm-ingress-list.yaml rename to charts/kof-mothership/templates/config/vm-ingress-list.yaml diff --git a/charts/motel-mothership/templates/config/vm-secrets-map.yaml b/charts/kof-mothership/templates/config/vm-secrets-map.yaml similarity index 100% rename from charts/motel-mothership/templates/config/vm-secrets-map.yaml rename to charts/kof-mothership/templates/config/vm-secrets-map.yaml diff --git a/charts/motel-mothership/templates/grafana/alert-agg-ds.yaml b/charts/kof-mothership/templates/grafana/alert-agg-ds.yaml similarity index 100% rename from charts/motel-mothership/templates/grafana/alert-agg-ds.yaml rename to charts/kof-mothership/templates/grafana/alert-agg-ds.yaml diff --git a/charts/motel-mothership/templates/grafana/dashboards/dashboard.yaml b/charts/kof-mothership/templates/grafana/dashboards/dashboard.yaml similarity index 100% rename from charts/motel-mothership/templates/grafana/dashboards/dashboard.yaml rename to charts/kof-mothership/templates/grafana/dashboards/dashboard.yaml diff --git a/charts/motel-mothership/templates/grafana/grafana.yaml b/charts/kof-mothership/templates/grafana/grafana.yaml similarity index 100% rename from charts/motel-mothership/templates/grafana/grafana.yaml rename to charts/kof-mothership/templates/grafana/grafana.yaml diff --git a/charts/motel-mothership/templates/grafana/logs-datasource.yaml b/charts/kof-mothership/templates/grafana/logs-datasource.yaml similarity index 100% rename from charts/motel-mothership/templates/grafana/logs-datasource.yaml rename to charts/kof-mothership/templates/grafana/logs-datasource.yaml diff --git a/charts/motel-mothership/templates/grafana/metrics-datasource.yaml b/charts/kof-mothership/templates/grafana/metrics-datasource.yaml similarity index 100% rename from charts/motel-mothership/templates/grafana/metrics-datasource.yaml rename to charts/kof-mothership/templates/grafana/metrics-datasource.yaml diff --git a/charts/motel-mothership/templates/grafana/rules/rules.yaml b/charts/kof-mothership/templates/grafana/rules/rules.yaml similarity index 100% rename from charts/motel-mothership/templates/grafana/rules/rules.yaml rename to charts/kof-mothership/templates/grafana/rules/rules.yaml diff --git a/charts/motel-mothership/templates/hmc/cert-manager/flux-helm.yaml b/charts/kof-mothership/templates/hmc/cert-manager/flux-helm.yaml similarity index 93% rename from charts/motel-mothership/templates/hmc/cert-manager/flux-helm.yaml rename to charts/kof-mothership/templates/hmc/cert-manager/flux-helm.yaml index e75e69e..a816b73 100644 --- a/charts/motel-mothership/templates/hmc/cert-manager/flux-helm.yaml +++ b/charts/kof-mothership/templates/hmc/cert-manager/flux-helm.yaml @@ -1,4 +1,4 @@ -{{- if .Values.hmc.installTemplates }} +{{- if .Values.kcm.installTemplates }} --- apiVersion: source.toolkit.fluxcd.io/v1 kind: HelmRepository diff --git a/charts/motel-mothership/templates/hmc/cert-manager/svctmpl.yaml b/charts/kof-mothership/templates/hmc/cert-manager/svctmpl.yaml similarity index 88% rename from charts/motel-mothership/templates/hmc/cert-manager/svctmpl.yaml rename to charts/kof-mothership/templates/hmc/cert-manager/svctmpl.yaml index bb9107e..514a5f8 100644 --- a/charts/motel-mothership/templates/hmc/cert-manager/svctmpl.yaml +++ b/charts/kof-mothership/templates/hmc/cert-manager/svctmpl.yaml @@ -1,4 +1,4 @@ -{{- if .Values.hmc.installTemplates }} +{{- if .Values.kcm.installTemplates }} apiVersion: hmc.mirantis.com/v1alpha1 kind: ServiceTemplate metadata: diff --git a/charts/motel-mothership/templates/hmc/motel-flux-helm.yaml b/charts/kof-mothership/templates/hmc/kof-flux-helm.yaml similarity index 60% rename from charts/motel-mothership/templates/hmc/motel-flux-helm.yaml rename to charts/kof-mothership/templates/hmc/kof-flux-helm.yaml index b6fb17c..9f66545 100644 --- a/charts/motel-mothership/templates/hmc/motel-flux-helm.yaml +++ b/charts/kof-mothership/templates/hmc/kof-flux-helm.yaml @@ -1,20 +1,20 @@ -{{- if .Values.hmc.installTemplates }} -{{- range $name, $values := .Values.hmc.motel.charts }} +{{- if .Values.kcm.installTemplates }} +{{- range $name, $values := .Values.kcm.kof.charts }} --- apiVersion: source.toolkit.fluxcd.io/v1 kind: HelmChart metadata: - name: motel-{{ $name }} + name: kof-{{ $name }} namespace: hmc-system labels: hmc.mirantis.com/managed: "true" spec: - chart: motel-{{ $name }} + chart: kof-{{ $name }} interval: 10m0s reconcileStrategy: ChartVersion sourceRef: kind: HelmRepository - name: {{ $.Values.hmc.motel.repo.name }} + name: {{ $.Values.kcm.kof.repo.name }} version: {{ $values.version }} {{- end }} {{- end }} diff --git a/charts/kof-mothership/templates/hmc/kof-repo.yaml b/charts/kof-mothership/templates/hmc/kof-repo.yaml new file mode 100644 index 0000000..d90b9bb --- /dev/null +++ b/charts/kof-mothership/templates/hmc/kof-repo.yaml @@ -0,0 +1,14 @@ +{{- if .Values.kcm.installTemplates }} +--- +apiVersion: source.toolkit.fluxcd.io/v1 +kind: HelmRepository +metadata: + name: {{ .Values.kcm.kof.repo.name }} + namespace: hmc-system + labels: + hmc.mirantis.com/managed: "true" +spec: + url: {{ .Values.kcm.kof.repo.url }} + insecure: {{ .Values.kcm.kof.repo.insecure }} + type: {{ .Values.kcm.kof.repo.type }} +{{- end }} diff --git a/charts/motel-mothership/templates/hmc/motel-svctmpl.yaml b/charts/kof-mothership/templates/hmc/kof-svctmpl.yaml similarity index 63% rename from charts/motel-mothership/templates/hmc/motel-svctmpl.yaml rename to charts/kof-mothership/templates/hmc/kof-svctmpl.yaml index be8ce8e..90d6b99 100644 --- a/charts/motel-mothership/templates/hmc/motel-svctmpl.yaml +++ b/charts/kof-mothership/templates/hmc/kof-svctmpl.yaml @@ -1,17 +1,17 @@ -{{- if .Values.hmc.installTemplates }} -{{- range $name, $values := .Values.hmc.motel.charts }} +{{- if .Values.kcm.installTemplates }} +{{- range $name, $values := .Values.kcm.kof.charts }} --- apiVersion: hmc.mirantis.com/v1alpha1 kind: ServiceTemplate metadata: - name: motel-{{ $name }} + name: kof-{{ $name }} namespace: hmc-system spec: helm: chartRef: apiVersion: source.toolkit.fluxcd.io/v1 kind: HelmChart - name: motel-{{ $name }} + name: kof-{{ $name }} namespace: hmc-system providers: [] {{- end }} diff --git a/charts/motel-mothership/templates/promxy/_helpers.tpl b/charts/kof-mothership/templates/promxy/_helpers.tpl similarity index 100% rename from charts/motel-mothership/templates/promxy/_helpers.tpl rename to charts/kof-mothership/templates/promxy/_helpers.tpl diff --git a/charts/motel-mothership/templates/promxy/deployment.yaml b/charts/kof-mothership/templates/promxy/deployment.yaml similarity index 100% rename from charts/motel-mothership/templates/promxy/deployment.yaml rename to charts/kof-mothership/templates/promxy/deployment.yaml diff --git a/charts/motel-mothership/templates/promxy/ingress.yaml b/charts/kof-mothership/templates/promxy/ingress.yaml similarity index 100% rename from charts/motel-mothership/templates/promxy/ingress.yaml rename to charts/kof-mothership/templates/promxy/ingress.yaml diff --git a/charts/motel-mothership/templates/promxy/secret.yaml b/charts/kof-mothership/templates/promxy/secret.yaml similarity index 100% rename from charts/motel-mothership/templates/promxy/secret.yaml rename to charts/kof-mothership/templates/promxy/secret.yaml diff --git a/charts/motel-mothership/templates/promxy/service.yaml b/charts/kof-mothership/templates/promxy/service.yaml similarity index 100% rename from charts/motel-mothership/templates/promxy/service.yaml rename to charts/kof-mothership/templates/promxy/service.yaml diff --git a/charts/motel-mothership/templates/promxy/serviceaccount.yaml b/charts/kof-mothership/templates/promxy/serviceaccount.yaml similarity index 100% rename from charts/motel-mothership/templates/promxy/serviceaccount.yaml rename to charts/kof-mothership/templates/promxy/serviceaccount.yaml diff --git a/charts/motel-mothership/templates/victoria/vmalert.yaml b/charts/kof-mothership/templates/victoria/vmalert.yaml similarity index 100% rename from charts/motel-mothership/templates/victoria/vmalert.yaml rename to charts/kof-mothership/templates/victoria/vmalert.yaml diff --git a/charts/motel-mothership/templates/victoria/vmcluster.yaml b/charts/kof-mothership/templates/victoria/vmcluster.yaml similarity index 100% rename from charts/motel-mothership/templates/victoria/vmcluster.yaml rename to charts/kof-mothership/templates/victoria/vmcluster.yaml diff --git a/charts/motel-mothership/values.yaml b/charts/kof-mothership/values.yaml similarity index 85% rename from charts/motel-mothership/values.yaml rename to charts/kof-mothership/values.yaml index ace293f..b16bc41 100644 --- a/charts/motel-mothership/values.yaml +++ b/charts/kof-mothership/values.yaml @@ -2,12 +2,12 @@ global: clusterLabel: clusterName storageClass: standard clusterName: mothership -hmc: +kcm: installTemplates: false - motel: + kof: repo: - name: motel - url: https://mirantis.github.io/motel/ + name: kof + url: https://k0rdent.github.io/kof/ insecure: false type: "default" charts: @@ -34,13 +34,13 @@ grafana: alerts: enabled: true logSources: - - name: hmc0-logs - url: https://vmauth.hmc0.example.net/vls + - name: storage0-logs + url: https://vmauth.storage0.example.net/vls type: victoriametrics-logs-datasource auth: credentials_secret_name: grafana-admin-credentials - - name: hmc1-logs - url: https://vmauth.hmc1.example.net/vls + - name: storage1-logs + url: https://vmauth.storage1.example.net/vls type: victoriametrics-logs-datasource auth: credentials_secret_name: grafana-admin-credentials @@ -99,13 +99,13 @@ promxy: config: remoteWriteUrl: http://vminsert-cluster:8480/insert/0/prometheus/api/v1/write serverGroups: - - clusterName: hmc0 + - clusterName: storage0 targets: - - vmauth.hmc0.example.net:443 + - vmauth.storage0.example.net:443 auth: credentials_secret_name: grafana-admin-credentials - - clusterName: hmc1 + - clusterName: storage1 targets: - - vmauth.hmc1.example.net:443 + - vmauth.storage1.example.net:443 auth: credentials_secret_name: grafana-admin-credentials diff --git a/charts/motel-operators/Chart.lock b/charts/kof-operators/Chart.lock similarity index 100% rename from charts/motel-operators/Chart.lock rename to charts/kof-operators/Chart.lock diff --git a/charts/motel-operators/Chart.yaml b/charts/kof-operators/Chart.yaml similarity index 95% rename from charts/motel-operators/Chart.yaml rename to charts/kof-operators/Chart.yaml index cac0f6d..4456dd8 100644 --- a/charts/motel-operators/Chart.yaml +++ b/charts/kof-operators/Chart.yaml @@ -1,5 +1,5 @@ apiVersion: v2 -name: motel-operators +name: kof-operators description: A Helm chart that deploys opentelemetry-operator and prometheus CRDs version: 0.0.1 appVersion: "1.0" diff --git a/charts/motel-operators/templates/opentelemetry/clusterrolebindings/opentelemetry-operator-manager.yaml b/charts/kof-operators/templates/opentelemetry/clusterrolebindings/opentelemetry-operator-manager.yaml similarity index 100% rename from charts/motel-operators/templates/opentelemetry/clusterrolebindings/opentelemetry-operator-manager.yaml rename to charts/kof-operators/templates/opentelemetry/clusterrolebindings/opentelemetry-operator-manager.yaml diff --git a/charts/motel-operators/templates/opentelemetry/clusterroles/opentelemetry-operator-manager.yaml b/charts/kof-operators/templates/opentelemetry/clusterroles/opentelemetry-operator-manager.yaml similarity index 100% rename from charts/motel-operators/templates/opentelemetry/clusterroles/opentelemetry-operator-manager.yaml rename to charts/kof-operators/templates/opentelemetry/clusterroles/opentelemetry-operator-manager.yaml diff --git a/charts/motel-operators/values.yaml b/charts/kof-operators/values.yaml similarity index 100% rename from charts/motel-operators/values.yaml rename to charts/kof-operators/values.yaml diff --git a/charts/motel-storage/Chart.lock b/charts/kof-storage/Chart.lock similarity index 70% rename from charts/motel-storage/Chart.lock rename to charts/kof-storage/Chart.lock index 81596e0..b920889 100644 --- a/charts/motel-storage/Chart.lock +++ b/charts/kof-storage/Chart.lock @@ -4,12 +4,12 @@ dependencies: version: v5.15.1 - name: victoria-metrics-operator repository: https://victoriametrics.github.io/helm-charts/ - version: 0.40.2 + version: 0.40.3 - name: victoria-logs-single repository: https://victoriametrics.github.io/helm-charts/ - version: 0.8.11 + version: 0.8.12 - name: external-dns repository: https://kubernetes-sigs.github.io/external-dns/ version: 1.15.0 -digest: sha256:244f062828bbc1d6c954b2c54955b6f974a5926dc3f4335fa8ba7a78a8516286 -generated: "2024-12-25T14:23:37.379566969+02:00" +digest: sha256:765fa797ecae93345bb5eff857a8ab89803f9cfb0048e560625820a1d4567df0 +generated: "2025-01-06T15:31:00.919698+02:00" diff --git a/charts/motel-storage/Chart.yaml b/charts/kof-storage/Chart.yaml similarity index 97% rename from charts/motel-storage/Chart.yaml rename to charts/kof-storage/Chart.yaml index 65bd8a4..21298d8 100644 --- a/charts/motel-storage/Chart.yaml +++ b/charts/kof-storage/Chart.yaml @@ -1,5 +1,5 @@ apiVersion: v2 -name: motel-storage +name: kof-storage description: A Helm chart that deploys Grafana, and VictoriaMetrics. version: 0.1.2 appVersion: "1.0" diff --git a/charts/motel-storage/files/dashboards/kubernetes-views-global.yaml b/charts/kof-storage/files/dashboards/kubernetes-views-global.yaml similarity index 100% rename from charts/motel-storage/files/dashboards/kubernetes-views-global.yaml rename to charts/kof-storage/files/dashboards/kubernetes-views-global.yaml diff --git a/charts/motel-storage/files/dashboards/kubernetes-views-namespaces.yaml b/charts/kof-storage/files/dashboards/kubernetes-views-namespaces.yaml similarity index 100% rename from charts/motel-storage/files/dashboards/kubernetes-views-namespaces.yaml rename to charts/kof-storage/files/dashboards/kubernetes-views-namespaces.yaml diff --git a/charts/motel-storage/files/dashboards/kubernetes-views-nodes.yaml b/charts/kof-storage/files/dashboards/kubernetes-views-nodes.yaml similarity index 100% rename from charts/motel-storage/files/dashboards/kubernetes-views-nodes.yaml rename to charts/kof-storage/files/dashboards/kubernetes-views-nodes.yaml diff --git a/charts/motel-storage/files/dashboards/kubernetes-views-pods.yaml b/charts/kof-storage/files/dashboards/kubernetes-views-pods.yaml similarity index 100% rename from charts/motel-storage/files/dashboards/kubernetes-views-pods.yaml rename to charts/kof-storage/files/dashboards/kubernetes-views-pods.yaml diff --git a/charts/motel-storage/files/dashboards/node-exporter-full.yaml b/charts/kof-storage/files/dashboards/node-exporter-full.yaml similarity index 100% rename from charts/motel-storage/files/dashboards/node-exporter-full.yaml rename to charts/kof-storage/files/dashboards/node-exporter-full.yaml diff --git a/charts/motel-storage/files/dashboards/opencost-cost-reporter-basic-overview.yaml b/charts/kof-storage/files/dashboards/opencost-cost-reporter-basic-overview.yaml similarity index 100% rename from charts/motel-storage/files/dashboards/opencost-cost-reporter-basic-overview.yaml rename to charts/kof-storage/files/dashboards/opencost-cost-reporter-basic-overview.yaml diff --git a/charts/motel-storage/files/dashboards/opencost-cost-reporter-detailed-overview.yaml b/charts/kof-storage/files/dashboards/opencost-cost-reporter-detailed-overview.yaml similarity index 100% rename from charts/motel-storage/files/dashboards/opencost-cost-reporter-detailed-overview.yaml rename to charts/kof-storage/files/dashboards/opencost-cost-reporter-detailed-overview.yaml diff --git a/charts/motel-storage/files/rules/etcd.yaml b/charts/kof-storage/files/rules/etcd.yaml similarity index 100% rename from charts/motel-storage/files/rules/etcd.yaml rename to charts/kof-storage/files/rules/etcd.yaml diff --git a/charts/motel-storage/files/rules/general.rules.yaml b/charts/kof-storage/files/rules/general.rules.yaml similarity index 100% rename from charts/motel-storage/files/rules/general.rules.yaml rename to charts/kof-storage/files/rules/general.rules.yaml diff --git a/charts/motel-storage/files/rules/k8s.rules.container_cpu_limits.yaml b/charts/kof-storage/files/rules/k8s.rules.container_cpu_limits.yaml similarity index 100% rename from charts/motel-storage/files/rules/k8s.rules.container_cpu_limits.yaml rename to charts/kof-storage/files/rules/k8s.rules.container_cpu_limits.yaml diff --git a/charts/motel-storage/files/rules/k8s.rules.container_cpu_requests.yaml b/charts/kof-storage/files/rules/k8s.rules.container_cpu_requests.yaml similarity index 100% rename from charts/motel-storage/files/rules/k8s.rules.container_cpu_requests.yaml rename to charts/kof-storage/files/rules/k8s.rules.container_cpu_requests.yaml diff --git a/charts/motel-storage/files/rules/k8s.rules.container_cpu_usage_seconds_total.yaml b/charts/kof-storage/files/rules/k8s.rules.container_cpu_usage_seconds_total.yaml similarity index 100% rename from charts/motel-storage/files/rules/k8s.rules.container_cpu_usage_seconds_total.yaml rename to charts/kof-storage/files/rules/k8s.rules.container_cpu_usage_seconds_total.yaml diff --git a/charts/motel-storage/files/rules/k8s.rules.container_memory_cache.yaml b/charts/kof-storage/files/rules/k8s.rules.container_memory_cache.yaml similarity index 100% rename from charts/motel-storage/files/rules/k8s.rules.container_memory_cache.yaml rename to charts/kof-storage/files/rules/k8s.rules.container_memory_cache.yaml diff --git a/charts/motel-storage/files/rules/k8s.rules.container_memory_limits.yaml b/charts/kof-storage/files/rules/k8s.rules.container_memory_limits.yaml similarity index 100% rename from charts/motel-storage/files/rules/k8s.rules.container_memory_limits.yaml rename to charts/kof-storage/files/rules/k8s.rules.container_memory_limits.yaml diff --git a/charts/motel-storage/files/rules/k8s.rules.container_memory_requests.yaml b/charts/kof-storage/files/rules/k8s.rules.container_memory_requests.yaml similarity index 100% rename from charts/motel-storage/files/rules/k8s.rules.container_memory_requests.yaml rename to charts/kof-storage/files/rules/k8s.rules.container_memory_requests.yaml diff --git a/charts/motel-storage/files/rules/k8s.rules.container_memory_rss.yaml b/charts/kof-storage/files/rules/k8s.rules.container_memory_rss.yaml similarity index 100% rename from charts/motel-storage/files/rules/k8s.rules.container_memory_rss.yaml rename to charts/kof-storage/files/rules/k8s.rules.container_memory_rss.yaml diff --git a/charts/motel-storage/files/rules/k8s.rules.container_memory_swap.yaml b/charts/kof-storage/files/rules/k8s.rules.container_memory_swap.yaml similarity index 100% rename from charts/motel-storage/files/rules/k8s.rules.container_memory_swap.yaml rename to charts/kof-storage/files/rules/k8s.rules.container_memory_swap.yaml diff --git a/charts/motel-storage/files/rules/k8s.rules.container_memory_working_set_bytes.yaml b/charts/kof-storage/files/rules/k8s.rules.container_memory_working_set_bytes.yaml similarity index 100% rename from charts/motel-storage/files/rules/k8s.rules.container_memory_working_set_bytes.yaml rename to charts/kof-storage/files/rules/k8s.rules.container_memory_working_set_bytes.yaml diff --git a/charts/motel-storage/files/rules/k8s.rules.pod_owner.yaml b/charts/kof-storage/files/rules/k8s.rules.pod_owner.yaml similarity index 100% rename from charts/motel-storage/files/rules/k8s.rules.pod_owner.yaml rename to charts/kof-storage/files/rules/k8s.rules.pod_owner.yaml diff --git a/charts/motel-storage/files/rules/kube-prometheus-general.rules.yaml b/charts/kof-storage/files/rules/kube-prometheus-general.rules.yaml similarity index 100% rename from charts/motel-storage/files/rules/kube-prometheus-general.rules.yaml rename to charts/kof-storage/files/rules/kube-prometheus-general.rules.yaml diff --git a/charts/motel-storage/files/rules/kube-prometheus-node-recording.rules.yaml b/charts/kof-storage/files/rules/kube-prometheus-node-recording.rules.yaml similarity index 100% rename from charts/motel-storage/files/rules/kube-prometheus-node-recording.rules.yaml rename to charts/kof-storage/files/rules/kube-prometheus-node-recording.rules.yaml diff --git a/charts/motel-storage/files/rules/kube-state-metrics.yaml b/charts/kof-storage/files/rules/kube-state-metrics.yaml similarity index 100% rename from charts/motel-storage/files/rules/kube-state-metrics.yaml rename to charts/kof-storage/files/rules/kube-state-metrics.yaml diff --git a/charts/motel-storage/files/rules/kubelet.rules.yaml b/charts/kof-storage/files/rules/kubelet.rules.yaml similarity index 100% rename from charts/motel-storage/files/rules/kubelet.rules.yaml rename to charts/kof-storage/files/rules/kubelet.rules.yaml diff --git a/charts/motel-storage/files/rules/kubernetes-apps.yaml b/charts/kof-storage/files/rules/kubernetes-apps.yaml similarity index 100% rename from charts/motel-storage/files/rules/kubernetes-apps.yaml rename to charts/kof-storage/files/rules/kubernetes-apps.yaml diff --git a/charts/motel-storage/files/rules/kubernetes-resources.yaml b/charts/kof-storage/files/rules/kubernetes-resources.yaml similarity index 100% rename from charts/motel-storage/files/rules/kubernetes-resources.yaml rename to charts/kof-storage/files/rules/kubernetes-resources.yaml diff --git a/charts/motel-storage/files/rules/kubernetes-storage.yaml b/charts/kof-storage/files/rules/kubernetes-storage.yaml similarity index 100% rename from charts/motel-storage/files/rules/kubernetes-storage.yaml rename to charts/kof-storage/files/rules/kubernetes-storage.yaml diff --git a/charts/motel-storage/files/rules/kubernetes-system-apiserver.yaml b/charts/kof-storage/files/rules/kubernetes-system-apiserver.yaml similarity index 100% rename from charts/motel-storage/files/rules/kubernetes-system-apiserver.yaml rename to charts/kof-storage/files/rules/kubernetes-system-apiserver.yaml diff --git a/charts/motel-storage/files/rules/kubernetes-system-kubelet.yaml b/charts/kof-storage/files/rules/kubernetes-system-kubelet.yaml similarity index 100% rename from charts/motel-storage/files/rules/kubernetes-system-kubelet.yaml rename to charts/kof-storage/files/rules/kubernetes-system-kubelet.yaml diff --git a/charts/motel-storage/files/rules/kubernetes-system.yaml b/charts/kof-storage/files/rules/kubernetes-system.yaml similarity index 100% rename from charts/motel-storage/files/rules/kubernetes-system.yaml rename to charts/kof-storage/files/rules/kubernetes-system.yaml diff --git a/charts/motel-storage/files/rules/node-exporter.rules.yaml b/charts/kof-storage/files/rules/node-exporter.rules.yaml similarity index 100% rename from charts/motel-storage/files/rules/node-exporter.rules.yaml rename to charts/kof-storage/files/rules/node-exporter.rules.yaml diff --git a/charts/motel-storage/files/rules/node-exporter.yaml b/charts/kof-storage/files/rules/node-exporter.yaml similarity index 100% rename from charts/motel-storage/files/rules/node-exporter.yaml rename to charts/kof-storage/files/rules/node-exporter.yaml diff --git a/charts/motel-storage/files/rules/node-network.yaml b/charts/kof-storage/files/rules/node-network.yaml similarity index 100% rename from charts/motel-storage/files/rules/node-network.yaml rename to charts/kof-storage/files/rules/node-network.yaml diff --git a/charts/motel-storage/files/rules/node.rules.yaml b/charts/kof-storage/files/rules/node.rules.yaml similarity index 100% rename from charts/motel-storage/files/rules/node.rules.yaml rename to charts/kof-storage/files/rules/node.rules.yaml diff --git a/charts/motel-storage/templates/_helpers.tpl b/charts/kof-storage/templates/_helpers.tpl similarity index 100% rename from charts/motel-storage/templates/_helpers.tpl rename to charts/kof-storage/templates/_helpers.tpl diff --git a/charts/motel-storage/templates/cert-manager/clusterissuer.yaml b/charts/kof-storage/templates/cert-manager/clusterissuer.yaml similarity index 100% rename from charts/motel-storage/templates/cert-manager/clusterissuer.yaml rename to charts/kof-storage/templates/cert-manager/clusterissuer.yaml diff --git a/charts/motel-storage/templates/grafana/dashboards/dashboard.yaml b/charts/kof-storage/templates/grafana/dashboards/dashboard.yaml similarity index 100% rename from charts/motel-storage/templates/grafana/dashboards/dashboard.yaml rename to charts/kof-storage/templates/grafana/dashboards/dashboard.yaml diff --git a/charts/motel-storage/templates/grafana/datasources.yaml b/charts/kof-storage/templates/grafana/datasources.yaml similarity index 100% rename from charts/motel-storage/templates/grafana/datasources.yaml rename to charts/kof-storage/templates/grafana/datasources.yaml diff --git a/charts/motel-storage/templates/grafana/grafana.yaml b/charts/kof-storage/templates/grafana/grafana.yaml similarity index 100% rename from charts/motel-storage/templates/grafana/grafana.yaml rename to charts/kof-storage/templates/grafana/grafana.yaml diff --git a/charts/motel-storage/templates/grafana/rules/rules.yaml b/charts/kof-storage/templates/grafana/rules/rules.yaml similarity index 100% rename from charts/motel-storage/templates/grafana/rules/rules.yaml rename to charts/kof-storage/templates/grafana/rules/rules.yaml diff --git a/charts/motel-storage/templates/victoria/vmalert.yaml b/charts/kof-storage/templates/victoria/vmalert.yaml similarity index 100% rename from charts/motel-storage/templates/victoria/vmalert.yaml rename to charts/kof-storage/templates/victoria/vmalert.yaml diff --git a/charts/motel-storage/templates/victoria/vmauth.yaml b/charts/kof-storage/templates/victoria/vmauth.yaml similarity index 100% rename from charts/motel-storage/templates/victoria/vmauth.yaml rename to charts/kof-storage/templates/victoria/vmauth.yaml diff --git a/charts/motel-storage/templates/victoria/vmcluster.yaml b/charts/kof-storage/templates/victoria/vmcluster.yaml similarity index 100% rename from charts/motel-storage/templates/victoria/vmcluster.yaml rename to charts/kof-storage/templates/victoria/vmcluster.yaml diff --git a/charts/motel-storage/templates/victoria/vmuser.yaml b/charts/kof-storage/templates/victoria/vmuser.yaml similarity index 97% rename from charts/motel-storage/templates/victoria/vmuser.yaml rename to charts/kof-storage/templates/victoria/vmuser.yaml index 66d7bd5..f23fb0d 100644 --- a/charts/motel-storage/templates/victoria/vmuser.yaml +++ b/charts/kof-storage/templates/victoria/vmuser.yaml @@ -22,7 +22,7 @@ spec: - /vm/insert/.* static: url: http://vminsert-cluster.{{ .Release.Namespace }}.svc:8480 - username: {{ .Values.victoriametrics.vmauth.credentials.username | default "motel" }} + username: {{ .Values.victoriametrics.vmauth.credentials.username | default "kof" }} passwordRef: key: {{ .Values.victoriametrics.vmauth.credentials.password_key | default "password" }} name: {{ .Values.victoriametrics.vmauth.credentials.password_secret_name }} diff --git a/charts/motel-storage/values.yaml b/charts/kof-storage/values.yaml similarity index 94% rename from charts/motel-storage/values.yaml rename to charts/kof-storage/values.yaml index 103456f..ebbeac2 100644 --- a/charts/motel-storage/values.yaml +++ b/charts/kof-storage/values.yaml @@ -27,7 +27,7 @@ victoriametrics: credentials: password_secret_name: grafana-admin-credentials password_key: "GF_SECURITY_ADMIN_PASSWORD" - username: motel + username: kof ingress: host: vmauth.hmc0.example.net vmcluster: @@ -43,7 +43,7 @@ grafana: url: http://vmselect-cluster:8481/select/0/prometheus type: prometheus - name: logs - url: http://motel-storage-victoria-logs-single-server:9428 + url: http://kof-storage-victoria-logs-single-server:9428 type: victoriametrics-logs-datasource alerts: enabled: true diff --git a/charts/motel-mothership/templates/hmc/motel-repo.yaml b/charts/motel-mothership/templates/hmc/motel-repo.yaml deleted file mode 100644 index 1c9efd4..0000000 --- a/charts/motel-mothership/templates/hmc/motel-repo.yaml +++ /dev/null @@ -1,14 +0,0 @@ -{{- if .Values.hmc.installTemplates }} ---- -apiVersion: source.toolkit.fluxcd.io/v1 -kind: HelmRepository -metadata: - name: {{ .Values.hmc.motel.repo.name }} - namespace: hmc-system - labels: - hmc.mirantis.com/managed: "true" -spec: - url: {{ .Values.hmc.motel.repo.url }} - insecure: {{ .Values.hmc.motel.repo.insecure }} - type: {{ .Values.hmc.motel.repo.type }} -{{- end }} diff --git a/demo/cluster/aws-managed.yaml b/demo/cluster/aws-managed.yaml index b36aa38..a849e52 100644 --- a/demo/cluster/aws-managed.yaml +++ b/demo/cluster/aws-managed.yaml @@ -4,7 +4,7 @@ metadata: name: aws-managed0 namespace: hmc-system labels: - motel: "collector" + kof: "collector" spec: credential: aws-cluster-identity-cred config: @@ -24,16 +24,16 @@ spec: services: - template: cert-manager name: cert-manager - namespace: motel + namespace: kof values: | crds: enabled: true - - template: motel-operators - name: motel-operators - namespace: motel - - template: motel-collectors - name: motel-collectors - namespace: motel + - template: kof-operators + name: kof-operators + namespace: kof + - template: kof-collectors + name: kof-collectors + namespace: kof values: | global: clusterName: aws-managed0 @@ -48,7 +48,7 @@ spec: url: "https://vmauth.storage0.example.net/vm/select/0/prometheus" exporter: defaultClusterId: "aws-managed0" - motel: + kof: logs: credentials_secret_name: grafana-admin-credentials username_key: GF_SECURITY_ADMIN_USER diff --git a/demo/cluster/aws-storage.yaml b/demo/cluster/aws-storage.yaml index 0c97719..8de74e3 100644 --- a/demo/cluster/aws-storage.yaml +++ b/demo/cluster/aws-storage.yaml @@ -4,7 +4,7 @@ metadata: name: aws-storage0 namespace: hmc-system labels: - motel: "storage" + kof: "storage" spec: credential: aws-cluster-identity-cred config: @@ -31,9 +31,9 @@ spec: values: | crds: enabled: true - - name: motel-storage - namespace: motel - template: motel-storage + - name: kof-storage + namespace: kof + template: kof-storage values: | victoriametrics: vmauth: diff --git a/docs/DEV.md b/docs/DEV.md index dded79b..9576623 100644 --- a/docs/DEV.md +++ b/docs/DEV.md @@ -2,10 +2,10 @@ ## Prerequisites -* Make sure that you have a [HMC](https://github.com/Mirantis/hmc/blob/main/docs/dev.md) installed. +* Make sure that you have a [K0rdent](https://github.com/K0rdent/kcm/blob/main/docs/dev.md) installed. It's your "mothership" cluster. -* DNS to test motel with managed clusters installations +* DNS to test kof with managed clusters installations Install cli tools @@ -13,7 +13,7 @@ Install cli tools make cli-install ``` -## Local deployment (without HMC) +## Local deployment (without K0rdent) Install into local clusters these helm charts using Makefile @@ -26,10 +26,10 @@ make dev-collectors-deploy When everything up and running you can connect to grafana using port-forwarding ```bash -kubectl --namespace motel port-forward svc/grafana-vm-service 3000:3000 +kubectl --namespace kof port-forward svc/grafana-vm-service 3000:3000 ``` -## Managed clusters deployment with HMC in AWS +## Managed clusters deployment with K0rdent in AWS Install helm charts into a local registry @@ -40,7 +40,7 @@ make helm-push Define your DNS zone (automatically managed by external-dns) ```bash -MOTEL_DNS="dev.example.net" +KOF_DNS="dev.example.net" ``` Install "mothership" helm chart into your "mothership" cluster @@ -65,5 +65,5 @@ make dev-managed-deploy-aws When everything up and running you can connect to grafana using port-forwarding from your "mothership" cluster ```bash -kubectl --namespace motel port-forward svc/grafana-vm-service 3000:3000 +kubectl --namespace kof port-forward svc/grafana-vm-service 3000:3000 ```