File tree Expand file tree Collapse file tree 8 files changed +7
-38
lines changed
Expand file tree Collapse file tree 8 files changed +7
-38
lines changed Original file line number Diff line number Diff line change 11#! /bin/bash
22set -e
33set -o pipefail
4+
5+ # Copy relevant files to `.frigga/`
46source kubernetes/minikube_rsync.sh
57
68kubectl apply -f kubernetes/debug.yml
@@ -11,8 +13,10 @@ while [[ -z "$(kubectl get pods | grep debug.*Running)" ]]; do
1113done
1214echo " >> [LOG] Debug pod is ready!"
1315POD_DEBUG=$( kubectl get pods | grep debug.* Running | cut -f 1 -d " " )
14- # kubectl exec -it $POD_DEBUG bash "mkdir -p /root/frigga"
16+
17+ # Copy from `.frigga/` to debug pod
1518kubectl cp .frigga/ default/$POD_DEBUG :/root/frigga/
19+
1620kubectl apply \
1721 -f kubernetes/exporters.yml \
1822 -f kubernetes/monitoring.yml
Load Diff This file was deleted.
Load Diff This file was deleted.
Original file line number Diff line number Diff line change 88 MINIKUBE_HOME=/home/runner/work/_temp
99fi
1010
11- AGENT_PID=$( eval ` ssh-agent -s` )
12- echo " >> [LOG] ssh-agent PID = $AGENT_PID "
13-
1411rm -rf .frigga
1512mkdir .frigga
1613echo $PWD
Original file line number Diff line number Diff line change 33set -o pipefail
44kubectl get pods
55POD_PROMETHEUS=$( kubectl get pods --selector=app=prometheus | grep 1/1.* Running | cut -f 1 -d " " 2> /dev/null || true)
6- [[ -z ${POD_PROMETHEUS} ]] && echo " The container ${POD_PROMETHEUS} is not running, execute first docker-compose/deploy_stack.sh"
7-
8- reload_result=$( kubectl logs ${POD_PROMETHEUS} )
9- reload_success=$( echo " ${reload_result} " | tail -n 3 | grep " .*Completed loading of configuration file.*" )
10- if [[ -z ${reload_succes} ]]; then
11- echo " "
12- echo " >> [LOG] Successfully reloaded prometheus.yml"
13- echo " "
14- else
15- echo " >> [ERROR] Failed to reload prometheus.yml"
16- echo " ${reload_result} "
6+ if [[ -z ${POD_PROMETHEUS} ]]; then
7+ echo " The container ${POD_PROMETHEUS} is not running, execute first docker-compose/deploy_stack.sh"
178 exit 1
189fi
Original file line number Diff line number Diff line change 33from time import sleep
44
55
6- # frigga_url = env['FRIGGA_URL'] if 'FRIGGA_URL' in env else "http://localhost:8083" # noqa: 501
7- # prom_url = env['PROM_URL'] if 'PROM_URL' in env else "http://localhost:9090"
8- # prom_yaml_path = env['PROM_YAML_PATH'] if 'PROM_YAML_PATH' in env else "docker-compose/prometheus.yml" # noqa: 501
9- # metrics_json_path = env['METRICS_JSON_PATH'] if 'METRICS_JSON_PATH' in env else ".metrics.json" # noqa: 501
10- # create_backup_file = env['CREATE_BACKUP_FILE'] if 'CREATE_BACKUP_FILE' in env else True # noqa: 501
11- # skip_rules_file = env['SKIP_RULES_FILE'] if 'SKIP_RULES_FILE' in env else False # noqa: 501
12- # grafana_url = env['GRAFANA_URL'] if 'GRAFANA_URL' in env else "http://localhost:3000" # noqa: 501
13- # grafana_api_key = env['GRAFANA_API_KEY'] if 'GRAFANA_API_KEY' in env else None # noqa: 501
146sleep_seconds = float (env ['SLEEP_SECONDS' ]) if 'SLEEP_SECONDS' in env else 15 # noqa: 501
157
168
Original file line number Diff line number Diff line change 77
88from .config import print_msg
99
10- # frigga_url = env['FRIGGA_URL'] if 'FRIGGA_URL' in env else "ws://localhost:8084" # noqa: 501
11- # prom_url = env['PROM_URL'] if 'PROM_URL' in env else "http://localhost:9090"
12- # prom_yaml_path = env['PROM_YAML_PATH'] if 'PROM_YAML_PATH' in env else "docker-compose/prometheus.yml" # noqa: 501
13- # metrics_json_path = env['METRICS_JSON_PATH'] if 'METRICS_JSON_PATH' in env else ".metrics.json" # noqa: 501
14- # create_backup_file = env['CREATE_BACKUP_FILE'] if 'CREATE_BACKUP_FILE' in env else True # noqa: 501
15- # skip_rules_file = env['SKIP_RULES_FILE'] if 'SKIP_RULES_FILE' in env else False # noqa: 501
16- # grafana_url = env['GRAFANA_URL'] if 'GRAFANA_URL' in env else "http://localhost:3000" # noqa: 501
17- # grafana_api_key = env['GRAFANA_API_KEY'] if 'GRAFANA_API_KEY' in env else None # noqa: 501
1810sleep_seconds = float (env ['SLEEP_SECONDS' ]) if 'SLEEP_SECONDS' in env else 30 # noqa: 501
1911
2012
You can’t perform that action at this time.
0 commit comments