Skip to content

Commit

Permalink
refactor(nsclient): simplify architecture handling
Browse files Browse the repository at this point in the history
  • Loading branch information
dafyddj committed Jan 6, 2025
1 parent 184acd7 commit b34d535
Showing 1 changed file with 5 additions and 8 deletions.
13 changes: 5 additions & 8 deletions nsclient.sls
Original file line number Diff line number Diff line change
Expand Up @@ -11,11 +11,8 @@
- '0.4.3.143'
- '0.4.3.88'
{%- endload%}
# This is to handle the architecture
{%- if grains['cpuarch'] == 'AMD64' %}
{%- set arch_file = "x64" %}
{%- set arch_name = "x64" %}
{%- else %}

{%- if grains["cpuarch"] == "x86" %}
{%- set arch_file = "Win32" %}
{%- set arch_name = "x86" %}
{%- endif %}
Expand All @@ -30,9 +27,9 @@ nsclient:
{%- endif %}

'{{ display_version|d(version) }}':
full_name: 'NSClient++ ({{ arch_name }})'
installer: 'https://github.com/mickem/nscp/releases/download/{{ version }}/NSCP-{{ version }}-{{ arch_file }}.msi'
uninstaller: 'https://github.com/mickem/nscp/releases/download/{{ version }}/NSCP-{{ version }}-{{ arch_file }}.msi'
full_name: 'NSClient++ ({{ arch_name|d("x64") }})'
installer: 'https://github.com/mickem/nscp/releases/download/{{ version }}/NSCP-{{ version }}-{{ arch_file|d("x64") }}.msi'
uninstaller: 'https://github.com/mickem/nscp/releases/download/{{ version }}/NSCP-{{ version }}-{{ arch_file|d("x64") }}.msi'
install_flags: '/quiet'
uninstall_flags: '/quiet'
msiexec: True
Expand Down

0 comments on commit b34d535

Please sign in to comment.