passenger 4.0.0.rc4 → 4.0.0.rc6
Sign up to get free protection for your applications and to get access to all the features.
Potentially problematic release.
This version of passenger might be problematic. Click here for more details.
- data.tar.gz.asc +12 -0
- data/.travis.yml +4 -4
- data/NEWS +46 -0
- data/bin/passenger-config +31 -1
- data/bin/passenger-install-apache2-module +1 -1
- data/bin/passenger-install-nginx-module +1 -0
- data/build/common_library.rb +4 -0
- data/build/cplusplus_support.rb +27 -6
- data/build/cxx_tests.rb +1 -1
- data/build/misc.rb +28 -6
- data/build/packaging.rb +72 -65
- data/build/test_basics.rb +1 -1
- data/dev/googlecode_upload.py +265 -0
- data/dev/run_travis.sh +9 -0
- data/doc/Users guide Apache.html +376 -193
- data/doc/Users guide Apache.idmap.txt +80 -62
- data/doc/Users guide Apache.txt +61 -35
- data/doc/Users guide Nginx.html +278 -83
- data/doc/Users guide Nginx.idmap.txt +26 -10
- data/doc/Users guide Nginx.txt +59 -31
- data/doc/Users guide Standalone.html +1 -1
- data/doc/users_guide_snippets/installation.txt +121 -11
- data/doc/users_guide_snippets/rvm_helper_tool.txt +56 -0
- data/ext/apache2/Bucket.cpp +1 -1
- data/ext/apache2/Configuration.cpp +7 -1
- data/ext/apache2/Configuration.hpp +4 -0
- data/ext/apache2/Hooks.cpp +2 -2
- data/ext/common/AgentsStarter.cpp +2 -2
- data/ext/common/AgentsStarter.h +1 -1
- data/ext/common/AgentsStarter.hpp +2 -2
- data/ext/common/ApplicationPool2/DirectSpawner.h +4 -8
- data/ext/common/ApplicationPool2/Group.h +17 -11
- data/ext/common/ApplicationPool2/Implementation.cpp +39 -11
- data/ext/common/ApplicationPool2/Pool.h +23 -4
- data/ext/common/ApplicationPool2/Process.h +30 -11
- data/ext/common/ApplicationPool2/SmartSpawner.h +3 -1
- data/ext/common/Constants.h +1 -1
- data/ext/common/EventedBufferedInput.h +4 -0
- data/ext/common/Utils.cpp +21 -3
- data/ext/common/Utils.h +8 -1
- data/ext/common/Utils/HttpHeaderBufferer.h +1 -1
- data/ext/common/Utils/IOUtils.cpp +5 -4
- data/ext/common/Utils/IOUtils.h +32 -14
- data/ext/common/Utils/MessagePassing.h +2 -2
- data/ext/common/Utils/ProcessMetricsCollector.h +47 -15
- data/ext/common/Utils/ScopeGuard.h +20 -3
- data/ext/common/Utils/StrIntUtils.h +14 -5
- data/ext/common/agents/Base.cpp +161 -50
- data/ext/common/agents/HelperAgent/AgentOptions.h +2 -2
- data/ext/common/agents/HelperAgent/Main.cpp +1 -0
- data/ext/common/agents/HelperAgent/RequestHandler.h +166 -52
- data/ext/common/agents/LoggingAgent/Main.cpp +1 -1
- data/ext/common/agents/Watchdog/Main.cpp +2 -2
- data/ext/nginx/Configuration.c +31 -4
- data/ext/nginx/Configuration.h +1 -0
- data/ext/nginx/ContentHandler.c +148 -34
- data/ext/nginx/ngx_http_passenger_module.c +4 -1
- data/ext/oxt/detail/spin_lock_pthreads.hpp +4 -4
- data/ext/oxt/macros.hpp +30 -8
- data/lib/phusion_passenger.rb +2 -2
- data/lib/phusion_passenger/classic_rails/thread_handler_extension.rb +1 -1
- data/lib/phusion_passenger/native_support.rb +19 -1
- data/lib/phusion_passenger/platform_info/compiler.rb +6 -0
- data/lib/phusion_passenger/platform_info/ruby.rb +54 -5
- data/lib/phusion_passenger/preloader_shared_helpers.rb +8 -1
- data/lib/phusion_passenger/rack/out_of_band_gc.rb +3 -1
- data/lib/phusion_passenger/rack/thread_handler_extension.rb +32 -5
- data/lib/phusion_passenger/request_handler/thread_handler.rb +28 -8
- data/lib/phusion_passenger/ruby_core_enhancements.rb +9 -1
- data/lib/phusion_passenger/standalone/runtime_installer.rb +1 -0
- data/lib/phusion_passenger/utils/unseekable_socket.rb +50 -5
- data/passenger.gemspec +1 -1
- data/resources/templates/apache2/config_snippets.txt.erb +1 -1
- data/test/cxx/ApplicationPool2/PoolTest.cpp +4 -9
- data/test/cxx/RequestHandlerTest.cpp +5 -5
- data/test/ruby/classic_rails/loader_spec.rb +1 -1
- data/test/ruby/classic_rails/preloader_spec.rb +1 -1
- data/test/ruby/request_handler_spec.rb +207 -1
- data/test/ruby/shared/loader_sharedspec.rb +1 -0
- data/test/ruby/spec_helper.rb +11 -1
- data/test/stub/apache2/httpd.conf.erb +1 -1
- metadata +5 -3
- metadata.gz.asc +12 -0
data/build/test_basics.rb
CHANGED
@@ -48,7 +48,7 @@ task 'test:install_deps' do
|
|
48
48
|
gem_install = PlatformInfo.gem_command + " install --no-rdoc --no-ri"
|
49
49
|
gem_install = "#{PlatformInfo.ruby_sudo_command} #{gem_install}" if boolean_option('SUDO')
|
50
50
|
sh "#{gem_install} rails -v 2.3.15"
|
51
|
-
sh "#{gem_install} bundler rspec mime-types daemon_controller json"
|
51
|
+
sh "#{gem_install} bundler rspec mime-types daemon_controller json rack"
|
52
52
|
if boolean_option('RAILS_BUNDLES', true)
|
53
53
|
sh "cd test/stub/rails3.0 && bundle install"
|
54
54
|
sh "cd test/stub/rails3.1 && bundle install"
|
@@ -0,0 +1,265 @@
|
|
1
|
+
#!/usr/bin/env python
|
2
|
+
#
|
3
|
+
# Copyright 2006, 2007 Google Inc. All Rights Reserved.
|
4
|
+
# Author: danderson@google.com (David Anderson)
|
5
|
+
#
|
6
|
+
# Script for uploading files to a Google Code project.
|
7
|
+
#
|
8
|
+
# This is intended to be both a useful script for people who want to
|
9
|
+
# streamline project uploads and a reference implementation for
|
10
|
+
# uploading files to Google Code projects.
|
11
|
+
#
|
12
|
+
# To upload a file to Google Code, you need to provide a path to the
|
13
|
+
# file on your local machine, a small summary of what the file is, a
|
14
|
+
# project name, and a valid account that is a member or owner of that
|
15
|
+
# project. You can optionally provide a list of labels that apply to
|
16
|
+
# the file. The file will be uploaded under the same name that it has
|
17
|
+
# in your local filesystem (that is, the "basename" or last path
|
18
|
+
# component). Run the script with '--help' to get the exact syntax
|
19
|
+
# and available options.
|
20
|
+
#
|
21
|
+
# Note that the upload script requests that you enter your
|
22
|
+
# googlecode.com password. This is NOT your Gmail account password!
|
23
|
+
# This is the password you use on googlecode.com for committing to
|
24
|
+
# Subversion and uploading files. You can find your password by going
|
25
|
+
# to http://code.google.com/hosting/settings when logged in with your
|
26
|
+
# Gmail account. If you have already committed to your project's
|
27
|
+
# Subversion repository, the script will automatically retrieve your
|
28
|
+
# credentials from there (unless disabled, see the output of '--help'
|
29
|
+
# for details).
|
30
|
+
#
|
31
|
+
# If you are looking at this script as a reference for implementing
|
32
|
+
# your own Google Code file uploader, then you should take a look at
|
33
|
+
# the upload() function, which is the meat of the uploader. You
|
34
|
+
# basically need to build a multipart/form-data POST request with the
|
35
|
+
# right fields and send it to https://PROJECT.googlecode.com/files .
|
36
|
+
# Authenticate the request using HTTP Basic authentication, as is
|
37
|
+
# shown below.
|
38
|
+
#
|
39
|
+
# Licensed under the terms of the Apache Software License 2.0:
|
40
|
+
# http://www.apache.org/licenses/LICENSE-2.0
|
41
|
+
#
|
42
|
+
# Questions, comments, feature requests and patches are most welcome.
|
43
|
+
# Please direct all of these to the Google Code users group:
|
44
|
+
# http://groups.google.com/group/google-code-hosting
|
45
|
+
|
46
|
+
"""Google Code file uploader script.
|
47
|
+
"""
|
48
|
+
|
49
|
+
__author__ = 'danderson@google.com (David Anderson)'
|
50
|
+
|
51
|
+
import httplib
|
52
|
+
import os.path
|
53
|
+
import optparse
|
54
|
+
import getpass
|
55
|
+
import base64
|
56
|
+
import sys
|
57
|
+
|
58
|
+
|
59
|
+
def upload(file, project_name, user_name, password, summary, labels=None):
|
60
|
+
"""Upload a file to a Google Code project's file server.
|
61
|
+
|
62
|
+
Args:
|
63
|
+
file: The local path to the file.
|
64
|
+
project_name: The name of your project on Google Code.
|
65
|
+
user_name: Your Google account name.
|
66
|
+
password: The googlecode.com password for your account.
|
67
|
+
Note that this is NOT your global Google Account password!
|
68
|
+
summary: A small description for the file.
|
69
|
+
labels: an optional list of label strings with which to tag the file.
|
70
|
+
|
71
|
+
Returns: a tuple:
|
72
|
+
http_status: 201 if the upload succeeded, something else if an
|
73
|
+
error occured.
|
74
|
+
http_reason: The human-readable string associated with http_status
|
75
|
+
file_url: If the upload succeeded, the URL of the file on Google
|
76
|
+
Code, None otherwise.
|
77
|
+
"""
|
78
|
+
# The login is the user part of user@gmail.com. If the login provided
|
79
|
+
# is in the full user@domain form, strip it down.
|
80
|
+
if user_name.endswith('@gmail.com'):
|
81
|
+
user_name = user_name[:user_name.index('@gmail.com')]
|
82
|
+
|
83
|
+
form_fields = [('summary', summary)]
|
84
|
+
if labels is not None:
|
85
|
+
form_fields.extend([('label', l.strip()) for l in labels])
|
86
|
+
|
87
|
+
content_type, body = encode_upload_request(form_fields, file)
|
88
|
+
|
89
|
+
upload_host = '%s.googlecode.com' % project_name
|
90
|
+
upload_uri = '/files'
|
91
|
+
auth_token = base64.b64encode('%s:%s'% (user_name, password))
|
92
|
+
headers = {
|
93
|
+
'Authorization': 'Basic %s' % auth_token,
|
94
|
+
'User-Agent': 'Googlecode.com uploader v0.9.4',
|
95
|
+
'Content-Type': content_type,
|
96
|
+
}
|
97
|
+
|
98
|
+
server = httplib.HTTPSConnection(upload_host)
|
99
|
+
server.request('POST', upload_uri, body, headers)
|
100
|
+
resp = server.getresponse()
|
101
|
+
server.close()
|
102
|
+
|
103
|
+
if resp.status == 201:
|
104
|
+
location = resp.getheader('Location', None)
|
105
|
+
else:
|
106
|
+
location = None
|
107
|
+
return resp.status, resp.reason, location
|
108
|
+
|
109
|
+
|
110
|
+
def encode_upload_request(fields, file_path):
|
111
|
+
"""Encode the given fields and file into a multipart form body.
|
112
|
+
|
113
|
+
fields is a sequence of (name, value) pairs. file is the path of
|
114
|
+
the file to upload. The file will be uploaded to Google Code with
|
115
|
+
the same file name.
|
116
|
+
|
117
|
+
Returns: (content_type, body) ready for httplib.HTTP instance
|
118
|
+
"""
|
119
|
+
BOUNDARY = '----------Googlecode_boundary_reindeer_flotilla'
|
120
|
+
CRLF = '\r\n'
|
121
|
+
|
122
|
+
body = []
|
123
|
+
|
124
|
+
# Add the metadata about the upload first
|
125
|
+
for key, value in fields:
|
126
|
+
body.extend(
|
127
|
+
['--' + BOUNDARY,
|
128
|
+
'Content-Disposition: form-data; name="%s"' % key,
|
129
|
+
'',
|
130
|
+
value,
|
131
|
+
])
|
132
|
+
|
133
|
+
# Now add the file itself
|
134
|
+
file_name = os.path.basename(file_path)
|
135
|
+
f = open(file_path, 'rb')
|
136
|
+
file_content = f.read()
|
137
|
+
f.close()
|
138
|
+
|
139
|
+
body.extend(
|
140
|
+
['--' + BOUNDARY,
|
141
|
+
'Content-Disposition: form-data; name="filename"; filename="%s"'
|
142
|
+
% file_name,
|
143
|
+
# The upload server determines the mime-type, no need to set it.
|
144
|
+
'Content-Type: application/octet-stream',
|
145
|
+
'',
|
146
|
+
file_content,
|
147
|
+
])
|
148
|
+
|
149
|
+
# Finalize the form body
|
150
|
+
body.extend(['--' + BOUNDARY + '--', ''])
|
151
|
+
|
152
|
+
return 'multipart/form-data; boundary=%s' % BOUNDARY, CRLF.join(body)
|
153
|
+
|
154
|
+
|
155
|
+
def upload_find_auth(file_path, project_name, summary, labels=None,
|
156
|
+
user_name=None, password=None, tries=3):
|
157
|
+
"""Find credentials and upload a file to a Google Code project's file server.
|
158
|
+
|
159
|
+
file_path, project_name, summary, and labels are passed as-is to upload.
|
160
|
+
|
161
|
+
Args:
|
162
|
+
file_path: The local path to the file.
|
163
|
+
project_name: The name of your project on Google Code.
|
164
|
+
summary: A small description for the file.
|
165
|
+
labels: an optional list of label strings with which to tag the file.
|
166
|
+
config_dir: Path to Subversion configuration directory, 'none', or None.
|
167
|
+
user_name: Your Google account name.
|
168
|
+
tries: How many attempts to make.
|
169
|
+
"""
|
170
|
+
if user_name is None or password is None:
|
171
|
+
from netrc import netrc
|
172
|
+
try:
|
173
|
+
authenticators = netrc().authenticators("code.google.com")
|
174
|
+
except IOError as e:
|
175
|
+
sys.stderr.write(str(e) + "\n\n")
|
176
|
+
sys.stderr.write("It seems that you don't have ~/.netrc. You must " +
|
177
|
+
"configure this file so that this script can authenticate with " +
|
178
|
+
"Google Code. This file must contain your Google Code password " +
|
179
|
+
"(which is NOT your Google account password)! Please visit " +
|
180
|
+
"http://code.google.com/hosting/settings for instructions.\n")
|
181
|
+
sys.exit(1)
|
182
|
+
if authenticators:
|
183
|
+
if user_name is None:
|
184
|
+
user_name = authenticators[0]
|
185
|
+
if password is None:
|
186
|
+
password = authenticators[2]
|
187
|
+
|
188
|
+
while tries > 0:
|
189
|
+
if user_name is None:
|
190
|
+
# Read username if not specified or loaded from svn config, or on
|
191
|
+
# subsequent tries.
|
192
|
+
sys.stdout.write('Please enter your googlecode.com username: ')
|
193
|
+
sys.stdout.flush()
|
194
|
+
user_name = sys.stdin.readline().rstrip()
|
195
|
+
if password is None:
|
196
|
+
# Read password if not loaded from svn config, or on subsequent tries.
|
197
|
+
print 'Please enter your googlecode.com password.'
|
198
|
+
print '** Note that this is NOT your Gmail account password! **'
|
199
|
+
print 'It is the password you use to access Subversion repositories,'
|
200
|
+
print 'and can be found here: http://code.google.com/hosting/settings'
|
201
|
+
password = getpass.getpass()
|
202
|
+
|
203
|
+
status, reason, url = upload(file_path, project_name, user_name, password,
|
204
|
+
summary, labels)
|
205
|
+
# Returns 403 Forbidden instead of 401 Unauthorized for bad
|
206
|
+
# credentials as of 2007-07-17.
|
207
|
+
if status in [httplib.FORBIDDEN, httplib.UNAUTHORIZED]:
|
208
|
+
# Rest for another try.
|
209
|
+
user_name = password = None
|
210
|
+
tries = tries - 1
|
211
|
+
else:
|
212
|
+
# We're done.
|
213
|
+
break
|
214
|
+
|
215
|
+
return status, reason, url
|
216
|
+
|
217
|
+
|
218
|
+
def main():
|
219
|
+
parser = optparse.OptionParser(usage='googlecode-upload.py -s SUMMARY '
|
220
|
+
'-p PROJECT [options] FILE')
|
221
|
+
parser.add_option('-s', '--summary', dest='summary',
|
222
|
+
help='Short description of the file')
|
223
|
+
parser.add_option('-p', '--project', dest='project',
|
224
|
+
help='Google Code project name')
|
225
|
+
parser.add_option('-u', '--user', dest='user',
|
226
|
+
help='Your Google Code username')
|
227
|
+
parser.add_option('-w', '--password', dest='password',
|
228
|
+
help='Your Google Code password')
|
229
|
+
parser.add_option('-l', '--labels', dest='labels',
|
230
|
+
help='An optional list of comma-separated labels to attach '
|
231
|
+
'to the file')
|
232
|
+
|
233
|
+
options, args = parser.parse_args()
|
234
|
+
|
235
|
+
if not options.summary:
|
236
|
+
parser.error('File summary is missing.')
|
237
|
+
elif not options.project:
|
238
|
+
parser.error('Project name is missing.')
|
239
|
+
elif len(args) < 1:
|
240
|
+
parser.error('File to upload not provided.')
|
241
|
+
elif len(args) > 1:
|
242
|
+
parser.error('Only one file may be specified.')
|
243
|
+
|
244
|
+
file_path = args[0]
|
245
|
+
|
246
|
+
if options.labels:
|
247
|
+
labels = options.labels.split(',')
|
248
|
+
else:
|
249
|
+
labels = None
|
250
|
+
|
251
|
+
status, reason, url = upload_find_auth(file_path, options.project,
|
252
|
+
options.summary, labels,
|
253
|
+
options.user, options.password)
|
254
|
+
if url:
|
255
|
+
print 'The file was uploaded successfully.'
|
256
|
+
print 'URL: %s' % url
|
257
|
+
return 0
|
258
|
+
else:
|
259
|
+
print 'An error occurred. Your file was not uploaded.'
|
260
|
+
print 'Google Code upload server said: %s (%s)' % (reason, status)
|
261
|
+
return 1
|
262
|
+
|
263
|
+
|
264
|
+
if __name__ == '__main__':
|
265
|
+
sys.exit(main())
|
data/dev/run_travis.sh
CHANGED
@@ -18,6 +18,15 @@ if [[ "$TEST_RUBY_VERSION" != "" ]]; then
|
|
18
18
|
echo "$ rvm use $TEST_RUBY_VERSION"
|
19
19
|
source ~/.rvm/scripts/rvm
|
20
20
|
rvm use $TEST_RUBY_VERSION
|
21
|
+
if [[ "$TEST_RUBYGEMS_VERSION" = "" ]]; then
|
22
|
+
echo "$ gem --version"
|
23
|
+
gem --version
|
24
|
+
fi
|
25
|
+
fi
|
26
|
+
|
27
|
+
if [[ "$TEST_RUBYGEMS_VERSION" != "" ]]; then
|
28
|
+
echo "$ rvm install rubygems $TEST_RUBYGEMS_VERSION"
|
29
|
+
rvm install rubygems $TEST_RUBYGEMS_VERSION
|
21
30
|
echo "$ gem --version"
|
22
31
|
gem --version
|
23
32
|
fi
|
data/doc/Users guide Apache.html
CHANGED
@@ -1111,15 +1111,23 @@ using the command line.</p></div>
|
|
1111
1111
|
<div class="foo toclevel3"><a href="#_installing_or_upgrading_on_debian_6_or_ubuntu">2.4. Installing or upgrading on Debian 6 or Ubuntu</a></div>
|
1112
1112
|
<div class="foo toclevel3"><a href="#_installing_or_upgrading_on_red_hat_fedora_centos_or_scientificlinux">2.5. Installing or upgrading on Red Hat, Fedora, CentOS or ScientificLinux</a></div>
|
1113
1113
|
<div class="foo toclevel3"><a href="#_upgrading_from_open_source_to_enterprise">2.6. Upgrading from open source to Enterprise</a></div>
|
1114
|
-
<div class="foo toclevel3"><a href="#
|
1115
|
-
<div class="foo
|
1116
|
-
<div class="foo toclevel4"><a href="#
|
1117
|
-
<div class="foo toclevel4"><a href="#
|
1118
|
-
<div class="foo toclevel4"><a href="#
|
1119
|
-
<div class="foo
|
1120
|
-
<div class="foo
|
1121
|
-
<div class="foo
|
1122
|
-
<div class="foo toclevel3"><a href="#
|
1114
|
+
<div class="foo toclevel3"><a href="#_cryptographic_verification_of_installation_files">2.7. Cryptographic verification of installation files</a></div>
|
1115
|
+
<div class="foo toclevel4"><a href="#_synopsis_2">2.7.1. Synopsis</a></div>
|
1116
|
+
<div class="foo toclevel4"><a href="#_importing_the_phusion_software_signing_key">2.7.2. Importing the Phusion Software Signing key</a></div>
|
1117
|
+
<div class="foo toclevel4"><a href="#_verifying_the_phusion_software_signing_key">2.7.3. Verifying the Phusion Software Signing key</a></div>
|
1118
|
+
<div class="foo toclevel4"><a href="#_verifying_the_gem_and_tarball">2.7.4. Verifying the gem and tarball</a></div>
|
1119
|
+
<div class="foo toclevel4"><a href="#_verifying_git_signatures">2.7.5. Verifying Git signatures</a></div>
|
1120
|
+
<div class="foo toclevel4"><a href="#_verifying_deb_and_rpm_packages">2.7.6. Verifying DEB and RPM packages</a></div>
|
1121
|
+
<div class="foo toclevel4"><a href="#_revocation">2.7.7. Revocation</a></div>
|
1122
|
+
<div class="foo toclevel3"><a href="#_non_interactive_automatic_headless_installs_or_upgrades">2.8. Non-interactive, automatic, headless installs or upgrades</a></div>
|
1123
|
+
<div class="foo toclevel3"><a href="#_customizing_the_compilation_process">2.9. Customizing the compilation process</a></div>
|
1124
|
+
<div class="foo toclevel4"><a href="#_setting_the_compiler">2.9.1. Setting the compiler</a></div>
|
1125
|
+
<div class="foo toclevel4"><a href="#_adding_additional_compiler_or_linker_flags">2.9.2. Adding additional compiler or linker flags</a></div>
|
1126
|
+
<div class="foo toclevel4"><a href="#_forcing_location_of_certain_command_line_tools">2.9.3. Forcing location of certain command line tools</a></div>
|
1127
|
+
<div class="foo toclevel3"><a href="#working_with_apache_conf">2.10. Working with the Apache configuration file</a></div>
|
1128
|
+
<div class="foo toclevel3"><a href="#_disabling_without_uninstalling">2.11. Disabling without uninstalling</a></div>
|
1129
|
+
<div class="foo toclevel3"><a href="#uninstalling">2.12. Uninstalling</a></div>
|
1130
|
+
<div class="foo toclevel3"><a href="#moving_phusion_passenger">2.13. Moving to a different directory</a></div>
|
1123
1131
|
<div class="foo toclevel2"><a href="#_deploying_a_ruby_on_rails_1_x_or_2_x_but_not_rails_gt_3_x_application">3. Deploying a Ruby on Rails 1.x or 2.x (but NOT Rails >= 3.x) application</a></div>
|
1124
1132
|
<div class="foo toclevel3"><a href="#_deploying_to_a_virtual_host_8217_s_root">3.1. Deploying to a virtual host’s root</a></div>
|
1125
1133
|
<div class="foo toclevel3"><a href="#deploying_rails_to_sub_uri">3.2. Deploying to a sub URI</a></div>
|
@@ -1144,59 +1152,60 @@ using the command line.</p></div>
|
|
1144
1152
|
<div class="foo toclevel3"><a href="#_redeploying_restarting_the_wsgi_application">5.3. Redeploying (restarting the WSGI application)</a></div>
|
1145
1153
|
<div class="foo toclevel2"><a href="#_configuring_phusion_passenger">6. Configuring Phusion Passenger</a></div>
|
1146
1154
|
<div class="foo toclevel3"><a href="#_passengerroot_lt_directory_gt">6.1. PassengerRoot <directory></a></div>
|
1147
|
-
<div class="foo toclevel3"><a href="#
|
1148
|
-
<div class="foo toclevel3"><a href="#
|
1149
|
-
<div class="foo toclevel3"><a href="#
|
1150
|
-
<div class="foo toclevel3"><a href="#
|
1151
|
-
<div class="foo toclevel3"><a href="#
|
1152
|
-
<div class="foo toclevel3"><a href="#
|
1153
|
-
<div class="foo toclevel3"><a href="#
|
1154
|
-
<div class="foo toclevel3"><a href="#
|
1155
|
-
<div class="foo toclevel3"><a href="#
|
1156
|
-
<div class="foo toclevel3"><a href="#
|
1157
|
-
<div class="foo toclevel3"><a href="#
|
1158
|
-
<div class="foo toclevel3"><a href="#
|
1159
|
-
<div class="foo
|
1160
|
-
<div class="foo toclevel4"><a href="#
|
1161
|
-
<div class="foo toclevel4"><a href="#
|
1162
|
-
<div class="foo toclevel4"><a href="#
|
1163
|
-
<div class="foo toclevel4"><a href="#
|
1164
|
-
<div class="foo toclevel4"><a href="#
|
1165
|
-
<div class="foo
|
1166
|
-
<div class="foo
|
1167
|
-
<div class="foo toclevel4"><a href="#
|
1168
|
-
<div class="foo toclevel4"><a href="#
|
1169
|
-
<div class="foo toclevel4"><a href="#
|
1170
|
-
<div class="foo toclevel4"><a href="#
|
1171
|
-
<div class="foo toclevel4"><a href="#
|
1172
|
-
<div class="foo toclevel4"><a href="#
|
1173
|
-
<div class="foo toclevel4"><a href="#
|
1174
|
-
<div class="foo toclevel4"><a href="#
|
1175
|
-
<div class="foo toclevel4"><a href="#
|
1176
|
-
<div class="foo toclevel4"><a href="#
|
1177
|
-
<div class="foo toclevel4"><a href="#
|
1178
|
-
<div class="foo toclevel4"><a href="#
|
1179
|
-
<div class="foo toclevel4"><a href="#
|
1180
|
-
<div class="foo
|
1181
|
-
<div class="foo
|
1182
|
-
<div class="foo toclevel4"><a href="#
|
1183
|
-
<div class="foo
|
1184
|
-
<div class="foo
|
1185
|
-
<div class="foo toclevel4"><a href="#
|
1186
|
-
<div class="foo toclevel4"><a href="#
|
1187
|
-
<div class="foo
|
1188
|
-
<div class="foo
|
1189
|
-
<div class="foo toclevel4"><a href="#
|
1190
|
-
<div class="foo
|
1191
|
-
<div class="foo
|
1192
|
-
<div class="foo toclevel4"><a href="#
|
1193
|
-
<div class="foo
|
1194
|
-
<div class="foo
|
1195
|
-
<div class="foo toclevel4"><a href="#
|
1196
|
-
<div class="foo toclevel4"><a href="#
|
1197
|
-
<div class="foo toclevel4"><a href="#
|
1198
|
-
<div class="foo toclevel4"><a href="#
|
1199
|
-
<div class="foo toclevel4"><a href="#
|
1155
|
+
<div class="foo toclevel3"><a href="#PassengerDefaultRuby">6.2. PassengerDefaultRuby and PassengerRuby</a></div>
|
1156
|
+
<div class="foo toclevel3"><a href="#PassengerRuby">6.3. PassengerRuby <filename></a></div>
|
1157
|
+
<div class="foo toclevel3"><a href="#_passengerpython_lt_filename_gt">6.4. PassengerPython <filename></a></div>
|
1158
|
+
<div class="foo toclevel3"><a href="#PassengerAppRoot">6.5. PassengerAppRoot <path/to/root></a></div>
|
1159
|
+
<div class="foo toclevel3"><a href="#PassengerSpawnMethod">6.6. PassengerSpawnMethod <string></a></div>
|
1160
|
+
<div class="foo toclevel3"><a href="#PassengerEnabled">6.7. PassengerEnabled <on|off></a></div>
|
1161
|
+
<div class="foo toclevel3"><a href="#PassengerTempDir">6.8. PassengerTempDir <directory></a></div>
|
1162
|
+
<div class="foo toclevel3"><a href="#PassengerUploadBufferDir">6.9. PassengerUploadBufferDir <directory></a></div>
|
1163
|
+
<div class="foo toclevel3"><a href="#_passengerrestartdir_lt_directory_gt">6.10. PassengerRestartDir <directory></a></div>
|
1164
|
+
<div class="foo toclevel3"><a href="#PassengerBufferResponse">6.11. PassengerBufferResponse <on|off></a></div>
|
1165
|
+
<div class="foo toclevel3"><a href="#PassengerRollingRestarts">6.12. PassengerRollingRestarts <on|off></a></div>
|
1166
|
+
<div class="foo toclevel3"><a href="#_passengerresistdeploymenterrors_lt_on_off_gt">6.13. PassengerResistDeploymentErrors <on|off></a></div>
|
1167
|
+
<div class="foo toclevel3"><a href="#_security_options">6.14. Security options</a></div>
|
1168
|
+
<div class="foo toclevel4"><a href="#PassengerUserSwitching">6.14.1. PassengerUserSwitching <on|off></a></div>
|
1169
|
+
<div class="foo toclevel4"><a href="#_passengeruser_lt_username_gt">6.14.2. PassengerUser <username></a></div>
|
1170
|
+
<div class="foo toclevel4"><a href="#_passengergroup_lt_group_name_gt">6.14.3. PassengerGroup <group name></a></div>
|
1171
|
+
<div class="foo toclevel4"><a href="#PassengerDefaultUser">6.14.4. PassengerDefaultUser <username></a></div>
|
1172
|
+
<div class="foo toclevel4"><a href="#PassengerDefaultGroup">6.14.5. PassengerDefaultGroup <group name></a></div>
|
1173
|
+
<div class="foo toclevel4"><a href="#_passengerfriendlyerrorpages_lt_on_off_gt">6.14.6. PassengerFriendlyErrorPages <on|off></a></div>
|
1174
|
+
<div class="foo toclevel3"><a href="#_resource_control_and_optimization_options">6.15. Resource control and optimization options</a></div>
|
1175
|
+
<div class="foo toclevel4"><a href="#_passengermaxpoolsize_lt_integer_gt">6.15.1. PassengerMaxPoolSize <integer></a></div>
|
1176
|
+
<div class="foo toclevel4"><a href="#PassengerMinInstances">6.15.2. PassengerMinInstances <integer></a></div>
|
1177
|
+
<div class="foo toclevel4"><a href="#_passengermaxinstances_lt_integer_gt">6.15.3. PassengerMaxInstances <integer></a></div>
|
1178
|
+
<div class="foo toclevel4"><a href="#_passengermaxinstancesperapp_lt_integer_gt">6.15.4. PassengerMaxInstancesPerApp <integer></a></div>
|
1179
|
+
<div class="foo toclevel4"><a href="#PassengerPoolIdleTime">6.15.5. PassengerPoolIdleTime <integer></a></div>
|
1180
|
+
<div class="foo toclevel4"><a href="#_passengermaxpreloaderidletime_lt_integer_gt">6.15.6. PassengerMaxPreloaderIdleTime <integer></a></div>
|
1181
|
+
<div class="foo toclevel4"><a href="#PassengerConcurrencyModel">6.15.7. PassengerConcurrencyModel <process|thread></a></div>
|
1182
|
+
<div class="foo toclevel4"><a href="#PassengerThreadCount">6.15.8. PassengerThreadCount <number></a></div>
|
1183
|
+
<div class="foo toclevel4"><a href="#PassengerMaxRequests">6.15.9. PassengerMaxRequests <integer></a></div>
|
1184
|
+
<div class="foo toclevel4"><a href="#PassengerMaxRequestTime">6.15.10. PassengerMaxRequestTime <seconds></a></div>
|
1185
|
+
<div class="foo toclevel4"><a href="#PassengerMemoryLimit">6.15.11. PassengerMemoryLimit <integer></a></div>
|
1186
|
+
<div class="foo toclevel4"><a href="#_passengerstatthrottlerate_lt_integer_gt">6.15.12. PassengerStatThrottleRate <integer></a></div>
|
1187
|
+
<div class="foo toclevel4"><a href="#PassengerPreStart">6.15.13. PassengerPreStart <url></a></div>
|
1188
|
+
<div class="foo toclevel4"><a href="#PassengerHighPerformance">6.15.14. PassengerHighPerformance <on|off></a></div>
|
1189
|
+
<div class="foo toclevel3"><a href="#_compatibility_options">6.16. Compatibility options</a></div>
|
1190
|
+
<div class="foo toclevel4"><a href="#PassengerResolveSymlinksInDocumentRoot">6.16.1. PassengerResolveSymlinksInDocumentRoot <on|off></a></div>
|
1191
|
+
<div class="foo toclevel4"><a href="#_passengerallowencodedslashes_lt_on_off_gt">6.16.2. PassengerAllowEncodedSlashes <on|off></a></div>
|
1192
|
+
<div class="foo toclevel3"><a href="#_logging_and_debugging_options">6.17. Logging and debugging options</a></div>
|
1193
|
+
<div class="foo toclevel4"><a href="#_passengerloglevel_lt_integer_gt">6.17.1. PassengerLogLevel <integer></a></div>
|
1194
|
+
<div class="foo toclevel4"><a href="#_passengerdebuglogfile_lt_filename_gt">6.17.2. PassengerDebugLogFile <filename></a></div>
|
1195
|
+
<div class="foo toclevel4"><a href="#_passengerdebugger_lt_on_off_gt">6.17.3. PassengerDebugger <on|off></a></div>
|
1196
|
+
<div class="foo toclevel3"><a href="#_classic_ruby_on_rails_8656_2_x_specific_options">6.18. Classic Ruby on Rails (⇐ 2.x)-specific options</a></div>
|
1197
|
+
<div class="foo toclevel4"><a href="#RailsBaseURI">6.18.1. RailsBaseURI <uri></a></div>
|
1198
|
+
<div class="foo toclevel4"><a href="#rails_env">6.18.2. RailsEnv <string></a></div>
|
1199
|
+
<div class="foo toclevel3"><a href="#_rack_and_rails_gt_3_specific_options">6.19. Rack and Rails >= 3 specific options</a></div>
|
1200
|
+
<div class="foo toclevel4"><a href="#RackBaseURI">6.19.1. RackBaseURI <uri></a></div>
|
1201
|
+
<div class="foo toclevel4"><a href="#rack_env">6.19.2. RackEnv <string></a></div>
|
1202
|
+
<div class="foo toclevel3"><a href="#_deprecated_or_removed_options">6.20. Deprecated or removed options</a></div>
|
1203
|
+
<div class="foo toclevel4"><a href="#_railsruby">6.20.1. RailsRuby</a></div>
|
1204
|
+
<div class="foo toclevel4"><a href="#_railsuserswitching">6.20.2. RailsUserSwitching</a></div>
|
1205
|
+
<div class="foo toclevel4"><a href="#_railsdefaultuser">6.20.3. RailsDefaultUser</a></div>
|
1206
|
+
<div class="foo toclevel4"><a href="#_railsallowmodrewrite">6.20.4. RailsAllowModRewrite</a></div>
|
1207
|
+
<div class="foo toclevel4"><a href="#_railsspawnmethod">6.20.5. RailsSpawnMethod</a></div>
|
1208
|
+
<div class="foo toclevel4"><a href="#_railsautodetect_rackautodetect_and_wsgiautodetect">6.20.6. RailsAutoDetect, RackAutoDetect and WsgiAutoDetect</a></div>
|
1200
1209
|
<div class="foo toclevel2"><a href="#troubleshooting">7. Troubleshooting</a></div>
|
1201
1210
|
<div class="foo toclevel3"><a href="#_operating_system_specific_problems">7.1. Operating system-specific problems</a></div>
|
1202
1211
|
<div class="foo toclevel4"><a href="#_macos_x_the_installer_cannot_locate_mamp_8217_s_apache">7.1.1. MacOS X: The installer cannot locate MAMP’s Apache</a></div>
|
@@ -1665,8 +1674,26 @@ sudo apt-get update</pre>
|
|
1665
1674
|
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="_installing_or_upgrading_on_red_hat_fedora_centos_or_scientificlinux"></span><h3 data-comment-topic="installing-or-upgrading-on-red-hat-fedora-centos-or-scientificlinux-1y5ie8b" data-anchor="_installing_or_upgrading_on_red_hat_fedora_centos_or_scientificlinux">2.5. Installing or upgrading on Red Hat, Fedora, CentOS or ScientificLinux</h3>
|
1666
1675
|
<div class="paragraph"><p>YUM repositories with RPMs are maintained by <a href="https://github.com/erikogan/passenger">Erik Ogan</a> and <a href="http://stealthymonkeys.com/">Stealthy Monkeys Consulting</a>. Only packages for the open source version of Phusion Passenger are provided. <a href="https://www.phusionpassenger.com/enterprise">Phusion Passenger Enterprise</a> customers should use the <a href="#rubygems_generic_install">generic RubyGems installation method</a> or <a href="#tarball_generic_install">the generic tarball installation method</a> instead.</p></div>
|
1667
1676
|
<div class="paragraph"><p>If you use YUM to install Phusion Passenger then you do not need to run <span class="monospaced">passenger-install-apache2-module</span> or <span class="monospaced">passenger-install-nginx-module</span>. The YUM packages contain all the binaries that you need. You also don’t need to modify any Apache or Nginx configuration to get them to load Phusion Passenger, the packages provide configuration snippets for you as well.</p></div>
|
1668
|
-
<span class="anchor_helper" id="
|
1669
|
-
<div class="
|
1677
|
+
<span class="anchor_helper" id="_step_1_import_the_stealthy_monkeys_consulting_8217_s_gpg_key"></span><h4 class="float" data-anchor="_step_1_import_the_stealthy_monkeys_consulting_8217_s_gpg_key">Step 1: Import the Stealthy Monkeys Consulting’s GPG key</h4>
|
1678
|
+
<div class="listingblock">
|
1679
|
+
<div class="content monospaced">
|
1680
|
+
<pre>rpm --import http://passenger.stealthymonkeys.com/RPM-GPG-KEY-stealthymonkeys.asc</pre>
|
1681
|
+
</div>
|
1682
|
+
</div>
|
1683
|
+
<span class="anchor_helper" id="_step_2_install_the_release_package"></span><h4 class="float" data-anchor="_step_2_install_the_release_package">Step 2: Install the release package</h4>
|
1684
|
+
<div class="paragraph"><p>Install the passenger-release package from the <a href="http://passenger.stealthymonkeys.com/">main repository</a>.</p></div>
|
1685
|
+
<div class="paragraph"><p>Fedora Core 17:</p></div>
|
1686
|
+
<div class="listingblock">
|
1687
|
+
<div class="content monospaced">
|
1688
|
+
<pre>yum install http://passenger.stealthymonkeys.com/fedora/17/passenger-release.noarch.rpm</pre>
|
1689
|
+
</div>
|
1690
|
+
</div>
|
1691
|
+
<div class="paragraph"><p>Fedora Core 16:</p></div>
|
1692
|
+
<div class="listingblock">
|
1693
|
+
<div class="content monospaced">
|
1694
|
+
<pre>yum install http://passenger.stealthymonkeys.com/fedora/16/passenger-release.noarch.rpm</pre>
|
1695
|
+
</div>
|
1696
|
+
</div>
|
1670
1697
|
<div class="paragraph"><p>Fedora Core 15:</p></div>
|
1671
1698
|
<div class="listingblock">
|
1672
1699
|
<div class="content monospaced">
|
@@ -1679,19 +1706,19 @@ sudo apt-get update</pre>
|
|
1679
1706
|
<pre>yum install http://passenger.stealthymonkeys.com/fedora/14/passenger-release.noarch.rpm</pre>
|
1680
1707
|
</div>
|
1681
1708
|
</div>
|
1682
|
-
<div class="paragraph"><p>RHEL
|
1709
|
+
<div class="paragraph"><p>RHEL 6 / CentOS 6 / ScientificLinux 6: (Note: these packages depend on <a href="http://fedoraproject.org/wiki/EPEL">EPEL</a>.)</p></div>
|
1683
1710
|
<div class="listingblock">
|
1684
1711
|
<div class="content monospaced">
|
1685
|
-
<pre>
|
1712
|
+
<pre>yum install http://passenger.stealthymonkeys.com/rhel/6/passenger-release.noarch.rpm</pre>
|
1686
1713
|
</div>
|
1687
1714
|
</div>
|
1688
|
-
<div class="paragraph"><p>RHEL
|
1715
|
+
<div class="paragraph"><p>RHEL 5 / CentOS 5 / ScientificLinux 5: (Note: these packages depend on <a href="http://fedoraproject.org/wiki/EPEL">EPEL</a>.)</p></div>
|
1689
1716
|
<div class="listingblock">
|
1690
1717
|
<div class="content monospaced">
|
1691
|
-
<pre>
|
1718
|
+
<pre>rpm -Uvh http://passenger.stealthymonkeys.com/rhel/5/passenger-release.noarch.rpm</pre>
|
1692
1719
|
</div>
|
1693
1720
|
</div>
|
1694
|
-
<span class="anchor_helper" id="
|
1721
|
+
<span class="anchor_helper" id="_step_3_install_the_right_phusion_passenger_package"></span><h4 class="float" data-anchor="_step_3_install_the_right_phusion_passenger_package">Step 3: Install the right Phusion Passenger package</h4>
|
1695
1722
|
<div class="paragraph"><p>From there you can use <a href="http://prefetch.net/articles/yum.html">YUM</a> to install packages. For example, try one of these:</p></div>
|
1696
1723
|
<div class="paragraph"><p>Phusion Passenger for Apache:</p></div>
|
1697
1724
|
<div class="listingblock">
|
@@ -1733,13 +1760,115 @@ Install the Enterprise version by following one of the installation guides in th
|
|
1733
1760
|
<div class="paragraph"><p>The uninstallation is necessary because the Enterprise Ruby gem has a different gem name (<em>passenger-enterprise-server</em> instead of <em>passenger</em>), but the same administration command names (e.g. <span class="monospaced">passenger-status</span>). Uninstalling the open source version avoids any conflicts.</p></div>
|
1734
1761
|
</div>
|
1735
1762
|
<div class="sect2">
|
1736
|
-
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="
|
1763
|
+
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="_cryptographic_verification_of_installation_files"></span><h3 data-comment-topic="cryptographic-verification-of-installation-files-ed3r9v" data-anchor="_cryptographic_verification_of_installation_files">2.7. Cryptographic verification of installation files</h3>
|
1764
|
+
<div class="sect3">
|
1765
|
+
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="_synopsis_2"></span><h4 data-comment-topic="synopsis-uwnz2o" data-anchor="_synopsis_2">2.7.1. Synopsis</h4>
|
1766
|
+
<div class="paragraph"><p>We digitally sign various files with our GPG key so that you can check whether they’re legit, i.e. whether they really came from Phusion and haven’t been tampered with by a third party. We apply signing since the open source version 4.0.0 RC 4, or the Enterprise version 4.0.0 RC 1.</p></div>
|
1767
|
+
</div>
|
1768
|
+
<div class="sect3">
|
1769
|
+
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="_importing_the_phusion_software_signing_key"></span><h4 data-comment-topic="importing-the-phusion-software-signing-key-1x0rhv" data-anchor="_importing_the_phusion_software_signing_key">2.7.2. Importing the Phusion Software Signing key</h4>
|
1770
|
+
<div class="paragraph"><p>Phusion’s GPG key for signing software is as follows:</p></div>
|
1771
|
+
<div class="literalblock">
|
1772
|
+
<div class="content monospaced">
|
1773
|
+
<pre>Phusion Software Signing (software-signing@phusion.nl)
|
1774
|
+
Short key ID: 0x0A212A8C
|
1775
|
+
Long key ID: 0x2AC745A50A212A8C
|
1776
|
+
Fingerprint: D5F0 8514 2693 9232 F437 AB72 2AC7 45A5 0A21 2A8C</pre>
|
1777
|
+
</div>
|
1778
|
+
</div>
|
1779
|
+
<div class="paragraph"><p>This key is stored at <a href="http://www.phusion.nl/about/gpg">the Phusion website</a> and at the key servers <a href="http://pool.sks-keyservers.net/pks/lookup?op=get&search=0x2AC745A50A212A8C">sks-keyservers.net</a> and <a href="http://keyserver.ubuntu.com/pks/lookup?op=get&search=0x2AC745A50A212A8C">keyserver.ubuntu.com</a>. You can import it to your keyring with one of these command:</p></div>
|
1780
|
+
<div class="listingblock">
|
1781
|
+
<div class="content monospaced">
|
1782
|
+
<pre>gpg --keyserver pool.sks-keyservers.net --search-keys 0x2AC745A50A212A8C
|
1783
|
+
# -OR-
|
1784
|
+
gpg --keyserver keyserver.ubuntu.com --search-keys 0x2AC745A50A212A8C</pre>
|
1785
|
+
</div>
|
1786
|
+
</div>
|
1787
|
+
<div class="paragraph"><p>The Phusion Software Signing key is only used for signing software. It’s never used for signing emails or for encrypting files, so please be suspicious if you encounter usage of this key outside the context of signing software, and alert us at <a href="mailto:support@phusion.nl">support@phusion.nl</a>. Include "notspam" in the message to bypass our spam filter.</p></div>
|
1788
|
+
<div class="paragraph"><p>The email address <a href="mailto:software-signing@phusion.nl">software-signing@phusion.nl</a> redirects to <a href="mailto:info@phusion.nl">info@phusion.nl</a> so it’s safe to send email there.</p></div>
|
1789
|
+
</div>
|
1790
|
+
<div class="sect3">
|
1791
|
+
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="_verifying_the_phusion_software_signing_key"></span><h4 data-comment-topic="verifying-the-phusion-software-signing-key-10430lg" data-anchor="_verifying_the_phusion_software_signing_key">2.7.3. Verifying the Phusion Software Signing key</h4>
|
1792
|
+
<div class="paragraph"><p>The Phusion Software Signing key is also <strong>signed by the Phusion founders</strong>. Their keys are as follows:</p></div>
|
1793
|
+
<div class="literalblock">
|
1794
|
+
<div class="content monospaced">
|
1795
|
+
<pre>Hongli Lai (hongli@phusion.nl)
|
1796
|
+
Short key ID: 4B6F4332
|
1797
|
+
Long key ID: 06A131094B6F4332
|
1798
|
+
Fingerprint: 64E8 0420 FC6A 499F 9E1F 81FA 06A1 3109 4B6F 4332</pre>
|
1799
|
+
</div>
|
1800
|
+
</div>
|
1801
|
+
<div class="literalblock">
|
1802
|
+
<div class="content monospaced">
|
1803
|
+
<pre>Ninh Bui (ninh@phusion.nl)
|
1804
|
+
Short key ID: 6FAF3782
|
1805
|
+
Long key ID: BA8DA3F46FAF3782
|
1806
|
+
Fingerprint: 353A 398C 49AF 5CD5 74A0 656C BA8D A3F4 6FAF 3782</pre>
|
1807
|
+
</div>
|
1808
|
+
</div>
|
1809
|
+
<div class="paragraph"><p>Both keys are stored at both sks-servers.net and keyserver.ubuntu.com. Import them with:</p></div>
|
1810
|
+
<div class="listingblock">
|
1811
|
+
<div class="content monospaced">
|
1812
|
+
<pre>gpg --keyserver pool.sks-servers.net --search-keys 0x06A131094B6F4332
|
1813
|
+
gpg --keyserver pool.sks-servers.net --search-keys 0xBA8DA3F46FAF3782
|
1814
|
+
# -OR-
|
1815
|
+
gpg --keyserver keyserver.ubuntu.com --search-keys 0x06A131094B6F4332
|
1816
|
+
gpg --keyserver keyserver.ubuntu.com --search-keys 0xBA8DA3F46FAF3782</pre>
|
1817
|
+
</div>
|
1818
|
+
</div>
|
1819
|
+
</div>
|
1820
|
+
<div class="sect3">
|
1821
|
+
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="_verifying_the_gem_and_tarball"></span><h4 data-comment-topic="verifying-the-gem-and-tarball-1nf0uov" data-anchor="_verifying_the_gem_and_tarball">2.7.4. Verifying the gem and tarball</h4>
|
1822
|
+
<div class="paragraph"><p>You can find the open source version’s gem and tarball GPG signatures at <a href="https://www.phusionpassenger.com/signatures/">https://www.phusionpassenger.com/signatures/</a>. The Enterprise version’s GPG signatures can be found in the <a href="https://www.phusionpassenger.com/orders">Customer Area</a>. All signatures have the <em>.asc</em> extension. Once you have imported our key, you can verify the validity of a file against its signature as follows:</p></div>
|
1823
|
+
<div class="listingblock">
|
1824
|
+
<div class="content monospaced">
|
1825
|
+
<pre>$ gpg --verify passenger-x.x.x.tar.gz.asc passenger-x.x.x.tar.gz
|
1826
|
+
gpg: Signature made Mon Mar 11 09:45:46 2013 CET using RSA key ID 0A212A8C
|
1827
|
+
gpg: Good signature from "Phusion Software Signing <software-signing@phusion.nl>"</pre>
|
1828
|
+
</div>
|
1829
|
+
</div>
|
1830
|
+
</div>
|
1831
|
+
<div class="sect3">
|
1832
|
+
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="_verifying_git_signatures"></span><h4 data-comment-topic="verifying-git-signatures-oaafwd" data-anchor="_verifying_git_signatures">2.7.5. Verifying Git signatures</h4>
|
1833
|
+
<div class="paragraph"><p>Tags in the <a href="https://github.com/FooBarWidget/passenger">Git repository for the open source version</a> are also tagged. You can verify a Git tag as follows:</p></div>
|
1834
|
+
<div class="listingblock">
|
1835
|
+
<div class="content monospaced">
|
1836
|
+
<pre>$ git tag --verify release-x.x.x
|
1837
|
+
object d886f34b5705e4314feccaf0d77b9a38416e15e0
|
1838
|
+
type commit
|
1839
|
+
tag release-4.0.0.rc5
|
1840
|
+
tagger Hongli Lai (Phusion) <hongli@phusion.nl> 1362993117 +0100
|
1841
|
+
|
1842
|
+
This is a tag message.
|
1843
|
+
gpg: Signature made Mon Mar 11 10:12:02 2013 CET using RSA key ID 0A212A8C
|
1844
|
+
gpg: Good signature from "Phusion Software Signing <software-signing@phusion.nl>"</pre>
|
1845
|
+
</div>
|
1846
|
+
</div>
|
1847
|
+
</div>
|
1848
|
+
<div class="sect3">
|
1849
|
+
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="_verifying_deb_and_rpm_packages"></span><h4 data-comment-topic="verifying-deb-and-rpm-packages-vgtv04" data-anchor="_verifying_deb_and_rpm_packages">2.7.6. Verifying DEB and RPM packages</h4>
|
1850
|
+
<div class="paragraph"><p>The DEB and RPM packages are signed with the signatures of the respective packagers. Phusion does not provide signatures for them.</p></div>
|
1851
|
+
</div>
|
1852
|
+
<div class="sect3">
|
1853
|
+
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="_revocation"></span><h4 data-comment-topic="revocation-4o01n2" data-anchor="_revocation">2.7.7. Revocation</h4>
|
1854
|
+
<div class="paragraph"><p>In the event our key is compromised, we will revoke the key and upload the revocation information to sks-servers.net and keyserver.ubuntu.com. However your system will not know about the revocation until you update the keys from the keyservers. You should update your keys regularly (e.g. once a week) by invoking:</p></div>
|
1855
|
+
<div class="listingblock">
|
1856
|
+
<div class="content monospaced">
|
1857
|
+
<pre>gpg --refresh-keys --keyserver pool.sks-servers.net
|
1858
|
+
# -OR-
|
1859
|
+
gpg --refresh-keys --keyserver keyserver.ubuntu.com</pre>
|
1860
|
+
</div>
|
1861
|
+
</div>
|
1862
|
+
</div>
|
1863
|
+
</div>
|
1864
|
+
<div class="sect2">
|
1865
|
+
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="_non_interactive_automatic_headless_installs_or_upgrades"></span><h3 data-comment-topic="non-interactive-automatic-headless-installs-or-upgrades-1arnxii" data-anchor="_non_interactive_automatic_headless_installs_or_upgrades">2.8. Non-interactive, automatic, headless installs or upgrades</h3>
|
1737
1866
|
<div class="paragraph"><p>By default, the installer (<span class="monospaced">passenger-install-apache2-module</span>) is interactive. If you want to automate installation then you can do so by passing <span class="monospaced">--auto</span> to the installer. See also <span class="monospaced">passenger-install-apache2-module --help</span> for more options.</p></div>
|
1738
1867
|
</div>
|
1739
1868
|
<div class="sect2">
|
1740
|
-
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="_customizing_the_compilation_process"></span><h3 data-comment-topic="customizing-the-compilation-process-1sds3od" data-anchor="_customizing_the_compilation_process">2.
|
1869
|
+
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="_customizing_the_compilation_process"></span><h3 data-comment-topic="customizing-the-compilation-process-1sds3od" data-anchor="_customizing_the_compilation_process">2.9. Customizing the compilation process</h3>
|
1741
1870
|
<div class="sect3">
|
1742
|
-
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="_setting_the_compiler"></span><h4 data-comment-topic="setting-the-compiler-1symq7h" data-anchor="_setting_the_compiler">2.
|
1871
|
+
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="_setting_the_compiler"></span><h4 data-comment-topic="setting-the-compiler-1symq7h" data-anchor="_setting_the_compiler">2.9.1. Setting the compiler</h4>
|
1743
1872
|
<div class="paragraph"><p>You can force the Phusion Passenger build system to use a specific C or C++ compiler by setting the <span class="monospaced">CC</span> and <span class="monospaced">CXX</span> environment variables. These may be set to any arbitrary shell commands.</p></div>
|
1744
1873
|
<div class="paragraph"><p>For example, contributors who want to hack on Phusion Passenger may want to use Clang for faster compilation and <a href="http://ccache.samba.org/">ccache</a> for faster recompilation, and may want to enable more error-catching compilation flags:</p></div>
|
1745
1874
|
<div class="listingblock">
|
@@ -1750,7 +1879,7 @@ export CXX='ccache clang++ -fcolor-diagnostics -Qunused-arguments -fcatch-undefi
|
|
1750
1879
|
</div>
|
1751
1880
|
</div>
|
1752
1881
|
<div class="sect3">
|
1753
|
-
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="_adding_additional_compiler_or_linker_flags"></span><h4 data-comment-topic="adding-additional-compiler-or-linker-flags-wzu0ey" data-anchor="_adding_additional_compiler_or_linker_flags">2.
|
1882
|
+
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="_adding_additional_compiler_or_linker_flags"></span><h4 data-comment-topic="adding-additional-compiler-or-linker-flags-wzu0ey" data-anchor="_adding_additional_compiler_or_linker_flags">2.9.2. Adding additional compiler or linker flags</h4>
|
1754
1883
|
<div class="paragraph"><p>On some systems, C/C++ libraries and headers that Phusion Passenger requires may be located in a non-standard directory. You can force the Phusion Passenger build system to look in those locations by injecting compiler and linker flags using the following environment variables:</p></div>
|
1755
1884
|
<div class="dlist"><dl>
|
1756
1885
|
<dt class="hdlist1">
|
@@ -1804,7 +1933,7 @@ export CXX='ccache clang++ -fcolor-diagnostics -Qunused-arguments -fcatch-undefi
|
|
1804
1933
|
</dl></div>
|
1805
1934
|
</div>
|
1806
1935
|
<div class="sect3">
|
1807
|
-
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="_forcing_location_of_certain_command_line_tools"></span><h4 data-comment-topic="forcing-location-of-certain-command-line-tools-1hym30u" data-anchor="_forcing_location_of_certain_command_line_tools">2.
|
1936
|
+
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="_forcing_location_of_certain_command_line_tools"></span><h4 data-comment-topic="forcing-location-of-certain-command-line-tools-1hym30u" data-anchor="_forcing_location_of_certain_command_line_tools">2.9.3. Forcing location of certain command line tools</h4>
|
1808
1937
|
<div class="paragraph"><p>The Phusion Passenger build system attempts to autodetect many things by locating relevant helper tools. For example, to find out which compiler flags it should use for compiling Apache modules, it locates the <span class="monospaced">apxs2</span> command and queries it. To find out which compiler flags it should use for libcurl, it queries the <span class="monospaced">curl-config</span> command. These commands may not be in <span class="monospaced">$PATH</span>, or even when they are you may want to use a different one.</p></div>
|
1809
1938
|
<div class="paragraph"><p>You can often force the build to find certain command line tools at certain locations by using the following environment variables:</p></div>
|
1810
1939
|
<div class="dlist"><dl>
|
@@ -1860,7 +1989,7 @@ export CXX='ccache clang++ -fcolor-diagnostics -Qunused-arguments -fcatch-undefi
|
|
1860
1989
|
</div>
|
1861
1990
|
</div>
|
1862
1991
|
<div class="sect2">
|
1863
|
-
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="working_with_apache_conf"></span><h3 data-comment-topic="locating-the-apache-configuration-file-1fterqv" data-anchor="working_with_apache_conf">2.
|
1992
|
+
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="working_with_apache_conf"></span><h3 data-comment-topic="locating-the-apache-configuration-file-1fterqv" data-anchor="working_with_apache_conf">2.10. Working with the Apache configuration file</h3>
|
1864
1993
|
<div class="paragraph"><p>On most systems the Apache configuration file is located in either <em>/etc/apache2/httpd.conf</em> or <em>/etc/apache2/apache2.conf</em>. However, to allow better organization, many operating systems and Apache distributions also read configuration files in the <em>conf.d</em>, <em>mods-enabled</em> and <em>sites-enabled</em> subdirectories.</p></div>
|
1865
1994
|
<div class="paragraph"><p><em>mods-enabled</em> contains symlinks to files in <em>mods-available</em>. This latter subdirectory contains config files for all available modules, while <em>mods-enabled</em> contains only a subset, namely the modules that should actually be enabled. The symlinks are created using the <span class="monospaced">a2enmod</span> tool. <em><strong>.load</strong></em> files contain <span class="monospaced">LoadModule</span> directives, while <em>.conf</em> files contain all other configuration directives.</p></div>
|
1866
1995
|
<div class="paragraph"><p>Use <em>mods-enabled</em>/<em>mods-available</em> to store Phusion Passenger configuration if you can:</p></div>
|
@@ -1885,7 +2014,7 @@ Enable by running <span class="monospaced">sudo a2enmod passenger</span>.
|
|
1885
2014
|
<div class="paragraph"><p>On OS X Server >= 10.8 Mountain Lion the location of the Apache configuration file depends on whether you use Web Services or not. If you do, then the configuration file is in <em>/Library/Server/Web/Config/apache2/httpd_server_app.conf</em>. If you do not, then the configuration file is in <em>/etc/apache2/httpd.conf</em>.</p></div>
|
1886
2015
|
</div>
|
1887
2016
|
<div class="sect2">
|
1888
|
-
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="_disabling_without_uninstalling"></span><h3 data-comment-topic="unloading-disabling-phusion-passenger-from-apache-without-uninstalling-it-s1axnx" data-anchor="_disabling_without_uninstalling">2.
|
2017
|
+
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="_disabling_without_uninstalling"></span><h3 data-comment-topic="unloading-disabling-phusion-passenger-from-apache-without-uninstalling-it-s1axnx" data-anchor="_disabling_without_uninstalling">2.11. Disabling without uninstalling</h3>
|
1889
2018
|
<div class="paragraph"><p>You can temporarily unload (disable) Phusion Passenger from the web server, without
|
1890
2019
|
uninstalling the Phusion Passenger files, so that the web server behaves as if Phusion
|
1891
2020
|
Passenger was never installed in the first place. This might be useful to you if -
|
@@ -1917,8 +2046,8 @@ NameVirtualHosts *:80
|
|
1917
2046
|
|
1918
2047
|
LoadModule passenger_module /somewhere/passenger-x.x.x/ext/apache2/mod_passenger.so
|
1919
2048
|
|
1920
|
-
PassengerRuby /usr/bin/ruby
|
1921
2049
|
PassengerRoot /somewhere/passenger/x.x.x
|
2050
|
+
PassengerDefaultRuby /usr/bin/ruby
|
1922
2051
|
PassengerMaxPoolSize 10
|
1923
2052
|
|
1924
2053
|
<VirtualHost *:80>
|
@@ -1937,8 +2066,8 @@ NameVirtualHosts *:80
|
|
1937
2066
|
|
1938
2067
|
# LoadModule passenger_module /somewhere/passenger-x.x.x/ext/apache2/mod_passenger.so
|
1939
2068
|
|
1940
|
-
# PassengerRuby /usr/bin/ruby
|
1941
2069
|
# PassengerRoot /somewhere/passenger/x.x.x
|
2070
|
+
# PassengerDefaultRuby /usr/bin/ruby
|
1942
2071
|
# PassengerMaxPoolSize 10
|
1943
2072
|
|
1944
2073
|
<VirtualHost *:80>
|
@@ -1951,7 +2080,7 @@ NameVirtualHosts *:80
|
|
1951
2080
|
<div class="paragraph"><p>After you’ve done this, save the configuration file and restart the web server.</p></div>
|
1952
2081
|
</div>
|
1953
2082
|
<div class="sect2">
|
1954
|
-
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="uninstalling"></span><h3 data-comment-topic="uninstalling-phusion-passenger-1qb4ssq" data-anchor="uninstalling">2.
|
2083
|
+
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="uninstalling"></span><h3 data-comment-topic="uninstalling-phusion-passenger-1qb4ssq" data-anchor="uninstalling">2.12. Uninstalling</h3>
|
1955
2084
|
<div class="paragraph"><p>To uninstall Phusion Passenger, please first remove all Phusion Passenger
|
1956
2085
|
configuration directives from your web server configuration file(s). After you’ve
|
1957
2086
|
done this, you need to remove the Phusion Passenger files.</p></div>
|
@@ -1977,7 +2106,7 @@ If you installed Phusion Passenger through APT or YUM, then use them to uninstal
|
|
1977
2106
|
</ul></div>
|
1978
2107
|
</div>
|
1979
2108
|
<div class="sect2">
|
1980
|
-
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="moving_phusion_passenger"></span><h3 data-comment-topic="moving-to-a-different-directory-1n0gkwh" data-anchor="moving_phusion_passenger">2.
|
2109
|
+
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="moving_phusion_passenger"></span><h3 data-comment-topic="moving-to-a-different-directory-1n0gkwh" data-anchor="moving_phusion_passenger">2.13. Moving to a different directory</h3>
|
1981
2110
|
<div class="paragraph"><p>If you installed Phusion Passenger through a tarball then you can move the Phusion Passenger directory to another location. This is not possible if you used any of the other installation methods.</p></div>
|
1982
2111
|
<div class="paragraph"><p>First, move the directory to whereever you like:</p></div>
|
1983
2112
|
<div class="listingblock">
|
@@ -2605,7 +2734,7 @@ $ some_awesome_editor passenger_wsgi.py
|
|
2605
2734
|
$ cat passenger_wsgi.py
|
2606
2735
|
def application(environ, start_response):
|
2607
2736
|
start_response('200 OK', [('Content-Type', 'text/plain')])
|
2608
|
-
return ["hello world!\n"]</pre>
|
2737
|
+
return [b"hello world!\n"]</pre>
|
2609
2738
|
</div>
|
2610
2739
|
</div>
|
2611
2740
|
<div class="paragraph"><p>Finally, we deploy it by adding the following configuration options to
|
@@ -2728,66 +2857,137 @@ this option as well. Please read
|
|
2728
2857
|
<div class="paragraph"><p>This required option may only occur once, in the global server configuration.</p></div>
|
2729
2858
|
</div>
|
2730
2859
|
<div class="sect2">
|
2731
|
-
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="
|
2732
|
-
<div class="paragraph"><p>
|
2733
|
-
<div class="paragraph"><p>
|
2860
|
+
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="PassengerDefaultRuby"></span><h3 data-comment-topic="passengerdefaultruby-and-passengerruby-7zblp8" data-anchor="PassengerDefaultRuby">6.2. PassengerDefaultRuby and PassengerRuby</h3>
|
2861
|
+
<div class="paragraph"><p><strong>Introduced in version 4.0.0.</strong></p></div>
|
2862
|
+
<div class="paragraph"><p>This option specifies the default Ruby interpreter to use for web apps as well as for all sorts of internal Phusion Passenger helper scripts, e.g. the one used by <a href="#PassengerPreStart">PassengerPreStart</a>. Please see <a href="#PassengerRuby">PassengerRuby</a> for more information, as well as how it relates to <a href="#PassengerRuby">PassengerRuby</a>.</p></div>
|
2863
|
+
<div class="paragraph"><p>This option may occur in the global server configuration. The default value is <em>ruby</em>, meaning that the Ruby interpreter will be looked up according to the <span class="monospaced">PATH</span> environment variable.</p></div>
|
2864
|
+
</div>
|
2865
|
+
<div class="sect2">
|
2866
|
+
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="PassengerRuby"></span><h3 data-comment-topic="passengerruby-filename--1r3fv73" data-anchor="PassengerRuby">6.3. PassengerRuby <filename></h3>
|
2867
|
+
<div class="paragraph"><p>The <span class="monospaced">PassengerDefaultRuby</span> and <span class="monospaced">PassengerRuby</span> directives specify the Ruby interpreter to use. Similarly, the <span class="monospaced">PassengerPython</span> directive is for specifying the Python interpreter.</p></div>
|
2868
|
+
<div class="paragraph"><p>The relationship between <span class="monospaced">PassengerDefaultRuby</span> and <span class="monospaced">PassengerRuby</span> is as follows:</p></div>
|
2734
2869
|
<div class="ulist"><ul>
|
2735
2870
|
<li>
|
2736
2871
|
<p>
|
2737
|
-
|
2872
|
+
<span class="monospaced">PassengerDefaultRuby</span> may only occur in the global server configuration.
|
2738
2873
|
</p>
|
2739
2874
|
</li>
|
2740
2875
|
<li>
|
2741
2876
|
<p>
|
2742
|
-
|
2877
|
+
<span class="monospaced">PassengerRuby</span> may occur everywhere: in the global server configuration, in <span class="monospaced"><VirtualHost></span>, in <span class="monospaced"><Directory></span>, in <span class="monospaced"><Location></span>, and in <em>.htaccess</em> if <span class="monospaced">AllowOverride Options</span> is on.
|
2743
2878
|
</p>
|
2744
2879
|
</li>
|
2745
2880
|
<li>
|
2746
2881
|
<p>
|
2747
|
-
In
|
2748
|
-
</p>
|
2749
|
-
</li>
|
2750
|
-
<li>
|
2751
|
-
<p>
|
2752
|
-
In <em>.htaccess</em>, if <span class="monospaced">AllowOverride Options</span> is on.
|
2882
|
+
You don’t <strong>have</strong> to specify <span class="monospaced">PassengerRuby</span>. In this case <span class="monospaced">PassengerDefaultRuby</span> is used as the Ruby interpreter. But if you do specify <span class="monospaced">PassengerRuby</span> then it will override <span class="monospaced">PassengerDefaultRuby</span> in that context. This allows you to use <span class="monospaced">PassengerRuby</span> to specify a different Ruby interpreter on a per-application basis.
|
2753
2883
|
</p>
|
2754
2884
|
</li>
|
2755
2885
|
</ul></div>
|
2756
|
-
<div class="paragraph"><p>
|
2757
|
-
<div class="paragraph"><p>
|
2758
|
-
<div class="paragraph"><p>
|
2886
|
+
<div class="paragraph"><p>Phusion Passenger not only uses Ruby to run web apps, but also for running certain helper tools that are written in Ruby, e.g. the internal helper script used by <a href="#PassengerPreStart">PassengerPreStart</a>. These tools are always run using <span class="monospaced">PassengerDefaultRuby</span>, never by <span class="monospaced">PassengerRuby</span>. <span class="monospaced">PassengerRuby</span> is only used for running web apps.</p></div>
|
2887
|
+
<div class="paragraph"><p>The reason why <span class="monospaced">PassengerDefaultRuby</span> exists at all is because limitations in the Apache API prevents us from implementing the same behavior using only the <span class="monospaced">PassengerRuby</span> directive.</p></div>
|
2888
|
+
<div class="paragraph"><p>There is no <span class="monospaced">PassengerDefaultPython</span> because there are no Phusion Passenger tools written in Python. As such, having <span class="monospaced">PassengerPython</span> is enough.</p></div>
|
2889
|
+
<div class="paragraph"><p>The following example illustrates how it works and how you can use these options to specify different Ruby/Python interpreters for different web apps.</p></div>
|
2890
|
+
<div class="listingblock">
|
2891
|
+
<div class="content monospaced">
|
2892
|
+
<pre># Use Ruby 1.8.7 by default.
|
2893
|
+
PassengerDefaultRuby /usr/bin/ruby1.8
|
2894
|
+
# Use Python 2.6 by default.
|
2895
|
+
PassengerPython /usr/bin/python2.6
|
2896
|
+
|
2897
|
+
<VirtualHost *:80>
|
2898
|
+
# This Rails web app will use Ruby 1.8.7
|
2899
|
+
ServerName www.foo.com
|
2900
|
+
DocumentRoot /webapps/foo/public
|
2901
|
+
</VirtualHost>
|
2902
|
+
|
2903
|
+
<VirtualHost *:80>
|
2904
|
+
# This Rails web app will use Ruby 1.9.3, as installed by RVM
|
2905
|
+
PassengerRuby /usr/local/rvm/wrappers/ruby-1.9.3/ruby
|
2906
|
+
ServerName www.bar.com
|
2907
|
+
DocumentRoot /webapps/bar/public
|
2908
|
+
|
2909
|
+
# If you have a web app deployed in a sub-URI, customize
|
2910
|
+
# PassengerRuby/PassengerPython inside a <Location> block.
|
2911
|
+
# The web app under www.bar.com/blog will use JRuby 1.7.1
|
2912
|
+
RackBaseURI /blog
|
2913
|
+
<Location /blog>
|
2914
|
+
PassengerRuby /usr/local/rvm/wrappers/jruby-1.7.1/ruby
|
2915
|
+
</Location>
|
2916
|
+
</VirtualHost>
|
2917
|
+
|
2918
|
+
<VirtualHost *:80>
|
2919
|
+
# This Flask web app will use Python 3.0
|
2920
|
+
PassengerPython /usr/bin/python3.0
|
2921
|
+
ServerName www.baz.com
|
2922
|
+
DocumentRoot /webapps/baz/public
|
2923
|
+
</VirtualHost></pre>
|
2924
|
+
</div>
|
2925
|
+
</div>
|
2926
|
+
<div class="paragraph">
|
2927
|
+
<div class="title">RVM helper tool</div>
|
2928
|
+
<p>Phusion Passenger provides the <span class="monospaced">passenger-config --ruby-command</span> tool for figuring out the correct command for invoking a specific Ruby interpreter. This is especially useful for RVM users. Suppose that you have both Ruby 1.8.7 and Ruby 1.9.3 installed through RVM, and you want to know the correct commands for each Ruby interpreter.</p>
|
2929
|
+
</div>
|
2930
|
+
<div class="paragraph"><p>For this purpose we’ll want to invoke <span class="monospaced">passenger-config</span> using its full path, because each time you <span class="monospaced">rvm use</span> a different Ruby interpreter, RVM changes <span class="monospaced">$PATH</span>. If you did not install Phusion Passenger through the generic tarball installation method, then here’s how you can figure out where <span class="monospaced">passenger-config</span> is:</p></div>
|
2931
|
+
<div class="listingblock">
|
2932
|
+
<div class="content monospaced">
|
2933
|
+
<pre>$ which passenger-config
|
2934
|
+
/opt/passenger/bin/passenger-config</pre>
|
2935
|
+
</div>
|
2936
|
+
</div>
|
2937
|
+
<div class="paragraph"><p>Now, switch to all the RVM Ruby interpreters you want to use. In each interpreter, invoke <span class="monospaced">passenger-config --ruby-command</span>. For Ruby 1.8.7:</p></div>
|
2938
|
+
<div class="listingblock">
|
2939
|
+
<div class="content monospaced">
|
2940
|
+
<pre>$ rvm use 1.8.7
|
2941
|
+
$ /opt/passenger/bin/passenger-config --ruby-command
|
2942
|
+
passenger-config was invoked through the following Ruby interpreter:
|
2943
|
+
Command: /usr/local/rvm/wrappers/ruby-1.8.7-p358/ruby
|
2944
|
+
Version: ruby 1.8.7 (2012-02-08 patchlevel 358) [universal-darwin12.0]
|
2945
|
+
To use in Apache: PassengerRuby /usr/local/rvm/wrappers/ruby-1.8.7-p358/ruby
|
2946
|
+
To use in Nginx : passenger_ruby /usr/local/rvm/wrappers/ruby-1.8.7-p358/ruby
|
2947
|
+
To use with Standalone: /usr/local/rvm/wrappers/ruby-1.8.7-p358/ruby /opt/passenger/bin/passenger start
|
2948
|
+
|
2949
|
+
The following Ruby interpreter was found first in $PATH:
|
2950
|
+
Command: /usr/local/rvm/wrappers/ruby-1.8.7-p358/ruby
|
2951
|
+
Version: ruby 1.8.7 (2012-02-08 patchlevel 358) [universal-darwin12.0]
|
2952
|
+
To use in Apache: PassengerRuby /usr/local/rvm/wrappers/ruby-1.8.7-p358/ruby
|
2953
|
+
To use in Nginx : passenger_ruby /usr/local/rvm/wrappers/ruby-1.8.7-p358/ruby
|
2954
|
+
To use with Standalone: /usr/local/rvm/wrappers/ruby-1.8.7-p358/ruby /opt/passenger/bin/passenger start
|
2955
|
+
|
2956
|
+
## Notes for RVM users
|
2957
|
+
Do you want to know which command to use for a different Ruby interpreter? 'rvm use' that Ruby interpreter, then re-run 'passenger-config --ruby-command'.</pre>
|
2958
|
+
</div>
|
2959
|
+
</div>
|
2960
|
+
<div class="paragraph"><p>Then, for Ruby 1.9.3:</p></div>
|
2961
|
+
<div class="listingblock">
|
2962
|
+
<div class="content monospaced">
|
2963
|
+
<pre>$ rvm use 1.9.3
|
2964
|
+
$ /opt/passenger/bin/passenger-config --ruby-command
|
2965
|
+
passenger-config was invoked through the following Ruby interpreter:
|
2966
|
+
Command: /usr/local/rvm/wrappers/ruby-1.9.3-p392/ruby
|
2967
|
+
Version: ruby 1.9.3p392 (2013-02-22 revision 39386) [x86_64-darwin12.2.1]
|
2968
|
+
To use in Apache: PassengerRuby /usr/local/rvm/wrappers/ruby-1.9.3-p392/ruby
|
2969
|
+
To use in Nginx : passenger_ruby /usr/local/rvm/wrappers/ruby-1.9.3-p392/ruby
|
2970
|
+
To use with Standalone: /usr/local/rvm/wrappers/ruby-1.9.3-p392/ruby /opt/passenger/bin/passenger start
|
2971
|
+
|
2972
|
+
The following Ruby interpreter was found first in $PATH:
|
2973
|
+
Command: /usr/local/rvm/wrappers/ruby-1.9.3-p392/ruby
|
2974
|
+
Version: ruby 1.9.3p392 (2013-02-22 revision 39386) [x86_64-darwin12.2.1]
|
2975
|
+
To use in Apache: PassengerRuby /usr/local/rvm/wrappers/ruby-1.9.3-p392/ruby
|
2976
|
+
To use in Nginx : passenger_ruby /usr/local/rvm/wrappers/ruby-1.9.3-p392/ruby
|
2977
|
+
To use with Standalone: /usr/local/rvm/wrappers/ruby-1.9.3-p392/ruby /opt/passenger/bin/passenger start
|
2978
|
+
|
2979
|
+
## Notes for RVM users
|
2980
|
+
Do you want to know which command to use for a different Ruby interpreter? 'rvm use' that Ruby interpreter, then re-run 'passenger-config --ruby-command'.</pre>
|
2981
|
+
</div>
|
2982
|
+
</div>
|
2759
2983
|
</div>
|
2760
2984
|
<div class="sect2">
|
2761
|
-
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="_passengerpython_lt_filename_gt"></span><h3 data-comment-topic="passengerpython-filename--1ssesv3" data-anchor="_passengerpython_lt_filename_gt">6.
|
2985
|
+
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="_passengerpython_lt_filename_gt"></span><h3 data-comment-topic="passengerpython-filename--1ssesv3" data-anchor="_passengerpython_lt_filename_gt">6.4. PassengerPython <filename></h3>
|
2762
2986
|
<div class="paragraph"><p><strong>Introduced in version 4.0.0.</strong></p></div>
|
2763
|
-
<div class="paragraph"><p>This option allows one to specify the Python interpreter to use.
|
2764
|
-
<div class="ulist"><ul>
|
2765
|
-
<li>
|
2766
|
-
<p>
|
2767
|
-
In the global server configuration.
|
2768
|
-
</p>
|
2769
|
-
</li>
|
2770
|
-
<li>
|
2771
|
-
<p>
|
2772
|
-
In a virtual host configuration block.
|
2773
|
-
</p>
|
2774
|
-
</li>
|
2775
|
-
<li>
|
2776
|
-
<p>
|
2777
|
-
In a <span class="monospaced"><Directory></span> or <span class="monospaced"><Location></span> block.
|
2778
|
-
</p>
|
2779
|
-
</li>
|
2780
|
-
<li>
|
2781
|
-
<p>
|
2782
|
-
In <em>.htaccess</em>, if <span class="monospaced">AllowOverride Options</span> is on.
|
2783
|
-
</p>
|
2784
|
-
</li>
|
2785
|
-
</ul></div>
|
2786
|
-
<div class="paragraph"><p>If you want to use a different Python interpreter for two different applications then you should define different <span class="monospaced">PassengerPython</span> directives in different virtual host blocks.</p></div>
|
2787
|
-
<div class="paragraph"><p>The default value is <em>python</em>, meaning that the Python interpreter will be looked up according to the <span class="monospaced">PATH</span> environment variable.</p></div>
|
2987
|
+
<div class="paragraph"><p>This option allows one to specify the Python interpreter to use. See <a href="#PassengerRuby">PassengerRuby</a> for more information. The default value is <em>python</em>, meaning that the Python interpreter will be looked up according to the <span class="monospaced">PATH</span> environment variable.</p></div>
|
2788
2988
|
</div>
|
2789
2989
|
<div class="sect2">
|
2790
|
-
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="PassengerAppRoot"></span><h3 data-comment-topic="passengerapproot-path-to-root--uf24yd" data-anchor="PassengerAppRoot">6.
|
2990
|
+
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="PassengerAppRoot"></span><h3 data-comment-topic="passengerapproot-path-to-root--uf24yd" data-anchor="PassengerAppRoot">6.5. PassengerAppRoot <path/to/root></h3>
|
2791
2991
|
<div class="paragraph"><p>By default, Phusion Passenger assumes that the application’s root directory
|
2792
2992
|
is the parent directory of the <em>public</em> directory. This option allows one to
|
2793
2993
|
specify the application’s root independently from the DocumentRoot, which
|
@@ -2829,7 +3029,7 @@ In <em>.htaccess</em>, if <span class="monospaced">AllowOverride Options</span>
|
|
2829
3029
|
</div>
|
2830
3030
|
</div>
|
2831
3031
|
<div class="sect2">
|
2832
|
-
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="PassengerSpawnMethod"></span><h3 data-comment-topic="passengerspawnmethod-string--sodg2y" data-anchor="PassengerSpawnMethod">6.
|
3032
|
+
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="PassengerSpawnMethod"></span><h3 data-comment-topic="passengerspawnmethod-string--sodg2y" data-anchor="PassengerSpawnMethod">6.6. PassengerSpawnMethod <string></h3>
|
2833
3033
|
<div class="admonitionblock">
|
2834
3034
|
<table><tr>
|
2835
3035
|
<td class="icon">
|
@@ -2912,7 +3112,7 @@ In a virtual host configuration block.
|
|
2912
3112
|
<div class="paragraph"><p>In each place, it may be specified at most once. The default value is <em>smart-lv2</em>.</p></div>
|
2913
3113
|
</div>
|
2914
3114
|
<div class="sect2">
|
2915
|
-
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="PassengerEnabled"></span><h3 data-comment-topic="passengerenabled-on-off--74rzth" data-anchor="PassengerEnabled">6.
|
3115
|
+
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="PassengerEnabled"></span><h3 data-comment-topic="passengerenabled-on-off--74rzth" data-anchor="PassengerEnabled">6.7. PassengerEnabled <on|off></h3>
|
2916
3116
|
<div class="paragraph"><p>You can set this option to <em>off</em> to completely disable Phusion Passenger for
|
2917
3117
|
a certain location. This is useful if, for example, you want to integrate a PHP
|
2918
3118
|
application into the same virtual host as a Rails application.</p></div>
|
@@ -2959,7 +3159,7 @@ In <em>.htaccess</em>.
|
|
2959
3159
|
<div class="paragraph"><p>In each place, it may be specified at most once. The default value is <em>on</em>.</p></div>
|
2960
3160
|
</div>
|
2961
3161
|
<div class="sect2">
|
2962
|
-
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="PassengerTempDir"></span><h3 data-comment-topic="passengertempdir-directory--68h2ng" data-anchor="PassengerTempDir">6.
|
3162
|
+
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="PassengerTempDir"></span><h3 data-comment-topic="passengertempdir-directory--68h2ng" data-anchor="PassengerTempDir">6.8. PassengerTempDir <directory></h3>
|
2963
3163
|
<div class="paragraph"><p>Specifies the directory that Phusion Passenger should use for storing temporary
|
2964
3164
|
files. This includes things such as Unix socket files, buffered file uploads
|
2965
3165
|
(see also <a href="#PassengerUploadBufferDir">PassengerUploadBufferDir</a>), etc.</p></div>
|
@@ -2988,7 +3188,7 @@ sudo -E passenger-status
|
|
2988
3188
|
</div>
|
2989
3189
|
</div>
|
2990
3190
|
<div class="sect2">
|
2991
|
-
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="PassengerUploadBufferDir"></span><h3 data-comment-topic="passengeruploadbufferdir-directory--kdr8at" data-anchor="PassengerUploadBufferDir">6.
|
3191
|
+
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="PassengerUploadBufferDir"></span><h3 data-comment-topic="passengeruploadbufferdir-directory--kdr8at" data-anchor="PassengerUploadBufferDir">6.9. PassengerUploadBufferDir <directory></h3>
|
2992
3192
|
<div class="paragraph"><p>Phusion Passenger buffers large file uploads to disk in order prevent slow file
|
2993
3193
|
uploads from blocking web applications. By default, a subdirectory in the
|
2994
3194
|
system’s temporary files directory (or a subdirectory in the directory specified
|
@@ -3031,7 +3231,7 @@ In <em>.htaccess</em>, if <span class="monospaced">AllowOverrides Options</span>
|
|
3031
3231
|
<div class="paragraph"><p>In each place, it may be specified at most once.</p></div>
|
3032
3232
|
</div>
|
3033
3233
|
<div class="sect2">
|
3034
|
-
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="_passengerrestartdir_lt_directory_gt"></span><h3 data-comment-topic="passengerrestartdir-directory--1fmhmv0" data-anchor="_passengerrestartdir_lt_directory_gt">6.
|
3234
|
+
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="_passengerrestartdir_lt_directory_gt"></span><h3 data-comment-topic="passengerrestartdir-directory--1fmhmv0" data-anchor="_passengerrestartdir_lt_directory_gt">6.10. PassengerRestartDir <directory></h3>
|
3035
3235
|
<div class="paragraph"><p>As described in the deployment chapters of this document, Phusion Passenger
|
3036
3236
|
checks the file <em>tmp/restart.txt</em> in the applications'
|
3037
3237
|
<a href="#application_root">root directory</a> for restarting applications. Sometimes it
|
@@ -3105,7 +3305,7 @@ allow the attacker to cause a Denial-of-Service.</p>
|
|
3105
3305
|
directory that’s readable by Apache, but only writable by administrators.</p></div>
|
3106
3306
|
</div>
|
3107
3307
|
<div class="sect2">
|
3108
|
-
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="PassengerBufferResponse"></span><h3 data-comment-topic="passengerbufferresponse-on-off--1y7ilka" data-anchor="PassengerBufferResponse">6.
|
3308
|
+
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="PassengerBufferResponse"></span><h3 data-comment-topic="passengerbufferresponse-on-off--1y7ilka" data-anchor="PassengerBufferResponse">6.11. PassengerBufferResponse <on|off></h3>
|
3109
3309
|
<div class="paragraph"><p>When turned on, application-generated responses are buffered by Apache. Buffering will
|
3110
3310
|
happen in memory.</p></div>
|
3111
3311
|
<div class="paragraph"><p>Before we proceed with explaining this configuration option, we want to state the following to avoid confusion. If you use Phusion Passenger for Apache, there are in fact two response buffering systems active:</p></div>
|
@@ -3206,7 +3406,7 @@ if responses can be huge. Because entire responses are buffered in memory when t
|
|
3206
3406
|
</div>
|
3207
3407
|
</div>
|
3208
3408
|
<div class="sect2">
|
3209
|
-
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="PassengerRollingRestarts"></span><h3 data-comment-topic="passengerrollingrestarts" data-anchor="PassengerRollingRestarts">6.
|
3409
|
+
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="PassengerRollingRestarts"></span><h3 data-comment-topic="passengerrollingrestarts" data-anchor="PassengerRollingRestarts">6.12. PassengerRollingRestarts <on|off></h3>
|
3210
3410
|
<div class="paragraph"><p><strong>This feature is only available in <a href="https://www.phusionpassenger.com/enterprise">Phusion Passenger Enterprise</a>. It was introduced in version 3.0.0. <a href="https://www.phusionpassenger.com/download">Buy Phusion Passenger Enterprise here.</a></strong></p></div>
|
3211
3411
|
<div class="paragraph"><p>Enables or disables support for rolling restarts. Normally when you
|
3212
3412
|
restart an application (by touching restart.txt), Phusion Passenger would
|
@@ -3279,7 +3479,7 @@ In <em>.htaccess</em>, if <span class="monospaced">AllowOverride Options</span>
|
|
3279
3479
|
<div class="paragraph"><p>In each place, it may be specified at most once. The default value is <em>off</em>.</p></div>
|
3280
3480
|
</div>
|
3281
3481
|
<div class="sect2">
|
3282
|
-
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="_passengerresistdeploymenterrors_lt_on_off_gt"></span><h3 data-comment-topic="passengerresistdeploymenterrors" data-anchor="_passengerresistdeploymenterrors_lt_on_off_gt">6.
|
3482
|
+
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="_passengerresistdeploymenterrors_lt_on_off_gt"></span><h3 data-comment-topic="passengerresistdeploymenterrors" data-anchor="_passengerresistdeploymenterrors_lt_on_off_gt">6.13. PassengerResistDeploymentErrors <on|off></h3>
|
3283
3483
|
<div class="paragraph"><p><strong>This feature is only available in <a href="https://www.phusionpassenger.com/enterprise">Phusion Passenger Enterprise</a>. It was introduced in version 3.0.0. <a href="https://www.phusionpassenger.com/download">Buy Phusion Passenger Enterprise here.</a></strong></p></div>
|
3284
3484
|
<div class="paragraph"><p>Enables or disables resistance against deployment errors.</p></div>
|
3285
3485
|
<div class="paragraph"><p>Suppose you’ve upgraded your application and you’ve issues a command to restart it (by touching restart.txt), but the application code contains an error that prevents Phusion Passenger from successfully spawning a process (e.g. a syntax error). Phusion Passenger would normally display an error message in response to this.</p></div>
|
@@ -3329,15 +3529,15 @@ In <em>.htaccess</em>, if <span class="monospaced">AllowOverride Options</span>
|
|
3329
3529
|
<div class="paragraph"><p>In each place, it may be specified at most once. The default value is <em>off</em>.</p></div>
|
3330
3530
|
</div>
|
3331
3531
|
<div class="sect2">
|
3332
|
-
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="_security_options"></span><h3 data-comment-topic="security-options-1pb75ho" data-anchor="_security_options">6.
|
3532
|
+
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="_security_options"></span><h3 data-comment-topic="security-options-1pb75ho" data-anchor="_security_options">6.14. Security options</h3>
|
3333
3533
|
<div class="sect3">
|
3334
|
-
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="PassengerUserSwitching"></span><h4 data-comment-topic="passengeruserswitching" data-anchor="PassengerUserSwitching">6.
|
3534
|
+
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="PassengerUserSwitching"></span><h4 data-comment-topic="passengeruserswitching" data-anchor="PassengerUserSwitching">6.14.1. PassengerUserSwitching <on|off></h4>
|
3335
3535
|
<div class="paragraph"><p>Whether to enable <a href="#user_switching">user switching support</a>.</p></div>
|
3336
3536
|
<div class="paragraph"><p>This option may only occur once, in the global server configuration.
|
3337
3537
|
The default value is <em>on</em>.</p></div>
|
3338
3538
|
</div>
|
3339
3539
|
<div class="sect3">
|
3340
|
-
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="_passengeruser_lt_username_gt"></span><h4 data-comment-topic="passengeruser" data-anchor="_passengeruser_lt_username_gt">6.
|
3540
|
+
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="_passengeruser_lt_username_gt"></span><h4 data-comment-topic="passengeruser" data-anchor="_passengeruser_lt_username_gt">6.14.2. PassengerUser <username></h4>
|
3341
3541
|
<div class="paragraph"><p>If <a href="#user_switching">user switching support</a> is enabled, then Phusion Passenger will
|
3342
3542
|
by default run the web application as the owner of the file <em>config/environment.rb</em>
|
3343
3543
|
(for Rails apps) or <em>config.ru</em> (for Rack apps). This option allows you to override
|
@@ -3364,7 +3564,7 @@ In a <span class="monospaced"><Directory></span> or <span class="monospace
|
|
3364
3564
|
<div class="paragraph"><p>In each place, it may be specified at most once.</p></div>
|
3365
3565
|
</div>
|
3366
3566
|
<div class="sect3">
|
3367
|
-
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="_passengergroup_lt_group_name_gt"></span><h4 data-comment-topic="passengergroup" data-anchor="_passengergroup_lt_group_name_gt">6.
|
3567
|
+
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="_passengergroup_lt_group_name_gt"></span><h4 data-comment-topic="passengergroup" data-anchor="_passengergroup_lt_group_name_gt">6.14.3. PassengerGroup <group name></h4>
|
3368
3568
|
<div class="paragraph"><p>If <a href="#user_switching">user switching support</a> is enabled, then Phusion Passenger will
|
3369
3569
|
by default run the web application as the primary group of the owner of the file
|
3370
3570
|
<em>config/environment.rb</em> (for Rails apps) or <em>config.ru</em> (for Rack apps). This option
|
@@ -3393,7 +3593,7 @@ In a <span class="monospaced"><Directory></span> or <span class="monospace
|
|
3393
3593
|
<div class="paragraph"><p>In each place, it may be specified at most once.</p></div>
|
3394
3594
|
</div>
|
3395
3595
|
<div class="sect3">
|
3396
|
-
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="PassengerDefaultUser"></span><h4 data-comment-topic="passengerdefaultuser" data-anchor="PassengerDefaultUser">6.
|
3596
|
+
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="PassengerDefaultUser"></span><h4 data-comment-topic="passengerdefaultuser" data-anchor="PassengerDefaultUser">6.14.4. PassengerDefaultUser <username></h4>
|
3397
3597
|
<div class="paragraph"><p>Phusion Passenger enables <a href="#user_switching">user switching support</a> by default.
|
3398
3598
|
This configuration option allows one to specify the user that applications must
|
3399
3599
|
run as, if user switching fails or is disabled.</p></div>
|
@@ -3401,7 +3601,7 @@ run as, if user switching fails or is disabled.</p></div>
|
|
3401
3601
|
The default value is <em>nobody</em>.</p></div>
|
3402
3602
|
</div>
|
3403
3603
|
<div class="sect3">
|
3404
|
-
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="PassengerDefaultGroup"></span><h4 data-comment-topic="passengerdefaultgroup" data-anchor="PassengerDefaultGroup">6.
|
3604
|
+
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="PassengerDefaultGroup"></span><h4 data-comment-topic="passengerdefaultgroup" data-anchor="PassengerDefaultGroup">6.14.5. PassengerDefaultGroup <group name></h4>
|
3405
3605
|
<div class="paragraph"><p>Phusion Passenger enables <a href="#user_switching">user switching support</a> by default.
|
3406
3606
|
This configuration option allows one to specify the group that applications must
|
3407
3607
|
run as, if user switching fails or is disabled.</p></div>
|
@@ -3410,7 +3610,7 @@ The default value is the primary group of the user specifified by
|
|
3410
3610
|
<a href="#PassengerDefaultUser">PassengerDefaultUser</a>.</p></div>
|
3411
3611
|
</div>
|
3412
3612
|
<div class="sect3">
|
3413
|
-
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="_passengerfriendlyerrorpages_lt_on_off_gt"></span><h4 data-comment-topic="passengerfriendlyerrorpages" data-anchor="_passengerfriendlyerrorpages_lt_on_off_gt">6.
|
3613
|
+
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="_passengerfriendlyerrorpages_lt_on_off_gt"></span><h4 data-comment-topic="passengerfriendlyerrorpages" data-anchor="_passengerfriendlyerrorpages_lt_on_off_gt">6.14.6. PassengerFriendlyErrorPages <on|off></h4>
|
3414
3614
|
<div class="paragraph"><p>Phusion Passenger can display friendly error pages whenever an application fails
|
3415
3615
|
to start. This friendly error page presents the startup error message, some
|
3416
3616
|
suggestions for solving the problem, and a backtrace. This feature is very useful
|
@@ -3445,36 +3645,19 @@ In <em>.htaccess</em>, if <span class="monospaced">AllowOverride Options</span>
|
|
3445
3645
|
</div>
|
3446
3646
|
</div>
|
3447
3647
|
<div class="sect2">
|
3448
|
-
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="_resource_control_and_optimization_options"></span><h3 data-comment-topic="resource-control-and-optimization-options-zu2f7u" data-anchor="_resource_control_and_optimization_options">6.
|
3648
|
+
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="_resource_control_and_optimization_options"></span><h3 data-comment-topic="resource-control-and-optimization-options-zu2f7u" data-anchor="_resource_control_and_optimization_options">6.15. Resource control and optimization options</h3>
|
3449
3649
|
<div class="sect3">
|
3450
|
-
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="_passengermaxpoolsize_lt_integer_gt"></span><h4 data-comment-topic="passengermaxpoolsize-integer--am64q8" data-anchor="_passengermaxpoolsize_lt_integer_gt">6.
|
3650
|
+
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="_passengermaxpoolsize_lt_integer_gt"></span><h4 data-comment-topic="passengermaxpoolsize-integer--am64q8" data-anchor="_passengermaxpoolsize_lt_integer_gt">6.15.1. PassengerMaxPoolSize <integer></h4>
|
3451
3651
|
<div class="paragraph"><p>The maximum number of <a href="#application_process">application processes</a> that may
|
3452
3652
|
simultaneously exist. A larger number results in higher memory usage,
|
3453
|
-
but
|
3454
|
-
<div class="paragraph"><p>The optimal value depends on your system’s hardware and the
|
3455
|
-
|
3456
|
-
the value should be at least equal to the number of CPUs (or CPU cores) that
|
3457
|
-
you have. If your system has 2 GB of RAM, then we recommend a value of <em>15</em>.
|
3458
|
-
If your system is a Virtual Private Server (VPS) and has about 256 MB RAM, and
|
3459
|
-
is also running other services such as MySQL, then we recommend a value of <em>2</em>.</p></div>
|
3460
|
-
<div class="paragraph"><p>If you find that your server is unable to handle the load on your Rails/Rack websites
|
3461
|
-
(i.e. running out of memory) then you should lower this value. (Though if your
|
3462
|
-
sites are really that popular, then you should strongly consider upgrading your
|
3463
|
-
hardware or getting more servers.)</p></div>
|
3653
|
+
but improves the ability to handle concurrent HTTP requests.</p></div>
|
3654
|
+
<div class="paragraph"><p>The optimal value depends on your system’s hardware and your workload. You can learn more at the Phusion article <a href="http://blog.phusion.nl/2013/03/12/tuning-phusion-passengers-concurrency-settings/">Tuning Phusion Passenger’s conurrency settings</a>.</p></div>
|
3655
|
+
<div class="paragraph"><p>If you find that your server is running out of memory then you should lower this value.</p></div>
|
3464
3656
|
<div class="paragraph"><p>This option may only occur once, in the global server configuration.
|
3465
3657
|
The default value is <em>6</em>.</p></div>
|
3466
|
-
<div class="admonitionblock">
|
3467
|
-
<table><tr>
|
3468
|
-
<td class="icon">
|
3469
|
-
<img src="./images/icons/tip.png" alt="Tip">
|
3470
|
-
</td>
|
3471
|
-
<td class="content">We strongly recommend you to <a href="#reducing_memory_usage">use Ruby Enterprise Edition</a>. This allows you to reduce the memory usage of your Ruby on Rails applications
|
3472
|
-
by about 33%, and it’s not hard to install.</td>
|
3473
|
-
</tr></table>
|
3474
|
-
</div>
|
3475
3658
|
</div>
|
3476
3659
|
<div class="sect3">
|
3477
|
-
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="PassengerMinInstances"></span><h4 data-comment-topic="passengermininstances-integer--wegq6b" data-anchor="PassengerMinInstances">6.
|
3660
|
+
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="PassengerMinInstances"></span><h4 data-comment-topic="passengermininstances-integer--wegq6b" data-anchor="PassengerMinInstances">6.15.2. PassengerMinInstances <integer></h4>
|
3478
3661
|
<div class="paragraph"><p>This specifies the minimum number of application processes that should exist for a
|
3479
3662
|
given application. You should set this option to a
|
3480
3663
|
non-zero value if you want to avoid potentially long startup times after a website
|
@@ -3545,7 +3728,7 @@ In <em>.htaccess</em>, if <span class="monospaced">AllowOverride Limits</span> i
|
|
3545
3728
|
<div class="paragraph"><p>In each place, it may be specified at most once. The default value is <em>1</em>.</p></div>
|
3546
3729
|
</div>
|
3547
3730
|
<div class="sect3">
|
3548
|
-
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="_passengermaxinstances_lt_integer_gt"></span><h4 data-comment-topic="passengermaxinstances" data-anchor="_passengermaxinstances_lt_integer_gt">6.
|
3731
|
+
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="_passengermaxinstances_lt_integer_gt"></span><h4 data-comment-topic="passengermaxinstances" data-anchor="_passengermaxinstances_lt_integer_gt">6.15.3. PassengerMaxInstances <integer></h4>
|
3549
3732
|
<div class="paragraph"><p><strong>This feature is only available in <a href="https://www.phusionpassenger.com/enterprise">Phusion Passenger Enterprise</a>. It was introduced in version 3.0.0. <a href="https://www.phusionpassenger.com/download">Buy Phusion Passenger Enterprise here.</a></strong></p></div>
|
3550
3733
|
<div class="paragraph"><p>The maximum number of application processes that may simultaneously exist
|
3551
3734
|
for an application. This helps to make sure that a single application
|
@@ -3586,7 +3769,7 @@ on the other hand will be free to spawn up to 10 processes if it gets a lot of t
|
|
3586
3769
|
</div>
|
3587
3770
|
</div>
|
3588
3771
|
<div class="sect3">
|
3589
|
-
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="_passengermaxinstancesperapp_lt_integer_gt"></span><h4 data-comment-topic="passengermaxinstancesperapp" data-anchor="_passengermaxinstancesperapp_lt_integer_gt">6.
|
3772
|
+
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="_passengermaxinstancesperapp_lt_integer_gt"></span><h4 data-comment-topic="passengermaxinstancesperapp" data-anchor="_passengermaxinstancesperapp_lt_integer_gt">6.15.4. PassengerMaxInstancesPerApp <integer></h4>
|
3590
3773
|
<div class="paragraph"><p>The maximum number of application processes that may simultaneously exist
|
3591
3774
|
for a single application. This helps to make sure that a single application
|
3592
3775
|
will not occupy all available slots in the application pool.</p></div>
|
@@ -3639,7 +3822,7 @@ the pool unequally, according to each web application’s relative importance.</
|
|
3639
3822
|
</div>
|
3640
3823
|
</div>
|
3641
3824
|
<div class="sect3">
|
3642
|
-
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="PassengerPoolIdleTime"></span><h4 data-comment-topic="passengerpoolidletime-integer--a3gunq" data-anchor="PassengerPoolIdleTime">6.
|
3825
|
+
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="PassengerPoolIdleTime"></span><h4 data-comment-topic="passengerpoolidletime-integer--a3gunq" data-anchor="PassengerPoolIdleTime">6.15.5. PassengerPoolIdleTime <integer></h4>
|
3643
3826
|
<div class="paragraph"><p>The maximum number of seconds that an application process may be idle. That is,
|
3644
3827
|
if an application process hasn’t received any traffic after the given number of
|
3645
3828
|
seconds, then it will be shutdown in order to conserve memory.</p></div>
|
@@ -3661,7 +3844,7 @@ applications, each which must be available at all times.</p></div>
|
|
3661
3844
|
The default value is <em>300</em>.</p></div>
|
3662
3845
|
</div>
|
3663
3846
|
<div class="sect3">
|
3664
|
-
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="_passengermaxpreloaderidletime_lt_integer_gt"></span><h4 data-comment-topic="railsappspawneridletime-integer--1awgog1" data-anchor="_passengermaxpreloaderidletime_lt_integer_gt">6.
|
3847
|
+
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="_passengermaxpreloaderidletime_lt_integer_gt"></span><h4 data-comment-topic="railsappspawneridletime-integer--1awgog1" data-anchor="_passengermaxpreloaderidletime_lt_integer_gt">6.15.6. PassengerMaxPreloaderIdleTime <integer></h4>
|
3665
3848
|
<div class="paragraph"><p>The ApplicationSpawner server (explained in <a href="#spawning_methods_explained">Spawning methods explained</a>) has an idle timeout, just like the backend processes spawned by
|
3666
3849
|
Phusion Passenger do. That is, it will automatically shutdown if it hasn’t done
|
3667
3850
|
anything for a given period.</p></div>
|
@@ -3690,7 +3873,7 @@ In a virtual host configuration block.
|
|
3690
3873
|
<div class="paragraph"><p>In each place, it may be specified at most once. The default value is <em>300</em> (5 minutes).</p></div>
|
3691
3874
|
</div>
|
3692
3875
|
<div class="sect3">
|
3693
|
-
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="PassengerConcurrencyModel"></span><h4 data-comment-topic="passengerconcurrencymodel-process-thread--1eipofj" data-anchor="PassengerConcurrencyModel">6.
|
3876
|
+
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="PassengerConcurrencyModel"></span><h4 data-comment-topic="passengerconcurrencymodel-process-thread--1eipofj" data-anchor="PassengerConcurrencyModel">6.15.7. PassengerConcurrencyModel <process|thread></h4>
|
3694
3877
|
<div class="paragraph"><p><strong>This feature is only available in <a href="https://www.phusionpassenger.com/enterprise">Phusion Passenger Enterprise</a>. It was introduced in version 4.0.0. <a href="https://www.phusionpassenger.com/download">Buy Phusion Passenger Enterprise here.</a></strong></p></div>
|
3695
3878
|
<div class="paragraph"><p>Specifies the I/O concurrency model that should be used for application processes. Phusion Passenger supports two concurrency models:</p></div>
|
3696
3879
|
<div class="ulist"><ul>
|
@@ -3731,7 +3914,7 @@ In <em>.htaccess</em>.
|
|
3731
3914
|
<div class="paragraph"><p>In each place, it may be specified at most once. The default value is <em>process</em>.</p></div>
|
3732
3915
|
</div>
|
3733
3916
|
<div class="sect3">
|
3734
|
-
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="PassengerThreadCount"></span><h4 data-comment-topic="passengerthreadcount-number--10jl64a" data-anchor="PassengerThreadCount">6.
|
3917
|
+
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="PassengerThreadCount"></span><h4 data-comment-topic="passengerthreadcount-number--10jl64a" data-anchor="PassengerThreadCount">6.15.8. PassengerThreadCount <number></h4>
|
3735
3918
|
<div class="paragraph"><p><strong>This feature is only available in <a href="https://www.phusionpassenger.com/enterprise">Phusion Passenger Enterprise</a>. It was introduced in version 4.0.0. <a href="https://www.phusionpassenger.com/download">Buy Phusion Passenger Enterprise here.</a></strong></p></div>
|
3736
3919
|
<div class="paragraph"><p>Specifies the number of threads that Phusion Passenger should spawn per application process. This option only has effect if <a href="#PassengerConcurrencyModel">PassengerConcurrencyModel</a> is <em>thread</em>.</p></div>
|
3737
3920
|
<div class="paragraph"><p>This option may occur in the following places:</p></div>
|
@@ -3760,7 +3943,7 @@ In <em>.htaccess</em>.
|
|
3760
3943
|
<div class="paragraph"><p>In each place, it may be specified at most once. The default value is <em>1</em>.</p></div>
|
3761
3944
|
</div>
|
3762
3945
|
<div class="sect3">
|
3763
|
-
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="PassengerMaxRequests"></span><h4 data-comment-topic="passengermaxrequests-integer--17qkw9n" data-anchor="PassengerMaxRequests">6.
|
3946
|
+
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="PassengerMaxRequests"></span><h4 data-comment-topic="passengermaxrequests-integer--17qkw9n" data-anchor="PassengerMaxRequests">6.15.9. PassengerMaxRequests <integer></h4>
|
3764
3947
|
<div class="paragraph"><p>The maximum number of requests an application process will process. After
|
3765
3948
|
serving that many requests, the application process will be shut down and
|
3766
3949
|
Phusion Passenger will restart it. A value of 0 means that there is no maximum:
|
@@ -3808,7 +3991,7 @@ measure to avoid memory leaks.</p></div>
|
|
3808
3991
|
</div>
|
3809
3992
|
</div>
|
3810
3993
|
<div class="sect3">
|
3811
|
-
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="PassengerMaxRequestTime"></span><h4 data-comment-topic="passengermaxrequesttime-seconds--127v1i2" data-anchor="PassengerMaxRequestTime">6.
|
3994
|
+
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="PassengerMaxRequestTime"></span><h4 data-comment-topic="passengermaxrequesttime-seconds--127v1i2" data-anchor="PassengerMaxRequestTime">6.15.10. PassengerMaxRequestTime <seconds></h4>
|
3812
3995
|
<div class="paragraph"><p><strong>This feature is only available in <a href="https://www.phusionpassenger.com/enterprise">Phusion Passenger Enterprise</a>. It was introduced in version 3.0.0. <a href="https://www.phusionpassenger.com/download">Buy Phusion Passenger Enterprise here.</a></strong></p></div>
|
3813
3996
|
<div class="paragraph"><p>The maximum amount of time, in seconds, that an application process may take
|
3814
3997
|
to process a request. If the request takes longer than this amount of time,
|
@@ -3877,7 +4060,7 @@ measure to avoid freezing applications.</p></div>
|
|
3877
4060
|
</div>
|
3878
4061
|
</div>
|
3879
4062
|
<div class="sect3">
|
3880
|
-
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="PassengerMemoryLimit"></span><h4 data-comment-topic="passengermemorylimit-integer--18irza1" data-anchor="PassengerMemoryLimit">6.
|
4063
|
+
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="PassengerMemoryLimit"></span><h4 data-comment-topic="passengermemorylimit-integer--18irza1" data-anchor="PassengerMemoryLimit">6.15.11. PassengerMemoryLimit <integer></h4>
|
3881
4064
|
<div class="paragraph"><p><strong>This feature is only available in <a href="https://www.phusionpassenger.com/enterprise">Phusion Passenger Enterprise</a>. It was introduced in version 3.0.0. <a href="https://www.phusionpassenger.com/download">Buy Phusion Passenger Enterprise here.</a></strong></p></div>
|
3882
4065
|
<div class="paragraph"><p>The maximum amount of memory that an application process may use, in megabytes.
|
3883
4066
|
Once an application process has surpassed its memory limit, it will process
|
@@ -3942,7 +4125,7 @@ measure to avoid memory leaks.</p></div>
|
|
3942
4125
|
</div>
|
3943
4126
|
</div>
|
3944
4127
|
<div class="sect3">
|
3945
|
-
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="_passengerstatthrottlerate_lt_integer_gt"></span><h4 data-comment-topic="passengerstatthrottlerate-integer--1dcfda3" data-anchor="_passengerstatthrottlerate_lt_integer_gt">6.
|
4128
|
+
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="_passengerstatthrottlerate_lt_integer_gt"></span><h4 data-comment-topic="passengerstatthrottlerate-integer--1dcfda3" data-anchor="_passengerstatthrottlerate_lt_integer_gt">6.15.12. PassengerStatThrottleRate <integer></h4>
|
3946
4129
|
<div class="paragraph"><p>By default, Phusion Passenger performs several filesystem checks (or, in
|
3947
4130
|
programmers jargon, <em>stat() calls</em>) each time a request is processed:</p></div>
|
3948
4131
|
<div class="ulist"><ul>
|
@@ -3994,7 +4177,7 @@ In <em>.htaccess</em>, if <span class="monospaced">AllowOverride Limits</span> i
|
|
3994
4177
|
<div class="paragraph"><p>In each place, it may be specified at most once. The default value is <em>0</em>.</p></div>
|
3995
4178
|
</div>
|
3996
4179
|
<div class="sect3">
|
3997
|
-
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="PassengerPreStart"></span><h4 data-comment-topic="passengerprestart-url--1utb57k" data-anchor="PassengerPreStart">6.
|
4180
|
+
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="PassengerPreStart"></span><h4 data-comment-topic="passengerprestart-url--1utb57k" data-anchor="PassengerPreStart">6.15.13. PassengerPreStart <url></h4>
|
3998
4181
|
<div class="paragraph"><p>By default, Phusion Passenger does not start any application processes until said
|
3999
4182
|
web application is first accessed. The result is that the first visitor of said
|
4000
4183
|
web application might experience a small delay as Phusion Passenger is starting
|
@@ -4232,7 +4415,7 @@ the request ending up at a different web server in the cluster.</p></div>
|
|
4232
4415
|
</div>
|
4233
4416
|
</div>
|
4234
4417
|
<div class="sect3">
|
4235
|
-
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="PassengerHighPerformance"></span><h4 data-comment-topic="passengerhighperformance-on-off--nvfa86" data-anchor="PassengerHighPerformance">6.
|
4418
|
+
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="PassengerHighPerformance"></span><h4 data-comment-topic="passengerhighperformance-on-off--nvfa86" data-anchor="PassengerHighPerformance">6.15.14. PassengerHighPerformance <on|off></h4>
|
4236
4419
|
<div class="paragraph"><p>By default, Phusion Passenger is compatible with mod_rewrite and most other
|
4237
4420
|
Apache modules. However, a lot of effort is required in order to be compatible.
|
4238
4421
|
If you turn <em>PassengerHighPerformance</em> to <em>on</em>, then Phusion Passenger will be
|
@@ -4316,9 +4499,9 @@ then you can enable high performance mode for a certain URL only. For example:</
|
|
4316
4499
|
</div>
|
4317
4500
|
</div>
|
4318
4501
|
<div class="sect2">
|
4319
|
-
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="_compatibility_options"></span><h3 data-comment-topic="compatibility-options-8jve5a" data-anchor="_compatibility_options">6.
|
4502
|
+
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="_compatibility_options"></span><h3 data-comment-topic="compatibility-options-8jve5a" data-anchor="_compatibility_options">6.16. Compatibility options</h3>
|
4320
4503
|
<div class="sect3">
|
4321
|
-
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="PassengerResolveSymlinksInDocumentRoot"></span><h4 data-comment-topic="passengerresolvesymlinksindocumentroot-on-off--1r0qcp8" data-anchor="PassengerResolveSymlinksInDocumentRoot">6.
|
4504
|
+
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="PassengerResolveSymlinksInDocumentRoot"></span><h4 data-comment-topic="passengerresolvesymlinksindocumentroot-on-off--1r0qcp8" data-anchor="PassengerResolveSymlinksInDocumentRoot">6.16.1. PassengerResolveSymlinksInDocumentRoot <on|off></h4>
|
4322
4505
|
<div class="paragraph"><p>Configures whether Phusion Passenger should resolve symlinks in the document root.
|
4323
4506
|
Please refer to <a href="#application_detection">How Phusion Passenger detects whether a virtual host is a web application</a> for more information.</p></div>
|
4324
4507
|
<div class="paragraph"><p>This option may occur in the following places:</p></div>
|
@@ -4347,7 +4530,7 @@ In <em>.htaccess</em>, if <span class="monospaced">AllowOverride Options</span>
|
|
4347
4530
|
<div class="paragraph"><p>In each place, it may be specified at most once. It is off by default.</p></div>
|
4348
4531
|
</div>
|
4349
4532
|
<div class="sect3">
|
4350
|
-
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="_passengerallowencodedslashes_lt_on_off_gt"></span><h4 data-comment-topic="passengerallowencodedslashes-on-off--1y3s1ww" data-anchor="_passengerallowencodedslashes_lt_on_off_gt">6.
|
4533
|
+
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="_passengerallowencodedslashes_lt_on_off_gt"></span><h4 data-comment-topic="passengerallowencodedslashes-on-off--1y3s1ww" data-anchor="_passengerallowencodedslashes_lt_on_off_gt">6.16.2. PassengerAllowEncodedSlashes <on|off></h4>
|
4351
4534
|
<div class="paragraph"><p>By default, Apache doesn’t support URLs with encoded slashes (%2f), e.g. URLs like
|
4352
4535
|
this: <span class="monospaced">/users/fujikura%2fyuu</span>. If you access such an URL then Apache will return a
|
4353
4536
|
404 Not Found error. This can be solved by turning on PassengerAllowEncodedSlashes
|
@@ -4416,9 +4599,9 @@ displaying maintenance.html will work fine even for URLs starting with "/users".
|
|
4416
4599
|
</div>
|
4417
4600
|
</div>
|
4418
4601
|
<div class="sect2">
|
4419
|
-
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="_logging_and_debugging_options"></span><h3 data-comment-topic="logging-and-debugging-options-el2cuc" data-anchor="_logging_and_debugging_options">6.
|
4602
|
+
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="_logging_and_debugging_options"></span><h3 data-comment-topic="logging-and-debugging-options-el2cuc" data-anchor="_logging_and_debugging_options">6.17. Logging and debugging options</h3>
|
4420
4603
|
<div class="sect3">
|
4421
|
-
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="_passengerloglevel_lt_integer_gt"></span><h4 data-comment-topic="passengerloglevel-integer--s3kbil" data-anchor="_passengerloglevel_lt_integer_gt">6.
|
4604
|
+
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="_passengerloglevel_lt_integer_gt"></span><h4 data-comment-topic="passengerloglevel-integer--s3kbil" data-anchor="_passengerloglevel_lt_integer_gt">6.17.1. PassengerLogLevel <integer></h4>
|
4422
4605
|
<div class="paragraph"><p>This option allows one to specify how much information Phusion Passenger should
|
4423
4606
|
write to the Apache error log file. A higher log level value means that more
|
4424
4607
|
information will be logged.</p></div>
|
@@ -4451,14 +4634,14 @@ information will be logged.</p></div>
|
|
4451
4634
|
The default is <em>0</em>.</p></div>
|
4452
4635
|
</div>
|
4453
4636
|
<div class="sect3">
|
4454
|
-
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="_passengerdebuglogfile_lt_filename_gt"></span><h4 data-comment-topic="passengerdebuglogfile-filename--1wjm2j1" data-anchor="_passengerdebuglogfile_lt_filename_gt">6.
|
4637
|
+
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="_passengerdebuglogfile_lt_filename_gt"></span><h4 data-comment-topic="passengerdebuglogfile-filename--1wjm2j1" data-anchor="_passengerdebuglogfile_lt_filename_gt">6.17.2. PassengerDebugLogFile <filename></h4>
|
4455
4638
|
<div class="paragraph"><p>By default Phusion Passenger debugging and error messages are written to the global
|
4456
4639
|
web server error log. This option allows one to specify the file that debugging and
|
4457
4640
|
error messages should be written to instead.</p></div>
|
4458
4641
|
<div class="paragraph"><p>This option may only occur once, in the global server configuration.</p></div>
|
4459
4642
|
</div>
|
4460
4643
|
<div class="sect3">
|
4461
|
-
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="_passengerdebugger_lt_on_off_gt"></span><h4 data-comment-topic="passengerdebugger-on-off--19you7e" data-anchor="_passengerdebugger_lt_on_off_gt">6.
|
4644
|
+
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="_passengerdebugger_lt_on_off_gt"></span><h4 data-comment-topic="passengerdebugger-on-off--19you7e" data-anchor="_passengerdebugger_lt_on_off_gt">6.17.3. PassengerDebugger <on|off></h4>
|
4462
4645
|
<div class="paragraph"><p><strong>This feature is only available in <a href="https://www.phusionpassenger.com/enterprise">Phusion Passenger Enterprise</a>. It was introduced in version 3.0.0. <a href="https://www.phusionpassenger.com/download">Buy Phusion Passenger Enterprise here.</a></strong></p></div>
|
4463
4646
|
<div class="paragraph"><p>Turns support for application debugging on or off. In case of Ruby applications,
|
4464
4647
|
turning this option on will cause them to load the <span class="monospaced">ruby-debug</span> gem (when on Ruby 1.8)
|
@@ -4498,11 +4681,11 @@ In <em>.htaccess</em>, if <span class="monospaced">AllowOverride Options</span>
|
|
4498
4681
|
</div>
|
4499
4682
|
</div>
|
4500
4683
|
<div class="sect2">
|
4501
|
-
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="_classic_ruby_on_rails_8656_2_x_specific_options"></span><h3 data-comment-topic="ruby-on-rails-specific-options-1t10wfu" data-anchor="_classic_ruby_on_rails_8656_2_x_specific_options">6.
|
4684
|
+
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="_classic_ruby_on_rails_8656_2_x_specific_options"></span><h3 data-comment-topic="ruby-on-rails-specific-options-1t10wfu" data-anchor="_classic_ruby_on_rails_8656_2_x_specific_options">6.18. Classic Ruby on Rails (⇐ 2.x)-specific options</h3>
|
4502
4685
|
<div class="paragraph"><p>These options only have effect on classic Ruby on Rails 1.x and 2.x applications.
|
4503
4686
|
Ruby on Rails >= 3.x applications are considered Rack applications.</p></div>
|
4504
4687
|
<div class="sect3">
|
4505
|
-
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="RailsBaseURI"></span><h4 data-comment-topic="railsbaseuri-uri--1txrw3k" data-anchor="RailsBaseURI">6.
|
4688
|
+
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="RailsBaseURI"></span><h4 data-comment-topic="railsbaseuri-uri--1txrw3k" data-anchor="RailsBaseURI">6.18.1. RailsBaseURI <uri></h4>
|
4506
4689
|
<div class="paragraph"><p>Used to specify that the given URI is a Rails application. See
|
4507
4690
|
<a href="#deploying_rails_to_sub_uri">Deploying Rails to a sub URI</a> for an example.</p></div>
|
4508
4691
|
<div class="paragraph"><p>It is allowed to specify this option multiple times. Do this to deploy multiple
|
@@ -4532,7 +4715,7 @@ In <em>.htaccess</em>, if <span class="monospaced">AllowOverride Options</span>
|
|
4532
4715
|
</ul></div>
|
4533
4716
|
</div>
|
4534
4717
|
<div class="sect3">
|
4535
|
-
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="rails_env"></span><h4 data-comment-topic="railsenv-string--1b0xxvu" data-anchor="rails_env">6.
|
4718
|
+
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="rails_env"></span><h4 data-comment-topic="railsenv-string--1b0xxvu" data-anchor="rails_env">6.18.2. RailsEnv <string></h4>
|
4536
4719
|
<div class="paragraph"><p>This option allows one to specify the default <span class="monospaced">RAILS_ENV</span> value.</p></div>
|
4537
4720
|
<div class="paragraph"><p>This option may occur in the following places:</p></div>
|
4538
4721
|
<div class="ulist"><ul>
|
@@ -4561,9 +4744,9 @@ In <em>.htaccess</em>, if <span class="monospaced">AllowOverride Options</span>
|
|
4561
4744
|
</div>
|
4562
4745
|
</div>
|
4563
4746
|
<div class="sect2">
|
4564
|
-
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="_rack_and_rails_gt_3_specific_options"></span><h3 data-comment-topic="rack-specific-options-wk9qzt" data-anchor="_rack_and_rails_gt_3_specific_options">6.
|
4747
|
+
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="_rack_and_rails_gt_3_specific_options"></span><h3 data-comment-topic="rack-specific-options-wk9qzt" data-anchor="_rack_and_rails_gt_3_specific_options">6.19. Rack and Rails >= 3 specific options</h3>
|
4565
4748
|
<div class="sect3">
|
4566
|
-
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="RackBaseURI"></span><h4 data-comment-topic="rackbaseuri-uri--1to24pj" data-anchor="RackBaseURI">6.
|
4749
|
+
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="RackBaseURI"></span><h4 data-comment-topic="rackbaseuri-uri--1to24pj" data-anchor="RackBaseURI">6.19.1. RackBaseURI <uri></h4>
|
4567
4750
|
<div class="paragraph"><p>Used to specify that the given URI is a Rack application. See
|
4568
4751
|
<a href="#deploying_rack_to_sub_uri">Deploying Rack to a sub URI</a> for an example.</p></div>
|
4569
4752
|
<div class="paragraph"><p>It is allowed to specify this option multiple times. Do this to deploy multiple
|
@@ -4593,7 +4776,7 @@ In <em>.htaccess</em>, if <span class="monospaced">AllowOverride Options</span>
|
|
4593
4776
|
</ul></div>
|
4594
4777
|
</div>
|
4595
4778
|
<div class="sect3">
|
4596
|
-
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="rack_env"></span><h4 data-comment-topic="rackenv-string--vve9py" data-anchor="rack_env">6.
|
4779
|
+
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="rack_env"></span><h4 data-comment-topic="rackenv-string--vve9py" data-anchor="rack_env">6.19.2. RackEnv <string></h4>
|
4597
4780
|
<div class="paragraph"><p>The given value will be accessible in Rack applications in the <span class="monospaced">RACK_ENV</span>
|
4598
4781
|
environment variable. This allows one to define the environment in which
|
4599
4782
|
Rack applications are run, very similar to <span class="monospaced">RAILS_ENV</span>.</p></div>
|
@@ -4624,31 +4807,31 @@ In <em>.htaccess</em>, if <span class="monospaced">AllowOverride Options</span>
|
|
4624
4807
|
</div>
|
4625
4808
|
</div>
|
4626
4809
|
<div class="sect2">
|
4627
|
-
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="_deprecated_or_removed_options"></span><h3 data-comment-topic="deprecated-options-pm9m57" data-anchor="_deprecated_or_removed_options">6.
|
4810
|
+
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="_deprecated_or_removed_options"></span><h3 data-comment-topic="deprecated-options-pm9m57" data-anchor="_deprecated_or_removed_options">6.20. Deprecated or removed options</h3>
|
4628
4811
|
<div class="paragraph"><p>The following options have been deprecated, but are still supported for backwards
|
4629
4812
|
compatibility reasons.</p></div>
|
4630
4813
|
<div class="sect3">
|
4631
|
-
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="_railsruby"></span><h4 data-comment-topic="railsruby-ht09ei" data-anchor="_railsruby">6.
|
4814
|
+
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="_railsruby"></span><h4 data-comment-topic="railsruby-ht09ei" data-anchor="_railsruby">6.20.1. RailsRuby</h4>
|
4632
4815
|
<div class="paragraph"><p>Deprecated in favor of <a href="#PassengerRuby">PassengerRuby</a>.</p></div>
|
4633
4816
|
</div>
|
4634
4817
|
<div class="sect3">
|
4635
|
-
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="_railsuserswitching"></span><h4 data-comment-topic="railsuserswitching-1npx8y4" data-anchor="_railsuserswitching">6.
|
4818
|
+
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="_railsuserswitching"></span><h4 data-comment-topic="railsuserswitching-1npx8y4" data-anchor="_railsuserswitching">6.20.2. RailsUserSwitching</h4>
|
4636
4819
|
<div class="paragraph"><p>Deprecated in favor of <a href="#PassengerUserSwitching">PassengerUserSwitching</a>.</p></div>
|
4637
4820
|
</div>
|
4638
4821
|
<div class="sect3">
|
4639
|
-
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="_railsdefaultuser"></span><h4 data-comment-topic="railsdefaultuser-19j7n3m" data-anchor="_railsdefaultuser">6.
|
4822
|
+
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="_railsdefaultuser"></span><h4 data-comment-topic="railsdefaultuser-19j7n3m" data-anchor="_railsdefaultuser">6.20.3. RailsDefaultUser</h4>
|
4640
4823
|
<div class="paragraph"><p>Deprecated in favor of <a href="#PassengerDefaultUser">PassengerDefaultUser</a>.</p></div>
|
4641
4824
|
</div>
|
4642
4825
|
<div class="sect3">
|
4643
|
-
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="_railsallowmodrewrite"></span><h4 data-comment-topic="railsallowmodrewrite-1vkziro" data-anchor="_railsallowmodrewrite">6.
|
4826
|
+
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="_railsallowmodrewrite"></span><h4 data-comment-topic="railsallowmodrewrite-1vkziro" data-anchor="_railsallowmodrewrite">6.20.4. RailsAllowModRewrite</h4>
|
4644
4827
|
<div class="paragraph"><p>This option doesn’t do anything anymore in recent versions of Phusion Passenger.</p></div>
|
4645
4828
|
</div>
|
4646
4829
|
<div class="sect3">
|
4647
|
-
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="_railsspawnmethod"></span><h4 data-comment-topic="railsspawnmethod-1aljgpa" data-anchor="_railsspawnmethod">6.
|
4830
|
+
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="_railsspawnmethod"></span><h4 data-comment-topic="railsspawnmethod-1aljgpa" data-anchor="_railsspawnmethod">6.20.5. RailsSpawnMethod</h4>
|
4648
4831
|
<div class="paragraph"><p>Deprecated in favor of <a href="#PassengerSpawnMethod">PassengerSpawnMethod</a>.</p></div>
|
4649
4832
|
</div>
|
4650
4833
|
<div class="sect3">
|
4651
|
-
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="_railsautodetect_rackautodetect_and_wsgiautodetect"></span><h4 data-comment-topic="railsautodetect-rackautodetect-and-wsgiautodetect-1qgakzs" data-anchor="_railsautodetect_rackautodetect_and_wsgiautodetect">6.
|
4834
|
+
<a href="javascript:void(0)" class="comments empty" title="Add a comment"><span class="count"></span></a><span class="anchor_helper" id="_railsautodetect_rackautodetect_and_wsgiautodetect"></span><h4 data-comment-topic="railsautodetect-rackautodetect-and-wsgiautodetect-1qgakzs" data-anchor="_railsautodetect_rackautodetect_and_wsgiautodetect">6.20.6. RailsAutoDetect, RackAutoDetect and WsgiAutoDetect</h4>
|
4652
4835
|
<div class="paragraph"><p>These options have been removed in version 4.0.0 as part of an optimization. You should use <a href="#PassengerEnabled">PassengerEnabled</a> instead.</p></div>
|
4653
4836
|
</div>
|
4654
4837
|
</div>
|
@@ -6234,7 +6417,7 @@ has no effect.</p></div>
|
|
6234
6417
|
<div id="footnotes"><hr></div>
|
6235
6418
|
<div id="footer">
|
6236
6419
|
<div id="footer-text">
|
6237
|
-
Last updated 2013-03-
|
6420
|
+
Last updated 2013-03-26 20:47:37 CET
|
6238
6421
|
</div>
|
6239
6422
|
</div>
|
6240
6423
|
<script>/*! jQuery v1.7.1 jquery.com | jquery.org/license */
|