Skip to content

Commit

Permalink
Provide pitti ppa apt repo for latest packages
Browse files Browse the repository at this point in the history
  • Loading branch information
chrisroberts authored and jtimberman committed Dec 10, 2012
1 parent 1dfc3bf commit 3f0213c
Show file tree
Hide file tree
Showing 4 changed files with 17 additions and 0 deletions.
2 changes: 2 additions & 0 deletions attributes/default.rb
Expand Up @@ -170,3 +170,5 @@
{:type => 'host', :db => 'all', :user => 'all', :addr => '127.0.0.1/32', :method => 'md5'},
{:type => 'host', :db => 'all', :user => 'all', :addr => '::1/128', :method => 'md5'}
]

default['postgresql']['server']['latest_packages'] = false
1 change: 1 addition & 0 deletions metadata.rb
Expand Up @@ -21,3 +21,4 @@
end

depends "openssl"
depends "sysctl"
10 changes: 10 additions & 0 deletions recipes/debian_latest_repo.rb
@@ -0,0 +1,10 @@
include_recipe 'apt'

apt_repository 'postgresql latest' do
uri 'http://ppa.launchpad.net/pitti/postgresql/ubuntu'
distribution node[:lsb][:codename]
components %w(main)
keyserver 'keyserver.ubuntu.com'
key '8683D8A2'
action :add
end
4 changes: 4 additions & 0 deletions recipes/server_debian.rb
Expand Up @@ -21,6 +21,10 @@

include_recipe "postgresql::client"

if(node['postgresql']['server']['latest_packages'])
include_recipe 'postgresql::debian_latest_repo'
end

node['postgresql']['server']['packages'].each do |pg_pack|

package pg_pack
Expand Down

0 comments on commit 3f0213c

Please sign in to comment.