Fix distribution fact on DragonFly (#17619)

* By default, ansible_distribution is not set on DragonFly systems,
  preventing some distribution-specific tests from being written

* This commit fixes the issue by returning the quite logical value
  of "DragonFly" when appropriate
pull/16294/merge
ftigeot 8 years ago committed by Brian Coca
parent 66426dcd38
commit 9df8a2565f

@ -673,7 +673,7 @@ class Distribution(object):
self.facts['distribution'] = self.system
self.facts['distribution_release'] = platform.release()
self.facts['distribution_version'] = platform.version()
systems_implemented = ('AIX', 'HP-UX', 'Darwin', 'FreeBSD', 'OpenBSD', 'SunOS')
systems_implemented = ('AIX', 'HP-UX', 'Darwin', 'FreeBSD', 'OpenBSD', 'SunOS', 'DragonFly')
self.facts['distribution'] = self.system
@ -777,6 +777,9 @@ class Distribution(object):
else:
self.facts['distribution_version'] = 'release'
def get_distribution_DragonFly(self):
pass
def get_distribution_Slackware(self, name, data, path):
if 'Slackware' not in data:
return False # TODO: remove

Loading…
Cancel
Save