Skip to content

Commit

Permalink
fix for pkg_format var on Windows systems
Browse files Browse the repository at this point in the history
  • Loading branch information
Jan committed Dec 6, 2024
1 parent f5a7629 commit 378ed24
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions roles/install_agent/vars/main.yml
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
---
# vars file for install_agent
pkg_format: "{% if ansible_facts.pkg_mgr in ['yum', 'dnf', 'zypper'] %}rpm{%
elif ansible_facts.pkg_mgr == 'apt' %}deb{%
elif ansible_facts.os_family == 'Windows' and not win_use_exe %}msi{%
elif ansible_facts.os_family == 'Windows' and win_use_exe %}exe{%
pkg_format: "{% if ansible_facts.pkg_mgr | default([]) in ['yum', 'dnf', 'zypper'] %}rpm{%
elif ansible_facts.pkg_mgr | default('') == 'apt' %}deb{%
elif ansible_facts.os_family | default('') == 'Windows' and not win_use_exe %}msi{%
elif ansible_facts.os_family | default('') == 'Windows' and win_use_exe %}exe{%
else %}unknown{% endif %}"
pkg_arch: "{% if ansible_facts.architecture | regex_search('x86_64|64-bit') %}64_bit{%
elif ansible_facts.architecture | regex_search('i386|32-bit') %}32_bit{%
Expand Down

0 comments on commit 378ed24

Please sign in to comment.