# Installation instructions for offline install on RHEL

**URL:** <https://discourse.chef.io/t/installation-instructions-for-offline-install-on-rhel/1686>\
**Category:** Chef Infra (archive)\
**Created:** [January 4, 2011, 5:36pm UTC](https://discourse.chef.io/t/installation-instructions-for-offline-install-on-rhel/1686 "2011-01-04T17:36:11Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![Meppiel\_Josh](https://avatars.discourse-cdn.com/v4/letter/m/bc79bd/32.png) [@Meppiel\_Josh](https://discourse.chef.io/u/Meppiel_Josh)\
**Post date:** [January 4, 2011, 5:36pm UTC](https://discourse.chef.io/t/installation-instructions-for-offline-install-on-rhel/1686/1 "2011-01-04T17:36:11Z")

</div>

Are there instructions for the installation of Chef on a RHEL 5.4/5.5 box without access to the internet? All instructions I see on the OpsCode website, including those for installation from source, dictate that the host has direct access to the internet. I would be fine with installation from source, tarball explode, or RPM’s.

-Josh

CONFIDENTIALITY NOTICE This e-mail message and any attachments are only for the use of the intended recipient and may contain information that is privileged, confidential or exempt from disclosure under applicable law. If you are not the intended recipient, any disclosure, distribution or other use of this e-mail message or attachments is prohibited. If you have received this e-mail message in error, please delete and notify the sender immediately. Thank you.

---

<div class="post-metadata">

**Author:** ![John\_E\_Vincent\_lusis](https://avatars.discourse-cdn.com/v4/letter/j/c89c15/32.png) [@John\_E\_Vincent\_lusis](https://discourse.chef.io/u/John_E_Vincent_lusis)\
**Post date:** [January 4, 2011, 5:46pm UTC](https://discourse.chef.io/t/installation-instructions-for-offline-install-on-rhel/1686/2 "2011-01-04T17:46:24Z")

</div>

On Tue, Jan 4, 2011 at 12:36 PM, Meppiel, Josh  
[josh\_meppiel@mastercard.com](mailto:josh_meppiel@mastercard.com) wrote:

> Are there instructions for the installation of Chef on a RHEL 5.4/5.5 box  
> without access to the internet? All instructions I see on the OpsCode  
> website, including those for installation from source, dictate that the host  
> has direct access to the internet. I would be fine with installation from  
> source, tarball explode, or RPM’s.
> 
> -Josh

I've been in your shoes, not just with Chef.

You have a couple of options

- Package the gems into RPMS yourself and install them (along with  
config files that way)
- Create a local gem server to host the gems and point all of your nodes there

If you're planning on using 'knife bootstrap', take a look at the  
bootstrap templates. That's where you're going to get the most  
flexibility and you'll understand exactly what happens when a node is  
bootstrapped. Here's an example:

> <https://gist.github.com/lusis/765086>

You can see all of the templates available in  
'lib/chef/knife/bootstrap' where your chef gems were installed  
locally. You'll probably need to create a custom one, copy it to the  
.chef directory of your local chef repo and then bootstrap a new node  
like so:

knife bootstrap FQDN -N nickname -i -x root -d -r "role[base]"

So esssentially, you would want to modify the steps in the first part  
of the gist to pull everything from a local repository.

If you want to run your own gem server, see here:

[http://docs.rubygems.org/read/chapter/18](http://docs.rubygems.org/read/chapter/18)

John

---

<div class="post-metadata">

**Author:** ![Jesse\_Nelson](https://sea2.discourse-cdn.com/flex016/user_avatar/discourse.chef.io/jesse_nelson/32/262_2.png) [@Jesse\_Nelson](https://discourse.chef.io/u/Jesse_Nelson)\
**Post date:** [January 4, 2011, 5:56pm UTC](https://discourse.chef.io/t/installation-instructions-for-offline-install-on-rhel/1686/3 "2011-01-04T17:56:02Z")

</div>

I've moved to using bundler to package all the chef gems into an rpm to make  
monolithic chef-client and chef-server rpm's. This is serving us well, and  
way simpler to manage if you want to track the chef gem releases faster.  
Happy to share the src rpm's if there's interest. It's just a Gemfile and a  
spec per project (client/server).

On 1/4/11 9:46 AM, "John E. Vincent (lusis)" [lusis.org+chef-list@gmail.com](mailto:lusis.org+chef-list@gmail.com)  
wrote:

> On Tue, Jan 4, 2011 at 12:36 PM, Meppiel, Josh  
> [josh\_meppiel@mastercard.com](mailto:josh_meppiel@mastercard.com) wrote:
> 
> > Are there instructions for the installation of Chef on a RHEL 5.4/5.5 box  
> > without access to the internet? All instructions I see on the OpsCode  
> > website, including those for installation from source, dictate that the host  
> > has direct access to the internet. I would be fine with installation from  
> > source, tarball explode, or RPM¹s.
> > 
> > -Josh
> 
> I've been in your shoes, not just with Chef.
> 
> You have a couple of options
> 
> - Package the gems into RPMS yourself and install them (along with  
> config files that way)
> - Create a local gem server to host the gems and point all of your nodes there
> 
> If you're planning on using 'knife bootstrap', take a look at the  
> bootstrap templates. That's where you're going to get the most  
> flexibility and you'll understand exactly what happens when a node is  
> bootstrapped. Here's an example:
> 
> [A sample centos5 chef bootstrap template from Ruby gems · GitHub](https://gist.github.com/765086)
> 
> You can see all of the templates available in  
> 'lib/chef/knife/bootstrap' where your chef gems were installed  
> locally. You'll probably need to create a custom one, copy it to the  
> .chef directory of your local chef repo and then bootstrap a new node  
> like so:
> 
> knife bootstrap FQDN -N nickname -i -x root -d -r "role[base]"
> 
> So esssentially, you would want to modify the steps in the first part  
> of the gist to pull everything from a local repository.
> 
> If you want to run your own gem server, see here:
> 
> [http://docs.rubygems.org/read/chapter/18](http://docs.rubygems.org/read/chapter/18)
> 
> John

---

<div class="post-metadata">

**Author:** ![Seth\_Chisamore](https://sea2.discourse-cdn.com/flex016/user_avatar/discourse.chef.io/seth_chisamore/32/488_2.png) [@Seth\_Chisamore](https://discourse.chef.io/u/Seth_Chisamore)\
**Post date:** [January 4, 2011, 5:56pm UTC](https://discourse.chef.io/t/installation-instructions-for-offline-install-on-rhel/1686/4 "2011-01-04T17:56:16Z")

</div>

Also be aware of RHEL/CentOS sudoers (env\_reset) PATH issues:  
[http://wiki.opscode.com/display/chef/User+Environment+PATH+Sanity](http://wiki.opscode.com/display/chef/User+Environment+PATH+Sanity)

The Chef Providers and Ohai plugins relies on the PATH being set correctly as they do not hardcode paths when running system commands. We do this because we don't want to make assumptions about where programs might live for every single platform.

-Seth

--  
Opscode, Inc.  
Seth Chisamore, Technical Evangelist  
T: (404) 348-0505 E: [schisamo@opscode.com](mailto:schisamo@opscode.com)  
Twitter, IRC, Github: schisamo

On Tuesday, January 4, 2011 at 12:46 PM, John E. Vincent (lusis) wrote:

> On Tue, Jan 4, 2011 at 12:36 PM, Meppiel, Josh  
> [josh\_meppiel@mastercard.com](mailto:josh_meppiel@mastercard.com) wrote:
> 
> > Are there instructions for the installation of Chef on a RHEL 5.4/5.5 box  
> > without access to the internet? All instructions I see on the OpsCode  
> > website, including those for installation from source, dictate that the host  
> > has direct access to the internet. I would be fine with installation from  
> > source, tarball explode, or RPM’s.
> > 
> > -Josh
> 
> I've been in your shoes, not just with Chef.
> 
> You have a couple of options
> 
> - Package the gems into RPMS yourself and install them (along with  
> config files that way)
> - Create a local gem server to host the gems and point all of your nodes there
> 
> If you're planning on using 'knife bootstrap', take a look at the  
> bootstrap templates. That's where you're going to get the most  
> flexibility and you'll understand exactly what happens when a node is  
> bootstrapped. Here's an example:
> 
> [A sample centos5 chef bootstrap template from Ruby gems · GitHub](https://gist.github.com/765086)
> 
> You can see all of the templates available in  
> 'lib/chef/knife/bootstrap' where your chef gems were installed  
> locally. You'll probably need to create a custom one, copy it to the  
> .chef directory of your local chef repo and then bootstrap a new node  
> like so:
> 
> knife bootstrap FQDN -N nickname -i -x root -d -r "role[base]"
> 
> So esssentially, you would want to modify the steps in the first part  
> of the gist to pull everything from a local repository.
> 
> If you want to run your own gem server, see here:
> 
> [http://docs.rubygems.org/read/chapter/18](http://docs.rubygems.org/read/chapter/18)
> 
> John

---

<div class="post-metadata">

**Author:** ![Sean\_OMeara](https://sea2.discourse-cdn.com/flex016/user_avatar/discourse.chef.io/sean_omeara/32/435_2.png) [@Sean\_OMeara](https://discourse.chef.io/u/Sean_OMeara)\
**Post date:** [January 4, 2011, 6:03pm UTC](https://discourse.chef.io/t/installation-instructions-for-offline-install-on-rhel/1686/5 "2011-01-04T18:03:13Z")

</div>

The "official" way is here:  
[http://wiki.opscode.com/display/chef/Installation+on+RHEL+and+CentOS+5+with+RPMs](http://wiki.opscode.com/display/chef/Installation+on+RHEL+and+CentOS+5+with+RPMs)

For offline installation, you'd want to make all the recursive  
packages available in a local yum repo.

You can also dig around in here for some goodies:

[http://yum.afistfulofservers.net/affs/centos/5/x86\_64/](http://yum.afistfulofservers.net/affs/centos/5/x86_64/)

My last attempts at 0.9.12 ended up broken for reasons I can't be  
bothered to investigate.  
I gave up on 5.x, and and decided to use fedora in anticipation of RHEL6.

Bundlerized Fedora stuff is here:

[http://yum.afistfulofservers.net/affs-chef/fedora/12/x86\_64/](http://yum.afistfulofservers.net/affs-chef/fedora/12/x86_64/)  
[http://yum.afistfulofservers.net/affs-chef/fedora/13/x86\_64/](http://yum.afistfulofservers.net/affs-chef/fedora/13/x86_64/)

I'll be updating for RHEL6 once Centos6 makes it out the door.

-s

On Tue, Jan 4, 2011 at 12:56 PM, SethChisamore [schisamo@opscode.com](mailto:schisamo@opscode.com) wrote:

> Also be aware of RHEL/CentOS sudoers (env\_reset) PATH issues:  
> [http://wiki.opscode.com/display/chef/User+Environment+PATH+Sanity](http://wiki.opscode.com/display/chef/User+Environment+PATH+Sanity)  
> The Chef Providers and Ohai plugins relies on the PATH being set correctly  
> as they do not hardcode paths when running system commands. We do this  
> because we don't want to make assumptions about where programs might live  
> for every single platform.
> 
> ## -Seth
> 
> Opscode, Inc.  
> Seth Chisamore, Technical Evangelist  
> T: (404) 348-0505 E: [schisamo@opscode.com](mailto:schisamo@opscode.com)  
> Twitter, IRC, Github: schisamo
> 
> On Tuesday, January 4, 2011 at 12:46 PM, John E. Vincent (lusis) wrote:
> 
> On Tue, Jan 4, 2011 at 12:36 PM, Meppiel, Josh  
> [josh\_meppiel@mastercard.com](mailto:josh_meppiel@mastercard.com) wrote:
> 
> Are there instructions for the installation of Chef on a RHEL 5.4/5.5 box  
> without access to the internet? All instructions I see on the OpsCode  
> website, including those for installation from source, dictate that the host  
> has direct access to the internet. I would be fine with installation from  
> source, tarball explode, or RPM’s.
> 
> -Josh
> 
> I've been in your shoes, not just with Chef.
> 
> You have a couple of options
> 
> - Package the gems into RPMS yourself and install them (along with  
> config files that way)
> - Create a local gem server to host the gems and point all of your nodes  
> there
> 
> If you're planning on using 'knife bootstrap', take a look at the  
> bootstrap templates. That's where you're going to get the most  
> flexibility and you'll understand exactly what happens when a node is  
> bootstrapped. Here's an example:
> 
> [A sample centos5 chef bootstrap template from Ruby gems · GitHub](https://gist.github.com/765086)
> 
> You can see all of the templates available in  
> 'lib/chef/knife/bootstrap' where your chef gems were installed  
> locally. You'll probably need to create a custom one, copy it to the  
> .chef directory of your local chef repo and then bootstrap a new node  
> like so:
> 
> knife bootstrap FQDN -N nickname -i -x root -d -r "role[base]"
> 
> So esssentially, you would want to modify the steps in the first part  
> of the gist to pull everything from a local repository.
> 
> If you want to run your own gem server, see here:
> 
> [http://docs.rubygems.org/read/chapter/18](http://docs.rubygems.org/read/chapter/18)
> 
> John
