puppet: Use config.ru from puppet package
This commit is contained in:
parent
0334e539b2
commit
427d56e2f0
3 changed files with 1 additions and 56 deletions
|
@ -1,16 +0,0 @@
|
||||||
# a config.ru, for use with every rack-compatible webserver.
|
|
||||||
# SSL needs to be handled outside this, though.
|
|
||||||
|
|
||||||
# if puppet is not in your RUBYLIB:
|
|
||||||
# $:.unshift('/opt/puppet/lib')
|
|
||||||
|
|
||||||
$0 = "master"
|
|
||||||
|
|
||||||
# if you want debugging:
|
|
||||||
#ARGV << "--debug"
|
|
||||||
|
|
||||||
ARGV << "--rack"
|
|
||||||
require 'puppet/application/master'
|
|
||||||
# we're usually running inside a Rack::Builder.new {} block,
|
|
||||||
# therefore we need to call run *here*.
|
|
||||||
run Puppet::Application[:master].run
|
|
|
@ -1,36 +0,0 @@
|
||||||
# a config.ru, for use with every rack-compatible webserver.
|
|
||||||
# SSL needs to be handled outside this, though.
|
|
||||||
|
|
||||||
# if puppet is not in your RUBYLIB:
|
|
||||||
# $LOAD_PATH.unshift('/opt/puppet/lib')
|
|
||||||
|
|
||||||
$0 = "master"
|
|
||||||
|
|
||||||
# if you want debugging:
|
|
||||||
# ARGV << "--debug"
|
|
||||||
|
|
||||||
ARGV << "--rack"
|
|
||||||
|
|
||||||
# Rack applications typically don't start as root. Set --confdir and --vardir
|
|
||||||
# to prevent reading configuration from ~puppet/.puppet/puppet.conf and writing
|
|
||||||
# to ~puppet/.puppet
|
|
||||||
ARGV << "--confdir" << "/etc/puppet"
|
|
||||||
ARGV << "--vardir" << "/var/lib/puppet"
|
|
||||||
|
|
||||||
# NOTE: it's unfortunate that we have to use the "CommandLine" class
|
|
||||||
# here to launch the app, but it contains some initialization logic
|
|
||||||
# (such as triggering the parsing of the config file) that is very
|
|
||||||
# important. We should do something less nasty here when we've
|
|
||||||
# gotten our API and settings initialization logic cleaned up.
|
|
||||||
#
|
|
||||||
# Also note that the "$0 = master" line up near the top here is
|
|
||||||
# the magic that allows the CommandLine class to know that it's
|
|
||||||
# supposed to be running master.
|
|
||||||
#
|
|
||||||
# --cprice 2012-05-22
|
|
||||||
|
|
||||||
require 'puppet/util/command_line'
|
|
||||||
# we're usually running inside a Rack::Builder.new {} block,
|
|
||||||
# therefore we need to call run *here*.
|
|
||||||
run Puppet::Util::CommandLine.new.execute
|
|
||||||
|
|
|
@ -626,10 +626,7 @@ class puppet::server::passenger {
|
||||||
mode => "0444",
|
mode => "0444",
|
||||||
owner => "puppet",
|
owner => "puppet",
|
||||||
group => "puppet",
|
group => "puppet",
|
||||||
source => $::puppetversion ? {
|
source => "/usr/share/puppet/ext/rack/files/config.ru",
|
||||||
/^3\./ => "puppet:///modules/puppet/puppet3-config.ru",
|
|
||||||
default => "puppet:///modules/puppet/puppet2-config.ru",
|
|
||||||
},
|
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Reference in a new issue