mirror of
https://github.com/helmfile/helmfile.git
synced 2026-10-21 11:33:39 +02:00
Fix chartify regression of missing chart dependencies (#1869)
* Fix chartify regression of missing chart dependencies Fixes https://github.com/roboll/helmfile/issues/1867 * Add integration test cases for issues #1857 and #1867
This commit is contained in:
@@ -0,0 +1,22 @@
|
||||
repositories:
|
||||
- name: prometheus-community
|
||||
url: https://prometheus-community.github.io/helm-charts
|
||||
|
||||
releases:
|
||||
- name: prometheus-operator-k8s-test
|
||||
chart: prometheus-community/kube-prometheus-stack
|
||||
namespace: monitoring
|
||||
forceNamespace: monitoring
|
||||
version: 15.4.6
|
||||
labels:
|
||||
component: test-upg
|
||||
values:
|
||||
- nameOverride: k8s
|
||||
fullnameOverride: prometheus-k8s
|
||||
global:
|
||||
imagePullSecrets:
|
||||
- name: regsecret
|
||||
alertmanager:
|
||||
enabled: false
|
||||
grafana:
|
||||
enabled: {{ .Values.grafanaEnabled }}
|
||||
@@ -0,0 +1,18 @@
|
||||
repositories:
|
||||
- name: bitnami
|
||||
url: https://charts.bitnami.com/bitnami
|
||||
|
||||
releases:
|
||||
- name: elasticsearch
|
||||
chart: bitnami/elasticsearch
|
||||
version: 15.2.2
|
||||
jsonPatches:
|
||||
- target:
|
||||
version: v1
|
||||
kind: StatefulSet
|
||||
name: elasticsearch-master
|
||||
patch:
|
||||
- op: add
|
||||
path: /spec/template/spec/containers/0/volumeMounts/0/subPathExpr
|
||||
value: elasticsearch/$(MY_POD_NAME)
|
||||
|
||||
@@ -150,6 +150,21 @@ info "Ensuring \"helmfile template\" output does contain only YAML docs"
|
||||
|
||||
test_pass "happypath"
|
||||
|
||||
test_start "regression tests"
|
||||
|
||||
if [[ helm_major_version -eq 3 ]]; then
|
||||
info "https://github.com/roboll/helmfile/issues/1857"
|
||||
(${helmfile} -f ${dir}/issue.1857.yaml --state-values-set grafanaEnabled=true template | grep grafana 1>/dev/null) || fail "\"helmfile template\" shouldn't include grafana"
|
||||
! (${helmfile} -f ${dir}/issue.1857.yaml --state-values-set grafanaEnabled=false template | grep grafana) || fail "\"helmfile template\" shouldn't include grafana"
|
||||
|
||||
info "https://github.com/roboll/helmfile/issues/1867"
|
||||
(${helmfile} -f ${dir}/issue.1867.yaml template 1>/dev/null) || fail "\"helmfile template\" shouldn't fail"
|
||||
else
|
||||
info "There are no regression tests for helm 2 because all the target charts have dropped helm 2 support."
|
||||
fi
|
||||
|
||||
test_pass "regression tests"
|
||||
|
||||
if [[ helm_major_version -eq 3 ]]; then
|
||||
export VAULT_ADDR=http://127.0.0.1:8200
|
||||
export VAULT_TOKEN=toor
|
||||
|
||||
Reference in New Issue
Block a user