Jakub Sokołowski a57950a038
configure Nginx proxy for use with ssl-proxy
Otherwise we can't block access to certain sensitive paths like `/metrics`.

https://github.com/status-im/infra-hq/issues/73

Signed-off-by: Jakub Sokołowski <jakub@status.im>
2022-03-30 16:11:27 +02:00

30 lines
1.1 KiB
YAML

---
- name: Create Consul service definition
include_role: name=consul-service
vars:
consul_config_name: '{{ grafana_service_name }}'
consul_services:
- id: '{{ grafana_service_name }}:{{ grafana_domain }}'
name: '{{ grafana_service_name }}'
tags: ['grafana', 'monitor']
port: '{{ grafana_cont_port }}'
address: '{{ ansible_local.wireguard.vpn_ip }}'
checks:
- id: '{{ grafana_service_name }}-health'
name: 'Grafana Health'
type: 'http'
http: 'http://localhost:{{ grafana_cont_port }}/api/health'
- id: '{{ grafana_service_name }}-proxy:{{ grafana_domain }}'
name: '{{ grafana_service_name }}-proxy'
tags: ['grafana', 'monitor', 'ssl-proxy-backend']
port: '{{ grafana_proxy_port }}'
address: '{{ ansible_local.wireguard.vpn_ip }}'
meta:
proxy_fqdn: '{{ grafana_domain | mandatory }}'
checks:
- id: '{{ grafana_service_name }}-proxy-health'
name: 'Grafana Proxy Health'
type: 'http'
http: 'http://localhost:{{ grafana_proxy_port }}/health'