Skip to content

Commit

Permalink
fix(macos): use pillars for plist sources
Browse files Browse the repository at this point in the history
  • Loading branch information
lmf-mx committed Jul 26, 2023
1 parent 18d5569 commit 671e926
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 4 deletions.
2 changes: 1 addition & 1 deletion salt/master.sls
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ include:
salt-master-macos:
file.managed:
- name: /Library/LaunchDaemons/com.saltstack.salt.master.plist
- source: https://raw.githubusercontent.com/saltstack/salt/master/pkg/osx/scripts/com.saltstack.salt.master.plist
- source: {{ salt_settings.salt_master_macos_plist_source }}
- source_hash: {{ salt_settings.salt_master_macos_plist_hash }}
- retry: {{ salt_settings.retry_options | json }}
- require_in:
Expand Down
2 changes: 1 addition & 1 deletion salt/minion.sls
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ salt-minion-macos:
file.managed:
- onlyif: {{ grains.os == 'MacOS' }}
- name: /Library/LaunchDaemons/com.saltstack.salt.minion.plist
- source: https://raw.githubusercontent.com/saltstack/salt/master/pkg/osx/scripts/com.saltstack.salt.master.plist
- source: {{ salt_settings.salt_minion_macos_plist_source }}
- source_hash: {{ salt_settings.salt_minion_macos_plist_hash }}
- retry: {{ salt_settings.retry_options | json }}
- require_in:
Expand Down
9 changes: 7 additions & 2 deletions salt/osmap.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,9 @@
{%- set repoarch = salt['grains.get']('osarch') %}
{%- set osrelease = salt['grains.get']('osrelease', '') %}
{%- set salt_release = salt['pillar.get']('salt:release', 'latest') %}
{%- if salt_release != "latest" %}
{%- set salt_release_major = salt_release.split('.') | map('.') | list | first %}
{%- endif %}
{%- if salt_release.split('.')|length >= 3 %}
{%- set salt_release = 'archive/' ~ salt_release %}
{%- endif %}
Expand Down Expand Up @@ -69,8 +72,10 @@ SmartOS:
MacOS:
minion_service: com.saltstack.salt.minion
master_service: com.saltstack.salt.master
salt_master_macos_plist_hash: 8435331b2d48ca8f0759f216e5b15ec9171a4216b1441328c732c6906728b7c9
salt_minion_macos_plist_hash: 26b33da12e0d8960ee96b488c8352002c22a377c19bf3df3f986a1e49eca8b20
salt_master_macos_plist_source: https://github.com/saltstack/salt/raw/master/pkg/macos/scripts/com.saltstack.salt.master.plist
salt_minion_macos_plist_source: https://github.com/saltstack/salt/raw/master/pkg/macos/scripts/com.saltstack.salt.minion.plist
salt_master_macos_plist_hash: 97666226c14ec2fd755edb5d909688540a36408dfe9fb34a1c15676020376ace
salt_minion_macos_plist_hash: 17d9556b5742a785eaddaec117132be99af138cab7157dbacbda2058538b6e69

FreeBSD:
salt_master: py39-salt
Expand Down

0 comments on commit 671e926

Please sign in to comment.