-
Notifications
You must be signed in to change notification settings - Fork 54
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
Bring Your Own Packages #62 #65
Conversation
Hmmm that rubocop failure is from a line I didn't modify ={ |
@thenoid rather than introducing a new flag, does |
@@ -34,6 +34,10 @@ def handle_uninstall | |||
private | |||
|
|||
def configure_package(action_name) | |||
byop = !node['chef-ingredient'].nil? && \ |
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.
since this is used in multiple places a helper function could be used instead, called byop?
maybe..
Hmm, I think worrying about copying RPMS to a host locally defeats what i'm going for with this PR, which is primarily that chef-ingredient shouldn't assume that a host is directly connected to the internet. It's should either have a flag, such as byop, or relegate configuration of yum/apt to outside the cookbook. People know how there systems are/should be configured. I just wasn't sure how people would feel if i submitted a PR that stripped all the yum/apt stuff out....call me a nervous pull-requester ;) |
Chef-ingredient should focus installing ingredients and if a soup-to-nuts solution that should wrap the two together. |
chef-ingredient allows you to specify what channel to install from, either stable or current. pr #69 allows you to install from a custom channel. you would then set the appropriate node attributes for the yum-chef cookbook to create that yum repo file. yum-chef does exactly as you described. just need chef-ingredient to support the custom channel. with that in mind, i also like the idea of skipping the yum-chef cookbook entirely, giving you the option of setting up the yum repo file yourself beforehand. |
I like that idea too [of disabling entirely] ! cause #69 doesn't address my concern fully. I don't want/need to specify a custom URL, we use spacewalk/satellite/katello/satellite6 (and there are other products out there) for all our RPMS. So the moment this code
is run without condition my heart fills with sadness! This is the second large enterprise i've worked ( first being healthcare, second being security) where hosts aren't allowed direct access to the internet. So for a cookbook that is included as part of core component installers, push-jobs for example, that forcefully configures yum, which intern breaks yum, which intern breaks chef is no es bueno. I do get the want/need to have a magic cookbook that uses chef to configure chef so you can chef the chef - yo dawg memes for days - but perhaps that should be part of something larger and chef-ingredient should do one thing well? |
Thanks for thinking about this problem @thenoid & @chilicheech. I think the right solution for this will be to have a new attribute for this cookbooks called
We need to keep in mind that "custom" means different things to different people. So we can not assume a shape or form of repo setup when we are in custom repo setup mode. We also need to make another minor change to the usage of Let me know what you guys think about this. |
@sersut seems like that will work for my use case. There may also be a use case for skipping setting up the yum repo altogether because it's already set up. As for the repo locking, it is necessary for my use cases, but what you outlined will work because then I can set the locking in the Maybe a new property called Thanks for looking into this. |
In the default case we do not want to make locking the repos optional. Because that would be problematic if one is installing some products (e.g. chef-server) from Also we would like the keep the API of chef-ingredient as basic as possible. Since custom locking functionality would be achievable via Thanks to you for looking into this 😄 |
Replaced by #74 |
Provides the ability to "Bring Your Own Packages" for companies where direct connections to the internet are not possible - as referenced in #62