Sha256: 4dbc363a05aae80ad13634ad32ce2187da16c8c7996f9178b5e12f3f95d684c2

Contents?: true

Size: 676 Bytes

Versions: 15

Compression:

Stored size: 676 Bytes

Contents

require 'daddy/itamae'

directory '/etc/nginx/conf.d/servers' do
  user 'root'
  owner 'root'
  group 'root'
  mode '755'
end

template "/etc/nginx/conf.d/servers/#{ENV['SERVER_NAME']}.conf" do
  source 'templates/passenger.conf.erb'
  user 'root'
  owner 'root'
  group 'root'
  mode '644'
  variables :app_name => ENV['APP_NAME'],
      :server_name => ENV['SERVER_NAME'],
      :rails_env => ENV['RAILS_ENV'],
      :rails_root => ENV['RAILS_ROOT'],
      :behind_load_balancer => false
end

if ENV['RAILS_ROOT'].start_with?("/home/#{ENV['USER']}/")
  directory "/home/#{ENV['USER']}" do
    user 'root'
    owner ENV['USER']
    group ENV['USER']
    mode '755'
  end
end

Version data entries

15 entries across 15 versions & 1 rubygems

Version Path
daddy-0.6.0 itamae/cookbooks/nginx/config.rb
daddy-0.5.34 itamae/cookbooks/nginx/config.rb
daddy-0.5.33 itamae/cookbooks/nginx/config.rb
daddy-0.5.32 itamae/cookbooks/nginx/config.rb
daddy-0.5.31 itamae/cookbooks/nginx/config.rb
daddy-0.5.30 itamae/cookbooks/nginx/config.rb
daddy-0.5.29 itamae/cookbooks/nginx/config.rb
daddy-0.5.28 itamae/cookbooks/nginx/config.rb
daddy-0.5.27 itamae/cookbooks/nginx/config.rb
daddy-0.5.26 itamae/cookbooks/nginx/config.rb
daddy-0.5.25 itamae/cookbooks/nginx/config.rb
daddy-0.5.24 itamae/cookbooks/nginx/config.rb
daddy-0.5.23 itamae/cookbooks/nginx/config.rb
daddy-0.5.22 itamae/cookbooks/nginx/config.rb
daddy-0.5.21 itamae/cookbooks/nginx/config.rb