From 661b7062cdbac2de151cd6fb19cf2193ef372a39 Mon Sep 17 00:00:00 2001 From: Michael Sprauer Date: Fri, 5 Jun 2015 01:31:03 +0200 Subject: [PATCH] make this working --- recipes/default.rb | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/recipes/default.rb b/recipes/default.rb index c6eb52c..cd2afc9 100644 --- a/recipes/default.rb +++ b/recipes/default.rb @@ -176,7 +176,7 @@ postgresql_connection_info = { :host => 'localhost', - :port => node['postgresql']['config']['port'], + :port => node['owncloud']['config']['dbport'], :username => 'postgres', :password => node['postgresql']['password']['postgres'] } @@ -329,7 +329,7 @@ template 'autoconfig.php' do path ::File.join(node['owncloud']['dir'], 'config', 'autoconfig.php') source 'autoconfig.php.erb' - if node['owncloud']['skip_permissions'] == false + unless node['owncloud']['skip_permissions'] owner node[web_server]['user'] group node[web_server]['group'] mode 00640 @@ -370,6 +370,7 @@ [ node['owncloud']['server_name'], node['owncloud']['server_aliases'] ].flatten.each do |domain| cookbook_config['trusted_domains'] << domain unless cookbook_config['trusted_domains'].include?(domain) end + cookbook_config['dbhost'] = "#{cookbook_config['dbhost']}:#{cookbook_config['dbport']}" config.merge(cookbook_config) config.write unless Chef::Config[:solo]