From e87e3b0724935281d315bb613db4f769a1faa8ba Mon Sep 17 00:00:00 2001 From: Simon Larsen Date: Fri, 15 Mar 2024 12:25:57 +0000 Subject: [PATCH] Remove unused helm commands and files --- Devops/docs/helm-ops.md | 117 ------------------ HelmChart/Docs/{HelmOneUptime.md => Helm.md} | 0 .../Public/oneuptime/templates/cert-pvc.yaml | 5 - .../Public/oneuptime/templates/identity.yaml | 16 --- HelmChart/Public/oneuptime/values.yaml | 4 - 5 files changed, 142 deletions(-) delete mode 100644 Devops/docs/helm-ops.md rename HelmChart/Docs/{HelmOneUptime.md => Helm.md} (100%) delete mode 100644 HelmChart/Public/oneuptime/templates/cert-pvc.yaml delete mode 100644 HelmChart/Public/oneuptime/templates/identity.yaml diff --git a/Devops/docs/helm-ops.md b/Devops/docs/helm-ops.md deleted file mode 100644 index 0be7d522b5..0000000000 --- a/Devops/docs/helm-ops.md +++ /dev/null @@ -1,117 +0,0 @@ -# Important helm commands. - -Please run these commands from `root` - -Make sure to use the right kubernetes context before making any changes - -``` -kubectl config get-contexts - -# replace NAME with the context name -kubectl config use-context NAME -``` - -### Lint chart - -``` -helm lint ./HelmChart/Public/oneuptime -``` - -### Install as an Enterprise Cluster with default values - -``` -helm install oneuptime-release./HelmChart/Public/oneuptime --namespace default -``` - -### Install on staging - -``` -helm install -f ./HelmChart/Public/oneuptime/values.yaml -f ./kubernetes/values-saas-staging.yaml oneuptime-release./HelmChart/Public/oneuptime --namespace default -``` - -### Install on production - -``` -helm install -f ./HelmChart/Public/oneuptime/values.yaml -f ./Kubernetes/values-saas-production.yaml oneuptime-release./HelmChart/Public/oneuptime --namespace default -``` - -### Update Cluster - -Staging: - -``` -kubectl config use-context arn:aws:eks:us-east-2:972164494713:cluster/oneuptime-staging -helm upgrade -f ./HelmChart/Public/oneuptime/values.yaml -f ./kubernetes/values-saas-staging.yaml oneuptime-release./HelmChart/Public/oneuptime -``` - -Use default values first and then use staging values. - -Production: - -``` -kubectl config use-context arn:aws:eks:us-east-2:972164494713:cluster/oneuptime-production -helm upgrade -f ./HelmChart/Public/oneuptime/values.yaml -f ./Kubernetes/values-saas-production.yaml oneuptime-release./HelmChart/Public/oneuptime -``` - -Use default values first and then use production values. - -If you introduce values, you can set - -``` -helm upgrade --reuse-values --set key=value oneuptime-release./HelmChart/Public/oneuptime -``` - -### Uninstall - -``` -helm uninstall oneuptime-release--namespace=default -``` - -### Docker build and push to docker repo with `:test` tag - -Build and deploy all (with master tag, you can use any other tag): - -``` -chmod +x ./ci/scripts/docker-build-all-and-push.sh -sudo ./ci/scripts/docker-build-all-and-push.sh latest -``` - -Build and deploy one: - -``` -chmod +x ./ci/scripts/docker-build-and-push.sh -sudo ./ci/scripts/docker-build-and-push.sh $repo $tag -``` - -### Package and deploy helm chart - -``` -cd ./HelmChart/Public -helm repo index ./oneuptime -helm package ./oneuptime -helm repo index . -cd .. -cd .. -``` - -### Update a chart dependency - -``` -cd ./HelmChart/Public -#IMPORTANT: change the version of the dependent chart at `/HelmChart/Public/oneuptime/Chart.yaml`. This should be the version field (and NOT appVersion) in Chart.yaml of the dependency. - -# Run this command. -helm dependency update oneuptime - -# Go back to root. -cd .. -cd.. -``` - -### Docker Images - -Docker Images are hosted at: https://hub.docker.com/orgs/oneuptime/repositories and are public. - -### More info - -Read readme at [./Public/oneuptime/Readme.md](./Public/oneuptime/Readme.md) diff --git a/HelmChart/Docs/HelmOneUptime.md b/HelmChart/Docs/Helm.md similarity index 100% rename from HelmChart/Docs/HelmOneUptime.md rename to HelmChart/Docs/Helm.md diff --git a/HelmChart/Public/oneuptime/templates/cert-pvc.yaml b/HelmChart/Public/oneuptime/templates/cert-pvc.yaml deleted file mode 100644 index 76c2296a53..0000000000 --- a/HelmChart/Public/oneuptime/templates/cert-pvc.yaml +++ /dev/null @@ -1,5 +0,0 @@ -# OneUptime Certs PVC - -{{- $certsPvcArgs := dict "Name" "certs" "Release" $.Release "Values" $.Values "Storage" $.Values.volume.certs.storage -}} -{{- include "oneuptime.pvc" $certsPvcArgs }} ---- \ No newline at end of file diff --git a/HelmChart/Public/oneuptime/templates/identity.yaml b/HelmChart/Public/oneuptime/templates/identity.yaml deleted file mode 100644 index a639cecd99..0000000000 --- a/HelmChart/Public/oneuptime/templates/identity.yaml +++ /dev/null @@ -1,16 +0,0 @@ -# OneUptime identity Deployment -{{- $identityEnv := dict "PORT" $.Values.port.identity -}} -{{- $identityDeploymentArgs :=dict "IsServer" true "ServiceName" "identity" "Port" $.Values.port.identity "Release" $.Release "Values" $.Values "Env" $identityEnv -}} -{{- include "oneuptime.deployment" $identityDeploymentArgs }} ---- - -# OneUptime identity Service - -{{- $identityServiceArgs := dict "ServiceName" "identity" "Port" $.Values.port.identity "Release" $.Release "Values" $.Values -}} -{{- include "oneuptime.service" $identityServiceArgs }} ---- - -# OneUptime identity autoscaler -{{- $identityAutoScalerArgs := dict "ServiceName" "identity" "Release" $.Release "Values" $.Values -}} -{{- include "oneuptime.autoscaler" $identityAutoScalerArgs }} ---- \ No newline at end of file diff --git a/HelmChart/Public/oneuptime/values.yaml b/HelmChart/Public/oneuptime/values.yaml index 9866f68caa..1f6bda8659 100644 --- a/HelmChart/Public/oneuptime/values.yaml +++ b/HelmChart/Public/oneuptime/values.yaml @@ -11,10 +11,6 @@ httpProtocol: http openTelemetryCollectorHost: fluentdHost: -volume: - certs: - storage: 1Gi - deployment: replicaCount: 1