Skip to content

Commit

Permalink
fix: stdout and stderr for exporter version check
Browse files Browse the repository at this point in the history
  • Loading branch information
tboerger committed Nov 22, 2021
1 parent db4827f commit cbc36f6
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions tasks/exporter.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,13 +5,13 @@
failed_when: False
changed_when: False
check_mode: False
command: /usr/bin/mariadb-exporter --version
shell: /usr/bin/mariadb-exporter --version 2>&1
tags:
- mariadb-exporter

- name: Fact version change
set_fact:
mariadb_exporter_version_changed: "{{ mariadb_exporter_version_check.rc != 0 or (mariadb_exporter_version_check.stderr_lines is defined and mariadb_exporter_version not in mariadb_exporter_version_check.stderr_lines[0]) | bool }}"
mariadb_exporter_version_changed: "{{ mariadb_exporter_version_check.rc != 0 or (mariadb_exporter_version_check.stdout_lines is defined and mariadb_exporter_version not in mariadb_exporter_version_check.stdout_lines[0]) | bool }}"
tags:
- mariadb-exporter

Expand Down

0 comments on commit cbc36f6

Please sign in to comment.