- From: Joshua Timberman <
>
- To: "<
>" <
>
- Subject: [chef] Re: PostgreSQL cookbook questions / issues
- Date: Tue, 21 May 2013 06:16:38 +0000
- Accept-language: en-US
Ohai,
On May 16, 2013, at 6:39 PM, Jeffrey Jones
<
>
wrote:
>
1) PostgreSQL 9.2 on CentOS 6.4
>
>
As far as I can tell, using opscode's cookbook it is impossible to install
>
anything other than PostgreSQL 8.4 on CentOS >= 6.0 without having t modify
>
lots of things like package names, service names etc. I have submitted a
>
pull request regarding this:
>
https://github.com/opscode-cookbooks/postgresql/pull/59
Are you using Chef 11+?
One of the things that Chef 11's node attributes fixes from earlier versions
is that you can override attributes that are used in the cookbook's
attributes file. Prior to Chef 11, they weren't loaded in the proper order.
"Computing attributes from attributes"
http://docs.opscode.com/breaking_changes_chef_11.html#role-and-environment-attribute-changes
>
2) postgresql::ruby recipe
>
>
There appears to be a redundant chunk of code in the postgresql::ruby
>
recipe at
>
https://github.com/opscode-cookbooks/postgresql/blob/master/recipes/ruby.rb#L33
>
which was causing me problems. The line in question installs the client
>
packages but in the line right before it it includes the postgresl::client
>
recipe which... installs the client packages. I had various problems with
>
this chunk of code as it appeared to be running before the
>
postgresql::client code which resulted in it trying to install the packages
>
before the pgdg repository had been enabled. Removing the package
>
installation code from this file solved the issue.
This recipe is intentional, and it is really complicated and nuanced.
The purpose of this recipe is to get the 'pg' gem installed into Chef's Ruby
environment. In order to do that, when using Chef from the Omnibus install
packages, we need to do the things in that recipe so all the proper libraries
are available for the compilation of the native extensions in the pg gem.
This must happen during the "compile" phase of the Chef run, which is why the
"client" packages are handled like that. It also predates the pgdg
repository, and may need to be updated to account for that.
Further details are recorded in this ticket:
http://tickets.opscode.com/browse/COOK-1406
Archive powered by MHonArc 2.6.16.