mirror of
https://github.com/ansible-collections/community.general.git
synced 2025-06-21 15:50:22 -07:00
facts: suse: fix SLES4SAP12 detection (#44388)
This commit is contained in:
parent
d5a4a401ea
commit
b6b238ae43
2 changed files with 62 additions and 1 deletions
|
@ -269,6 +269,10 @@ class DistributionFiles:
|
|||
else:
|
||||
release = "0" # no minor number, so it is the first release
|
||||
suse_facts['distribution_release'] = release
|
||||
# Starting with SLES4SAP12 SP3 NAME reports 'SLES' instead of 'SLES_SAP'
|
||||
# According to SuSe Support (SR101182877871) we should use the CPE_NAME to detect SLES4SAP
|
||||
if re.search("^CPE_NAME=.*sles_sap.*$", line):
|
||||
suse_facts['distribution'] = 'SLES_SAP'
|
||||
elif path == '/etc/SuSE-release':
|
||||
if 'open' in data.lower():
|
||||
data = data.splitlines()
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue