-
-
Notifications
You must be signed in to change notification settings - Fork 451
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 a circular loading issue with mongodb::repo #474
Conversation
manifests/repo.pp
Outdated
$ensure = $mongodb::params::ensure, | ||
$version = $mongodb::params::version, | ||
Variant[Enum['present', 'absent'], Boolean] $ensure = 'present', | ||
Optional[String] $version = undef, | ||
$repo_location = undef, | ||
$proxy = undef, | ||
$proxy_username = undef, | ||
$proxy_password = undef, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
can you please align the =
please?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should we align or remove all alignment? With puppet data types I think alignment makes it harder to read.
mongodb::globals includes mongodb::repo mongodb::repo inherits from mongodb::params mongodb::params inherits from globals We work around this by removing the inheritance from mongodb::repo and requiring explicit parameters. We then pass in the parameters explicitly in mongodb::globals. Since repo is a private class this shouldn't be considered breaking an API. While we're at it we add types to the parameters we change. Fixes voxpupuli#428
Rather than disabling it, we should actually remove it. This is cleaner.
Updated with another commit added to only use local vars in |
I have these changes running and can confirm the repo management works. |
What is blocking this? |
@bastelfreak could you re-review this? |
thanks for the patch @ekohl ! |
mongodb::globals includes mongodb::repo mongodb::repo inherits from
mongodb::params mongodb::params inherits from globals
We work around this by removing the inheritance from mongodb::repo and
requiring explicit parameters. We then pass in the parameters explicitly in
mongodb::globals. Since repo is a private class this shouldn't be
considered breaking an API. While we're at it we add types to the
parameters we change.
Fixes #428
Also ensures the yumrepo is absent rather than disabled.