[chef] Re: Trying to leave some Ruby inside a finished installed Chef template.


Chronological Thread 
  • From: Daniel Condomitti < >
  • To:
  • Subject: [chef] Re: Trying to leave some Ruby inside a finished installed Chef template.
  • Date: Wed, 9 Jan 2013 13:42:40 -0800

If the entire thing is plain text use cookbook_file instead of template.

On Wednesday, January 9, 2013 at 1:40 PM, Darron Froese wrote:

Have a rails database.yml installed via chef:

production:
adapter: mysql2
encoding: utf8
reconnect: false
database: gitlabhq_production
pool: 5
username: <%= ENV['PROD_DB_USER'] %>
password: <%= ENV['PROD_DB_PASSWORD'] %>

I want to to look like this when it's installed - but Chef is
rendering the ENV vars during the install.

I'd rather not have that done - just like to use the ENV variables the
whole time.

I'd really like chef to just install this - treat is as a text file
and just install. Is that possible?

Any tips? I've looked through the Chef and Erubis docs as well as done
lots of Googling.





Archive powered by MHonArc 2.6.16.

§