puppet-nodejs icon indicating copy to clipboard operation
puppet-nodejs copied to clipboard

nodejs::repo::nodesource::baseurl and source_baseurl override

Open cdenneen opened this issue 7 years ago • 2 comments

Allowing for mirrors this needs the ability to override.

Having to do something like this is really bad:

Yumrepo<| title == 'nodesource' |> { baseurl = "https://mirror...."} Yumrepo<| title == 'nodesource-source' |> { baseurl = "https://mirror...."}

cdenneen avatar Feb 22 '18 20:02 cdenneen

@cdenneen Hmmm, with this type of use case I think the better and cleaner alternative is to manage the yumrepo resource yourself using the $repo_class parameter. This kind of approach is more or less consistent with how upstream repository configuration is included with modules elsewhere. If you're using a virtual repository manager like Nexus, Artifactory etc or simply want to manage repositories outside of this module setting $manage_package_repo to false is an option as well.

juniorsysadmin avatar Feb 25 '18 01:02 juniorsysadmin

There are many packages that allow for the prefix to be supplied for example: https://github.com/sensu/sensu-puppet/blob/master/manifests/init.pp#L447

This allows for you to setup an internal mirror of the external resource but allows for the "suffix" naming changes as needed by the module to account for upstream to continue to work as expected.

I can have it unmanage the repo and do outside the class but it would be useful to have as parameter.

cdenneen avatar Feb 26 '18 19:02 cdenneen