summaryrefslogtreecommitdiff
path: root/lib/ansible/module_utils
diff options
context:
space:
mode:
authorRick Elrod <rick@elrod.me>2021-01-05 09:16:59 -0600
committerGitHub <noreply@github.com>2021-01-05 10:16:59 -0500
commit20509b65071291ab6cbe8a279c734902fb4e8383 (patch)
treeb91105331103c59057ec4b238f8ecd88742d942a /lib/ansible/module_utils
parent003a9e890db3a2660fe1a2d95f00dec356b2f3e7 (diff)
downloadansible-20509b65071291ab6cbe8a279c734902fb4e8383.tar.gz
[facts] fix version facts on FreeBSD RC/PRERELEASE (#73020)
Change: - The FreeBSD release can contain -RC or -PRERELEASE in addition to -RELEASE, -STABLE, or -CURRENT. Test Plan: - Added new fixed from an RC version of TrueNAS which uses a -PRERELEASE version of FreeBSD. Tickets: - Fixes #72331 Signed-off-by: Rick Elrod <rick@elrod.me>
Diffstat (limited to 'lib/ansible/module_utils')
-rw-r--r--lib/ansible/module_utils/facts/system/distribution.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/ansible/module_utils/facts/system/distribution.py b/lib/ansible/module_utils/facts/system/distribution.py
index ad56594567..7de506679a 100644
--- a/lib/ansible/module_utils/facts/system/distribution.py
+++ b/lib/ansible/module_utils/facts/system/distribution.py
@@ -586,7 +586,7 @@ class Distribution(object):
def get_distribution_FreeBSD(self):
freebsd_facts = {}
freebsd_facts['distribution_release'] = platform.release()
- data = re.search(r'(\d+)\.(\d+)-(RELEASE|STABLE|CURRENT).*', freebsd_facts['distribution_release'])
+ data = re.search(r'(\d+)\.(\d+)-(RELEASE|STABLE|CURRENT|RC|PRERELEASE).*', freebsd_facts['distribution_release'])
if 'trueos' in platform.version():
freebsd_facts['distribution'] = 'TrueOS'
if data: