Skip to content
This repository has been archived by the owner on Jun 19, 2020. It is now read-only.

Add *BSD kernelversion and kernelmajversion facts #462

Merged
merged 2 commits into from
Apr 29, 2020

Conversation

smortex
Copy link
Contributor

@smortex smortex commented Apr 21, 2020

Use the kernel release to compute the kernelversion and kernelmajversion facts on *BSD.

The Solaris code which facter currently fallbacks to does not gather correct information.

The release string may look like 12.1-RELEASE-p3 on FreeBSD or 6.6 on OpenBSD, so consider the kernelversion to be the sequence of digits separated by dots at the beginning of the release name, and kernelmajversion to be the number before the first dot.

This allows facter-ng to give consistent results for these facts with those returned by facter 3.

@smortex smortex requested review from a team April 21, 2020 04:06
@puppetlabs-jenkins
Copy link
Collaborator

Can one of the admins verify this patch?

@BogdanIrimie BogdanIrimie merged commit 60117e2 into puppetlabs:master Apr 29, 2020
@smortex smortex deleted the bsd-kernel-info branch April 29, 2020 19:05
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants