Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add aio_agent_version fact to 4.2 with fact missing #271

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

choffee
Copy link

@choffee choffee commented Mar 31, 2023

This should fix #270

This only adds it back to the 4.2 versions.

@choffee choffee force-pushed the aio_agent_version branch from 3921b2a to ee3b26d Compare March 31, 2023 11:22
Copy link
Member

@smortex smortex left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Some of these facts do not exist in the real world. If this is blocking the puppet_agent module, maybe the puppetversion fact may be used?

@@ -1,4 +1,5 @@
{
"aio_agent_version": "7.20.0",
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

FreeBSD does not have AIO package.

@@ -1,4 +1,5 @@
{
"aio_agent_version": "7.20.0",
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Same

@@ -1,4 +1,5 @@
{
"aio_agent_version": "7.20.0",
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Same

@@ -1,4 +1,5 @@
{
"aio_agent_version": "7.20.0",
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@bastelfreak may confirm, but I am pretty sure ArchLinux does not have this fact for the same reason as FreeBSD: not an AIO package.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

correct, arch linux does not have it

Copy link
Member

@ekohl ekohl left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think the root cause is that we use Facter, but aio_agent_version comes from Puppet's facts. No custom facts are included in FacterDB so I doubt this is correct.

In rspec-puppet-facts you could work around this with a dynamic custom fact: https://github.com/voxpupuli/rspec-puppet-facts#create-dynamic-facts

add_custom_fact :aio_agent_version, -> { |_os, facts| facts[:puppetversion] }

Or make it more dynamic and filter out the OSes that actually ship AIO

@TheMeier
Copy link
Contributor

outdated, needs rebase

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

ubuntu facts from 21.04 are missing the aio_agent_version fact.
5 participants