-
-
Notifications
You must be signed in to change notification settings - Fork 94
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Update NOTES.txt to include prometheus config
- Loading branch information
Showing
1 changed file
with
19 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
1. Forward the application port by running these commands: | ||
|
||
export POD_NAME=$(kubectl get pods --namespace {{ .Release.Namespace }} -l "app={{ include "promitor-scraper.name" . }},release={{ .Release.Name }}" -o jsonpath="{.items[0].metadata.name}") | ||
kubectl port-forward $POD_NAME 8080:{{ .Values.service.targetPort }} | ||
|
||
2. Check the scraping output at http://127.0.0.1:8080{{ .Values.scrapeConfig.path }} | ||
|
||
3. To set up Prometheus in your cluster & pull in metrics from Promitor's scraping output, run: | ||
|
||
export CLUSTER_IP=$(kubectl get svc --namespace {{ .Release.Namespace }} -l "app={{ include "promitor-scraper.name" . }},release={{ .Release.Name }}" -o jsonpath="{.items[0].spec.clusterIP}") | ||
cat > promitor-scrape-config.yaml <<EOF | ||
extraScrapeConfigs: | | ||
- job_name: {{ .Release.Name }} | ||
metrics_path: {{ .Values.scrapeConfig.path }} | ||
static_configs: | ||
- targets: | ||
- $CLUSTER_IP:{{ .Values.service.port }} | ||
EOF | ||
helm install stable/prometheus -f promitor-scrape-config.yaml |