parent
3378c9f385
commit
eb951f1c2a
|
@ -26,7 +26,7 @@
|
||||||
- name: Check RHEL subscription-manager status
|
- name: Check RHEL subscription-manager status
|
||||||
command: /sbin/subscription-manager status
|
command: /sbin/subscription-manager status
|
||||||
register: rh_subscription_status
|
register: rh_subscription_status
|
||||||
changed_when: "rh_subscription_status != 0"
|
changed_when: "rh_subscription_status.rc != 0"
|
||||||
ignore_errors: true # noqa ignore-errors
|
ignore_errors: true # noqa ignore-errors
|
||||||
become: true
|
become: true
|
||||||
|
|
||||||
|
@ -43,7 +43,6 @@
|
||||||
service_level_agreement: "{{ rh_subscription_sla }}"
|
service_level_agreement: "{{ rh_subscription_sla }}"
|
||||||
sync: true
|
sync: true
|
||||||
notify: RHEL auto-attach subscription
|
notify: RHEL auto-attach subscription
|
||||||
ignore_errors: true # noqa ignore-errors
|
|
||||||
become: true
|
become: true
|
||||||
when:
|
when:
|
||||||
- rh_subscription_org_id is defined
|
- rh_subscription_org_id is defined
|
||||||
|
@ -63,7 +62,6 @@
|
||||||
service_level_agreement: "{{ rh_subscription_sla }}"
|
service_level_agreement: "{{ rh_subscription_sla }}"
|
||||||
sync: true
|
sync: true
|
||||||
notify: RHEL auto-attach subscription
|
notify: RHEL auto-attach subscription
|
||||||
ignore_errors: true # noqa ignore-errors
|
|
||||||
become: true
|
become: true
|
||||||
no_log: "{{ not (unsafe_show_logs|bool) }}"
|
no_log: "{{ not (unsafe_show_logs|bool) }}"
|
||||||
when:
|
when:
|
||||||
|
@ -79,6 +77,7 @@
|
||||||
state: "{{ 'enabled' if (rhel_enable_repos | default(True) | bool) else 'disabled' }}"
|
state: "{{ 'enabled' if (rhel_enable_repos | default(True) | bool) else 'disabled' }}"
|
||||||
when:
|
when:
|
||||||
- ansible_distribution_major_version == "7"
|
- ansible_distribution_major_version == "7"
|
||||||
|
- (not rh_subscription_status.changed) or (rh_subscription_username is defined) or (rh_subscription_org_id is defined)
|
||||||
|
|
||||||
# container-selinux is in appstream repo
|
# container-selinux is in appstream repo
|
||||||
- name: Enable RHEL 8 repos
|
- name: Enable RHEL 8 repos
|
||||||
|
@ -89,6 +88,7 @@
|
||||||
state: "{{ 'enabled' if (rhel_enable_repos | default(True) | bool) else 'disabled' }}"
|
state: "{{ 'enabled' if (rhel_enable_repos | default(True) | bool) else 'disabled' }}"
|
||||||
when:
|
when:
|
||||||
- ansible_distribution_major_version == "8"
|
- ansible_distribution_major_version == "8"
|
||||||
|
- (not rh_subscription_status.changed) or (rh_subscription_username is defined) or (rh_subscription_org_id is defined)
|
||||||
|
|
||||||
- name: Check presence of fastestmirror.conf
|
- name: Check presence of fastestmirror.conf
|
||||||
stat:
|
stat:
|
||||||
|
|
Loading…
Reference in New Issue