diff options
| author | Ahmed Abdelhalim <[email protected]> | 2026-07-21 14:33:55 +0200 |
|---|---|---|
| committer | Ahmed Abdelhalim <[email protected]> | 2026-07-21 14:33:55 +0200 |
| commit | 44d7056b2a069b36077b716a32adfb5b978cd898 (patch) | |
| tree | 50995970f1ecac5ac8300d0216e04cadb95ca87b /roles/prometheus | |
| parent | 5a677725003444d5fc02e4f754392bafaecbde2f (diff) | |
Fix nginx to use conventional ngix conf.d
Diffstat (limited to 'roles/prometheus')
| -rw-r--r-- | roles/prometheus/tasks/main.yml | 2 | ||||
| -rw-r--r-- | roles/prometheus/templates/prometheus.nginx.conf.j2 | 3 |
2 files changed, 4 insertions, 1 deletions
diff --git a/roles/prometheus/tasks/main.yml b/roles/prometheus/tasks/main.yml index 123c1216..9921b441 100644 --- a/roles/prometheus/tasks/main.yml +++ b/roles/prometheus/tasks/main.yml @@ -67,7 +67,7 @@ when: proxy_type == "nginx" and prometheus_hostname | length > 0 ansible.builtin.template: src: "prometheus.nginx.conf.j2" - dest: "/etc/nginx/vhosts.d/prometheus.conf" + dest: "/etc/nginx/conf.d/prometheus.conf" owner: "root" group: "root" mode: "0644" diff --git a/roles/prometheus/templates/prometheus.nginx.conf.j2 b/roles/prometheus/templates/prometheus.nginx.conf.j2 index 5ae9c20c..5c8483f8 100644 --- a/roles/prometheus/templates/prometheus.nginx.conf.j2 +++ b/roles/prometheus/templates/prometheus.nginx.conf.j2 @@ -4,6 +4,9 @@ server { server_name {{ prometheus_hostname }}; + access_log /var/log/nginx/access.log; + error_log /var/log/nginx/error.log; + location / { proxy_pass http://127.0.0.1:{{ prometheus_port }}/; } |
