From ba987198cd381a10b5075eac599fee9d2f6219d9 Mon Sep 17 00:00:00 2001 From: Kamil Wiatrowski Date: Wed, 3 Oct 2018 14:59:28 +0200 Subject: Add role to auto install docker on hosts - missing patch Small updates to ansible roles. Several minor updates in documentation. Change-Id: Id031cebc23301b6218f8ced0d261f844f270e37f Signed-off-by: Kamil Wiatrowski --- docker/ansible/roles/config_files/tasks/mcelog.yml | 2 ++ docker/ansible/roles/config_files/vars/main.yml | 5 ++++- docker/ansible/roles/run_grafana/vars/main.yml | 4 ++-- 3 files changed, 8 insertions(+), 3 deletions(-) (limited to 'docker/ansible/roles') diff --git a/docker/ansible/roles/config_files/tasks/mcelog.yml b/docker/ansible/roles/config_files/tasks/mcelog.yml index bab4b142..794db98c 100644 --- a/docker/ansible/roles/config_files/tasks/mcelog.yml +++ b/docker/ansible/roles/config_files/tasks/mcelog.yml @@ -17,6 +17,7 @@ package: name: mcelog state: present + ignore_errors: "true" when: install_mcelog|default(false)|bool tags: - mcelogs @@ -26,6 +27,7 @@ name: mcelog state: started enabled: true + ignore_errors: "true" when: install_mcelog|default(false)|bool tags: - mcelogs diff --git a/docker/ansible/roles/config_files/vars/main.yml b/docker/ansible/roles/config_files/vars/main.yml index bfa0fd68..ab4a7867 100644 --- a/docker/ansible/roles/config_files/vars/main.yml +++ b/docker/ansible/roles/config_files/vars/main.yml @@ -23,7 +23,10 @@ interval_value: 10 #network plugin vars network_port: 25826 -network_ip_addr: "{{ (groups['influxdb_hosts']|default({}))[0] | default('localhost') }}" +#get influxdb name as defined in inventory +influxdb_hostname: "{{ (groups['influxdb_hosts']|default({}))[0] | default('localhost') }}" +#get hostname as used by ansible +network_ip_addr: "{{ hostvars[influxdb_hostname].ansible_hostname }}" #ovs event and stats plugin vars ovs_event_interval: 1 diff --git a/docker/ansible/roles/run_grafana/vars/main.yml b/docker/ansible/roles/run_grafana/vars/main.yml index 5caf45da..0975b598 100644 --- a/docker/ansible/roles/run_grafana/vars/main.yml +++ b/docker/ansible/roles/run_grafana/vars/main.yml @@ -13,5 +13,5 @@ # limitations under the License. --- -influxdb_hostname: influxdb_host -influxdb_host_ip: "{{ (groups['influxdb_hosts']|default({}))[0] | default('localhost') }}" +influxdb_hostname: localhost +influxdb_host_ip: 127.0.0.1 -- cgit 1.2.3-korg