Skip to content

Commit

Permalink
use prometheus label override
Browse files Browse the repository at this point in the history
  • Loading branch information
oscgonfer committed Feb 23, 2024
1 parent e82503a commit 3fa960f
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 16 deletions.
5 changes: 3 additions & 2 deletions env.example
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,7 @@ kairos_http_password=some_password
AUTH_SECRET_KEY_BASE=CreateSomeVeryLongLongLongRandomStringHere

# GRAFANA
PROMETHEUS_HOST=
PROMETHEUS_URL=
PROMETHEUS_USERNAME=
PROMETHEUS_PASSWORD=
PROMETHEUS_PASSWORD=
PROMETHEUS_INSTANCE_LABEL=
19 changes: 5 additions & 14 deletions scripts/grafana/agent.yaml
Original file line number Diff line number Diff line change
@@ -1,24 +1,15 @@
prometheus:
server:
log_level: info
metrics:
wal_directory: /tmp/grafana-agent-wal
global:
scrape_interval: 15s
configs:
- name: integrations
scrape_configs:
- job_name: integrations/nodejs
static_configs:
- targets:
- localhost:4001
remote_write:
- url: ${PROMETHEUS_HOST}
basic_auth:
username: ${PROMETHEUS_USERNAME}
password: ${PROMETHEUS_PASSWORD}
integrations:
node_exporter:
enabled: true
instance: ${PROMETHEUS_INSTANCE_LABEL}
prometheus_remote_write:
- url: ${PROMETHEUS_HOST}
- url: ${PROMETHEUS_URL}
basic_auth:
username: ${PROMETHEUS_USERNAME}
password: ${PROMETHEUS_PASSWORD}

0 comments on commit 3fa960f

Please sign in to comment.