-
Notifications
You must be signed in to change notification settings - Fork 103
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
CFE-4450: Allow passing environment variables to package managers #2963
base: master
Are you sure you want to change the base?
Conversation
Do you have some explicit examples of the use case for each of the package managers as well? |
For APT, for example controling needrestart's behavior. But the main use case is for non-standard packages that allow customizing the configuration through env vars used in the postinst script. GitLab is one of them (https://docs.gitlab.com/omnibus/installation/index.html#set-up-the-initial-account):
|
From my side I think it makes sense, I will invite @olehermanse @craigcomstock to bike shed a bit. |
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.
Seems fine to me. Seeing this change here kind of begs to have a common python script to share such repeated code.
Also, it's a shame to not have the same for non-python modules if they even need it. For example, apk for alpine, but I have never needed to use env vars so probably fine. We can leave the complex usage to the complex systems: apt, yum and zypper. ;)
Definitely was looking for documentation and examples (a test case is usually a great example) before I read your description. So with those two pieces this looks good to me!
Thanks for the contribution!
I created some basic documentation in cfengine/documentation#3374. I also took a look at the tests but it seems there are no tests covering the |
1e58dfd
to
31b014d
Compare
Allow passing options to the package managers modules through
env:NAME=VERSION
options.Taking the easiest path. If it is considered acceptable I'll add a test case and documentation.