Skip to content

Commit

Permalink
Refactor filters section
Browse files Browse the repository at this point in the history
  • Loading branch information
LDiazN committed Mar 7, 2025
1 parent 6c20f6c commit 27c1c75
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions ansible/roles/prometheus/templates/prometheus.yml
Original file line number Diff line number Diff line change
Expand Up @@ -225,7 +225,7 @@ scrape_configs:
secret_key: "{{prometheus_aws_secret_key_dev}}"
region: "eu-central-1"
port: 9100
filters:
filters: &instance_filters
- name: instance-state-name
values: ['running']
relabel_configs: &ec2_relabeling # Change the host to the proxy host with relabeling
Expand Down Expand Up @@ -273,9 +273,8 @@ scrape_configs:
secret_key: "{{prometheus_aws_secret_key_prod}}"
region: "eu-central-1"
port: 9100
filters:
- name: instance-state-name
values: ['running']
filters:
*instance_filters
relabel_configs: # Change the host to the proxy host with relabeling
*ec2_relabeling

Expand Down

0 comments on commit 27c1c75

Please sign in to comment.