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

chef-ingredient assumes connection to the interwebs #62

Closed
thenoid opened this Issue Nov 13, 2015 · 5 comments

Comments

Projects
None yet
5 participants
@thenoid

thenoid commented Nov 13, 2015

Chef-ingredient assumes that the host it is running on is connected to the internet and configures/depends on the yum-chef/apt-chef.

https://github.com/chef-cookbooks/chef-ingredient/blob/master/libraries/rhel_handler.rb#L57
https://github.com/chef-cookbooks/chef-ingredient/blob/master/libraries/rhel_handler.rb#L64

Not all installs have direct access to the interwebs, even if they do, should this cookbook really assume that people want to pull directly from there? They could have the packages mirrored internally using satellite/katello/spacewalk/artifactory, etc. and do so for good reason audit/compliance/blah/blah

While it is nice having the cookbook that works soup-to-nuts, perhaps provide the capability to say "i'll provide my own toys" and install the package w/out all the assumptions.

@jtimberman

This comment has been minimized.

Show comment
Hide comment
@jtimberman

jtimberman Dec 1, 2015

Member

You can specify a package_source when using the chef_ingredient. An example of this is in the test::local recipe.

You can also override the yum-chef attributes to change where the yum repository is.

Member

jtimberman commented Dec 1, 2015

You can specify a package_source when using the chef_ingredient. An example of this is in the test::local recipe.

You can also override the yum-chef attributes to change where the yum repository is.

@jtimberman jtimberman closed this Dec 1, 2015

@chilicheech

This comment has been minimized.

Show comment
Hide comment
@chilicheech

chilicheech Dec 2, 2015

hey, @jtimberman, we had some good discussion about this in the 2 PRs referenced above.

package_source allows you to specify a local file to install and the installation is performed with RPM instead of YUM. It doesn't let you specify a yum repo.

Also, yum-chef does allow you to change attributes for the default recipe, not for current or stable, which is what chef_ingredient uses. As you can see, the https://github.com/chef-cookbooks/yum-chef/blob/master/recipes/stable.rb recipe doesn't allow you to customize the yum repo.

As you can see here: https://github.com/chef-cookbooks/chef-ingredient/blob/master/libraries/rhel_handler.rb#L57 and here: https://github.com/chef-cookbooks/chef-ingredient/blob/master/libraries/chef_ingredient_resource.rb#L30 only the current and stable recipes are used by chef_ingredient. Therefore, you actually "can't" override the yum-chef attributes to change where the yum repo is.

Please re-open this issue. If I'm failing to see what you're trying to say, please elaborate further.

Cheers,

chilicheech commented Dec 2, 2015

hey, @jtimberman, we had some good discussion about this in the 2 PRs referenced above.

package_source allows you to specify a local file to install and the installation is performed with RPM instead of YUM. It doesn't let you specify a yum repo.

Also, yum-chef does allow you to change attributes for the default recipe, not for current or stable, which is what chef_ingredient uses. As you can see, the https://github.com/chef-cookbooks/yum-chef/blob/master/recipes/stable.rb recipe doesn't allow you to customize the yum repo.

As you can see here: https://github.com/chef-cookbooks/chef-ingredient/blob/master/libraries/rhel_handler.rb#L57 and here: https://github.com/chef-cookbooks/chef-ingredient/blob/master/libraries/chef_ingredient_resource.rb#L30 only the current and stable recipes are used by chef_ingredient. Therefore, you actually "can't" override the yum-chef attributes to change where the yum repo is.

Please re-open this issue. If I'm failing to see what you're trying to say, please elaborate further.

Cheers,

@afiune

This comment has been minimized.

Show comment
Hide comment
@afiune

afiune Dec 4, 2015

Contributor

+1 On this issue. I am re-opening and taking ownership since it makes total sense for enterprises that does not have access to the internet.

Contributor

afiune commented Dec 4, 2015

+1 On this issue. I am re-opening and taking ownership since it makes total sense for enterprises that does not have access to the internet.

@afiune afiune reopened this Dec 4, 2015

@sersut

This comment has been minimized.

Show comment
Hide comment
@sersut

sersut Dec 4, 2015

Contributor

Thanks @afiune for checking this out. We have a proposal here:

#65 (comment)

What do you think about that?

Contributor

sersut commented Dec 4, 2015

Thanks @afiune for checking this out. We have a proposal here:

#65 (comment)

What do you think about that?

@afiune

This comment has been minimized.

Show comment
Hide comment
@afiune

afiune Dec 4, 2015

Contributor

That is terrific! Exactly what I have in mind!! 😄

Is there anybody working in this or should I go ahead and code it?

On Friday, December 4, 2015, Serdar Sutay notifications@github.com wrote:

Thanks @afiune https://github.com/afiune for checking this out. We have
a proposal here:

#65 (comment)
#65 (comment)

What do you think about that?


Reply to this email directly or view it on GitHub
#62 (comment)
.

Salim Afiune — Solutions Engineer

917.716.0448 – afiune@chef.io – *my: *Linkedin
http://www.linkedin.com/in/afiune Twitter http://www.twitter.com/afiune

CHEF

  CHEF.IO <http://www.chef.io/>

TM

chef.io http://www.chef.io/ Blog http://www.chef.io/blog/ Facebook
https://www.facebook.com/getchefdotcom Twitter
https://twitter.com/chef Youtube https://www.youtube.com/getchef

Contributor

afiune commented Dec 4, 2015

That is terrific! Exactly what I have in mind!! 😄

Is there anybody working in this or should I go ahead and code it?

On Friday, December 4, 2015, Serdar Sutay notifications@github.com wrote:

Thanks @afiune https://github.com/afiune for checking this out. We have
a proposal here:

#65 (comment)
#65 (comment)

What do you think about that?


Reply to this email directly or view it on GitHub
#62 (comment)
.

Salim Afiune — Solutions Engineer

917.716.0448 – afiune@chef.io – *my: *Linkedin
http://www.linkedin.com/in/afiune Twitter http://www.twitter.com/afiune

CHEF

  CHEF.IO <http://www.chef.io/>

TM

chef.io http://www.chef.io/ Blog http://www.chef.io/blog/ Facebook
https://www.facebook.com/getchefdotcom Twitter
https://twitter.com/chef Youtube https://www.youtube.com/getchef

afiune added a commit that referenced this issue Dec 9, 2015

Do not assume connection to the interwebs
Provides the ability to "Bring Your Own Repo Setup Recipe" for companies
where direct connections to the internet are not possible.

Setting `node['chef-ingredient']['custom_repo_setup_recipe']` pointing
to your own repository setup recipe will avoid the creation of any
**chef** specific repo pointing to packagecloud.

Closes #62
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment