From 0592af628e394d16637b101ba4de0cf4ac555e53 Mon Sep 17 00:00:00 2001 From: Svetlin Kalendzhiev Date: Wed, 27 Jan 2021 16:20:32 +0000 Subject: [PATCH] [FIX] remove hardcoded version values The version of the node exporter is controlled using a variable - node_exporter_version unfortunatelly some of the tasks were not using the variable but instead having hardcoded version strings. This commit removes the hardcoded version strings to ensure changing the version using the variable works as expected --- tasks/binary.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tasks/binary.yml b/tasks/binary.yml index 673781c..55a480a 100644 --- a/tasks/binary.yml +++ b/tasks/binary.yml @@ -24,7 +24,7 @@ - name: "Move node-exporter to the /usr/local/bin/node-exporter" copy: remote_src: true - src: "/tmp/node_exporter-0.14.0.linux-{{ node_exporter_arch }}/node_exporter" + src: "/tmp/node_exporter-{{ node_exporter_version }}.linux-{{ node_exporter_arch }}/node_exporter" dest: "/usr/local/bin/node_exporter" owner: "root" group: "root" @@ -39,6 +39,6 @@ state: "absent" with_items: - "/tmp/node_exporter-{{ node_exporter_version }}.linux-{{ node_exporter_arch }}.tar.gz" - - "/tmp/node_exporter-0.14.0.linux-{{ node_exporter_arch }}/" + - "/tmp/node_exporter-{{ node_exporter_version }}.linux-{{ node_exporter_arch }}/" when: bin.stat.exists == False or bin.stat.checksum != node_exporter_checksum_binary