Merge "Prometheus: Add feature-gate support in deployment scripts"
This commit is contained in:
commit
a78ee39dcb
@ -1,26 +1,8 @@
|
|||||||
conf:
|
conf:
|
||||||
prometheus:
|
prometheus:
|
||||||
rules:
|
rules:
|
||||||
logging:
|
elasticsearch:
|
||||||
groups:
|
groups:
|
||||||
- name: fluentd.rules
|
|
||||||
rules:
|
|
||||||
- alert: prom_exporter_fluentd_unavailable
|
|
||||||
expr: absent(fluentd_up)
|
|
||||||
for: 10m
|
|
||||||
labels:
|
|
||||||
severity: warning
|
|
||||||
annotations:
|
|
||||||
description: Fluentd exporter is not collecting metrics or is not available for past 10 minutes
|
|
||||||
title: Fluentd exporter is not collecting metrics or is not available
|
|
||||||
- alert: fluentd_not_running
|
|
||||||
expr: fluentd_up == 0
|
|
||||||
for: 5m
|
|
||||||
labels:
|
|
||||||
severity: page
|
|
||||||
annotations:
|
|
||||||
description: 'fluentd is down on {{$labels.instance}} for more than 5 minutes'
|
|
||||||
summary: 'Fluentd is down'
|
|
||||||
- name: elasticsearch.rules
|
- name: elasticsearch.rules
|
||||||
rules:
|
rules:
|
||||||
- alert: prom_exporter_elasticsearch_unavailable
|
- alert: prom_exporter_elasticsearch_unavailable
|
@ -19,10 +19,15 @@ set -xe
|
|||||||
#NOTE: Lint and package chart
|
#NOTE: Lint and package chart
|
||||||
make prometheus
|
make prometheus
|
||||||
|
|
||||||
|
FEATURE_GATES="alertmanager,ceph,elasticsearch,kubernetes,nodes,openstack,postgresql"
|
||||||
|
: ${OSH_INFRA_EXTRA_HELM_ARGS_PROMETHEUS:="$({ ./tools/deployment/common/get-values-overrides.sh prometheus;} 2> /dev/null)"}
|
||||||
|
|
||||||
#NOTE: Deploy command
|
#NOTE: Deploy command
|
||||||
helm upgrade --install prometheus ./prometheus \
|
helm upgrade --install prometheus ./prometheus \
|
||||||
--namespace=osh-infra \
|
--namespace=osh-infra \
|
||||||
--set pod.replicas.prometheus=2
|
--set pod.replicas.prometheus=2 \
|
||||||
|
${OSH_INFRA_EXTRA_HELM_ARGS} \
|
||||||
|
${OSH_INFRA_EXTRA_HELM_ARGS_PROMETHEUS}
|
||||||
|
|
||||||
#NOTE: Wait for deploy
|
#NOTE: Wait for deploy
|
||||||
./tools/deployment/common/wait-for-pods.sh osh-infra
|
./tools/deployment/common/wait-for-pods.sh osh-infra
|
||||||
|
@ -19,15 +19,14 @@ set -xe
|
|||||||
#NOTE: Lint and package chart
|
#NOTE: Lint and package chart
|
||||||
make prometheus
|
make prometheus
|
||||||
|
|
||||||
rules_overrides=""
|
FEATURE_GATES="alertmanager,ceph,elasticsearch,kubernetes,nodes,openstack,postgresql"
|
||||||
for rules_file in $(ls ./prometheus/values_overrides); do
|
: ${OSH_INFRA_EXTRA_HELM_ARGS_PROMETHEUS:="$({ ./tools/deployment/common/get-values-overrides.sh prometheus;} 2> /dev/null)"}
|
||||||
rules_overrides="$rules_overrides --values=./prometheus/values_overrides/$rules_file"
|
|
||||||
done
|
|
||||||
|
|
||||||
#NOTE: Deploy command
|
#NOTE: Deploy command
|
||||||
helm upgrade --install prometheus ./prometheus \
|
helm upgrade --install prometheus ./prometheus \
|
||||||
--namespace=osh-infra \
|
--namespace=osh-infra \
|
||||||
$rules_overrides
|
${OSH_INFRA_EXTRA_HELM_ARGS} \
|
||||||
|
${OSH_INFRA_EXTRA_HELM_ARGS_PROMETHEUS}
|
||||||
|
|
||||||
#NOTE: Wait for deploy
|
#NOTE: Wait for deploy
|
||||||
./tools/deployment/common/wait-for-pods.sh osh-infra
|
./tools/deployment/common/wait-for-pods.sh osh-infra
|
||||||
|
Loading…
Reference in New Issue
Block a user