KubeZero/charts/kubezero-logging/update.sh

25 lines
1.0 KiB
Bash
Raw Normal View History

#!/bin/bash
2021-12-15 22:19:52 +00:00
set -ex
. ../../scripts/lib-update.sh
2021-12-15 22:19:52 +00:00
ECK_VERSION=$(yq eval '.dependencies[] | select(.name=="eck-operator") | .version' Chart.yaml)
FLUENT_BIT_VERSION=$(yq eval '.dependencies[] | select(.name=="fluent-bit") | .version' Chart.yaml)
FLUENTD_VERSION=$(yq eval '.dependencies[] | select(.name=="fluentd") | .version' Chart.yaml)
patch_chart eck-operator
# fix ECK crds handling to adhere to proper helm v3 support which also fixes ArgoCD applying updates on upgrades
mkdir charts/eck-operator/crds
helm template charts/eck-operator/charts/eck-operator-crds --name-template logging > charts/eck-operator/crds/all-crds.yaml
rm -rf charts/eck-operator/charts
2021-12-15 22:19:52 +00:00
yq eval -Mi 'del(.dependencies)' charts/eck-operator/Chart.yaml
# FluentD
patch_chart fluentd
# Fetch dashboards from Grafana.com and update ZDT CM
../kubezero-metrics/sync_grafana_dashboards.py dashboards.yaml templates/fluent-bit/grafana-dashboards.yaml
../kubezero-metrics/sync_grafana_dashboards.py dashboards-es.yaml templates/eck/grafana-dashboards.yaml