Sha256: 2875c6e7c5ac688f8ef9be4013f4e78665734ec6dc49305efef32e1811762c88

Contents?: true

Size: 1.1 KB

Versions: 2

Compression:

Stored size: 1.1 KB

Contents

#
# Cookbook Name:: postgresql
# Recipe:: ruby
#
# Author:: Joshua Timberman (<joshua@opscode.com>)
# Copyright 2012 Opscode, Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
#     http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
#

begin
  require 'pg'
rescue LoadError
  execute "apt-get update" do
    ignore_failure true
    action :nothing
  end.run_action(:run) if node['platform_family'] == "debian"

  node.set['build_essential']['compiletime'] = true
  include_recipe "build-essential"
  include_recipe "postgresql::client"

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

    resources("package[#{pg_pack}]").run_action(:install)

  end

  chef_gem "pg"
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
server_maint-0.0.5 lib/cookbooks/postgresql/recipes/ruby.rb
server_maint-0.0.4 lib/cookbooks/postgresql/recipes/ruby.rb