Skip to content

Commit

Permalink
k8s: Remove Argo managed services from helmfile (#1840)
Browse files Browse the repository at this point in the history
* k8s: Remove Argo managed services from helmfile

This commit seeks to remove services that are now fully migrated
to argo from the main helmfile.yaml.

This should prevent running `make apply` from showing phantom
diffs where argo has already enacted the change but helm hasn't
yet recorded that change in its secrets.
  • Loading branch information
tarrow authored Nov 21, 2024
1 parent 4854abc commit 88c3d4f
Show file tree
Hide file tree
Showing 3 changed files with 68 additions and 20 deletions.
2 changes: 1 addition & 1 deletion bin/generate-values
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ RELEASE="$2"
# absolute path of the wbaas-deploy repository
ROOT=$(realpath $(dirname $(realpath $BASH_SOURCE))/..)
OUTPUT_TEMPLATE="${ROOT}/k8s/argocd/${ENVIRONMENT}/${RELEASE}.values.yaml"
HELMFILE="k8s/helmfile/helmfile.yaml"
HELMFILE="k8s/helmfile/only-for-argo-value-generation.yaml"
TMP_HELMFILE="$(dirname ${HELMFILE})/.tmp_helmfile.$(mktemp -u XXXXXX).yaml"

if [[ -n "$3" ]]; then
Expand Down
19 changes: 0 additions & 19 deletions k8s/helmfile/helmfile.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -139,13 +139,6 @@ releases:
version: 19.10.2
<<: *default_release

- name: redis
# This is in the default namespace, as the default ns implies staging?
namespace: default
chart: bitnami/redis
version: 17.3.8
<<: *default_release

- name: platform-nginx
namespace: default
chart: bitnami-legacy/nginx
Expand All @@ -161,18 +154,6 @@ releases:
- forceSSL: {{ .Values.forceSSL | toYaml }}
- tls: {{ .Values.tls | toYaml }}

- name: api
chart: wbstack/api
version: "0.32.0"
namespace: default
<<: *default_release

- name: ui
namespace: default
chart: wbstack/ui
version: 0.3.1
<<: *default_release

- name: mediawiki-139
namespace: default
chart: wbstack/mediawiki
Expand Down
67 changes: 67 additions & 0 deletions k8s/helmfile/only-for-argo-value-generation.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,67 @@
repositories:
- name: wbstack
url: https://wbstack.github.io/charts
- name: bitnami
url: https://charts.bitnami.com/bitnami
- name: bitnami-legacy
# yamllint disable-line rule:line-length
url: https://raw.githubusercontent.com/bitnami/charts/eb5f9a9513d987b519f0ecd732e7031241c50328/bitnami
- name: cetic
url: https://cetic.github.io/helm-charts
- name: codecentric
url: https://codecentric.github.io/helm-charts
- name: ingress-nginx
url: https://kubernetes.github.io/ingress-nginx
- name: prometheus-community
url: https://prometheus-community.github.io/helm-charts
- name: istio
url: https://istio-release.storage.googleapis.com/charts
- name: minio
url: https://charts.min.io

environments:
default:
kubeContext: INVALID-ENVIRONMENT
production:
kubeContext: gke_wikibase-cloud_europe-west3-a_wbaas-3
values:
- ./env/production/base.yaml
- ./env/production/private.yaml
staging:
kubeContext: gke_wikibase-cloud_europe-west3-a_wbaas-2
values:
- ./env/staging/base.yaml
- ./env/staging/private.yaml
local:
kubeContext: minikube-wbaas
values:
- ./env/local/base.yaml
- ./env/local/private.yaml

---

templates:
default: &default_release
missingFileHandler: Error
values:
- env/production/{{`{{ .Release.Name }}`}}.values.yaml.gotmpl
- env/{{`{{ .Environment.Name }}`}}/{{`{{ .Release.Name }}`}}.values.yaml.gotmpl

releases:
- name: api
chart: wbstack/api
version: "0.32.0"
namespace: default
<<: *default_release

- name: ui
namespace: default
chart: wbstack/ui
version: 0.3.1
<<: *default_release

- name: redis
namespace: default
chart: bitnami/redis
version: 17.3.8
<<: *default_release

0 comments on commit 88c3d4f

Please sign in to comment.