diff --git a/roles/grafana/tasks/main.yml b/roles/grafana/tasks/main.yml index bec44338..bd5975a4 100644 --- a/roles/grafana/tasks/main.yml +++ b/roles/grafana/tasks/main.yml @@ -31,6 +31,13 @@ retries: 3 until: apt_result is succeeded +# This capability enables grafana to bind :80 +- name: Add cap_net_bind_service to grafana + capabilities: + path: /usr/sbin/grafana-server + capability: cap_net_bind_service+ep + state: present + - name: Configure Grafana ini_file: path: /etc/grafana/grafana.ini @@ -39,6 +46,9 @@ value: "{{ item.value }}" mode: 0640 loop: + - section: server + option: http_port + value: "80" - section: server option: root_url value: "{{ grafana_root_url }}"