Add missing files
This commit is contained in:
16
site-cookbooks/kosmos_postgresql/recipes/hostsfile.rb
Normal file
16
site-cookbooks/kosmos_postgresql/recipes/hostsfile.rb
Normal file
@@ -0,0 +1,16 @@
|
||||
#
|
||||
# Cookbook:: kosmos_postgresql
|
||||
# Recipe:: hostsfile
|
||||
#
|
||||
|
||||
begin
|
||||
primary_ip = postgresql_primary[:ipaddress]
|
||||
rescue NoMethodError
|
||||
end
|
||||
|
||||
unless primary_ip.nil?
|
||||
hostsfile_entry primary_ip do
|
||||
hostname "pg.kosmos.local"
|
||||
unique true
|
||||
end
|
||||
end
|
||||
Reference in New Issue
Block a user