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

Fix docker fact with recent version of docker #897

Merged
merged 2 commits into from
Feb 28, 2023

Conversation

smortex
Copy link
Collaborator

@smortex smortex commented Feb 14, 2023

The docker nested fact is supposed to be conditionaly build if the
docker client version is 1.13 or greater, as changed in #166.

Unfortunately, the regexp is not working as expected, and future tweaks
of the regexp did not fix it.

Fix the regexp to match versions greater are equal to 1.13.*. Add a few
unit tests to verify the outcome.

Fixes #896

The `docker` nested fact is supposed to be conditionaly build if the
docker client version is 1.13 or greater, as changed in #166.

Unfortunately, the regexp is not working as expected, and future tweaks
of the regexp did not fix it.

Fix the regexp to match versions greater are equal to 1.13.*.  Add a few
unit tests to verify the outcome.

Fixes #896
@smortex smortex force-pushed the fix-facter-version-matching branch from 4e4ce92 to ddb5092 Compare February 14, 2023 20:26
@smortex smortex marked this pull request as ready for review February 14, 2023 20:33
@smortex smortex requested a review from a team as a code owner February 14, 2023 20:33
@smortex smortex added the bugfix label Feb 14, 2023
bastelfreak
bastelfreak previously approved these changes Feb 14, 2023
@smortex
Copy link
Collaborator Author

smortex commented Feb 15, 2023

After restarting the failing builds 8 times, it finally passed ✌️

@jaketus
Copy link

jaketus commented Feb 21, 2023

Please merge this with the mainstream ASAP, as new docker versions aren't detected by the old regexp and therefore the module currently requires patching downstream before use.

@vitargelo
Copy link

I can't set up a lower docker version on Ubuntu focal.

class { 'docker':
    version      => '5:20.10.21~3-0~ubuntu-focal',
    .....
  }
}

This configuration installs the latest 23.0.1 docker version. ensure => absent and fresh install didn't help.
Is this a related issue? Or do I need to create a new one?

Copy link
Contributor

@LukasAud LukasAud left a comment

Choose a reason for hiding this comment

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

LGTM

@LukasAud LukasAud merged commit ca30099 into main Feb 28, 2023
@LukasAud LukasAud deleted the fix-facter-version-matching branch February 28, 2023 10:20
@LukasAud
Copy link
Contributor

Thanks for you contribution!

@LukasAud
Copy link
Contributor

@vitargelo If you are still experiencing problems, please raise an issue in our Issues section.

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

Successfully merging this pull request may close these issues.

"docker" fact not working on 23.0.1
6 participants