Skip to content

Commit

Permalink
Don't trigger repos salt states for transactional server (#1740)
Browse files Browse the repository at this point in the history
  • Loading branch information
srbarrios authored Oct 22, 2024
1 parent 5c59e92 commit 1efab3d
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 7 deletions.
6 changes: 1 addition & 5 deletions salt/repos/init.sls
Original file line number Diff line number Diff line change
Expand Up @@ -21,15 +21,11 @@ include:
{% endif %}
- repos.additional

{% if grains['os'] == 'SUSE' %}
{% if grains['os'] == 'SUSE' and grains['osfullname'] not in ['SLE Micro', 'SL-Micro'] %}
refresh_repos:
cmd.run:
{% if grains['osfullname'] in ['SLE Micro', 'SL-Micro'] %}
- name: transactional-update -c run zypper --non-interactive --gpg-auto-import-keys refresh --force
{% else %}
- name: zypper --non-interactive --gpg-auto-import-keys refresh --force; exit 0
{% endif %}
{% endif %}

# WORKAROUND: see github:saltstack/salt#10852
{{ sls }}_nop:
Expand Down
3 changes: 1 addition & 2 deletions salt/server/init.sls
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
include:
- scc.server
{% if 'build_image' not in grains.get('product_version', '') and 'paygo' not in grains.get('product_version', '') %}
{% if 'build_image' not in grains.get('product_version', '') and 'paygo' not in grains.get('product_version', '') and grains['osfullname'] not in ['SLE Micro', 'SL-Micro'] %}
- repos
{% endif %}
- server.additional_disk
Expand All @@ -20,7 +20,6 @@ include:
- server.salt_master
- server.tcpdump


{% if 'paygo' not in grains.get('product_version') | default('', true) %}
{% if 'uyuni' not in grains.get('product_version') %}
server-switch-product:
Expand Down

0 comments on commit 1efab3d

Please sign in to comment.