diff --git a/elk_metrics_6x/templates/metricbeat.yml.j2 b/elk_metrics_6x/templates/metricbeat.yml.j2 index 2055fe16..94f3ff52 100644 --- a/elk_metrics_6x/templates/metricbeat.yml.j2 +++ b/elk_metrics_6x/templates/metricbeat.yml.j2 @@ -351,7 +351,7 @@ metricbeat.modules: # # Host DSN should be defined as "user:pass@tcp(127.0.0.1:3306)/" # # The username and password can either be set in the DSN or using the username # # and password config options. Those specified in the DSN take precedence. - hosts: ["{{ galera_root_user }}:{{ galera_root_password }}@tcp(127.0.0.1:3306)/"] + hosts: ["{{ galera_root_user }}:{{ galera_root_password }}@tcp({{ ansible_hostname }}:3306)/"] # # # Username of hosts. Empty by default. username: {{ galera_root_user }}