passenger 6.0.12 → 6.0.13
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/CHANGELOG +37 -1
- data/bin/passenger-install-nginx-module +1 -1
- data/dev/copy_boost_headers +30 -15
- data/resources/mime.types +1 -0
- data/resources/templates/standalone/server.erb +1 -0
- data/src/agent/Core/ApplicationPool/Group/StateInspection.cpp +1 -0
- data/src/agent/Core/ApplicationPool/Options.h +5 -0
- data/src/agent/Core/Config.h +1 -1
- data/src/agent/Core/Controller/Config.h +5 -2
- data/src/agent/Core/Controller/InitRequest.cpp +2 -0
- data/src/agent/Core/OptionParser.h +4 -0
- data/src/agent/Core/SpawningKit/Config/AutoGeneratedCode.h +7 -0
- data/src/agent/Core/SpawningKit/Config.h +13 -0
- data/src/agent/Core/SpawningKit/Handshake/Prepare.h +4 -0
- data/src/agent/Core/SpawningKit/Spawner.h +1 -0
- data/src/agent/SpawnEnvSetupper/SpawnEnvSetupperMain.cpp +4 -0
- data/src/agent/Watchdog/Config.h +1 -1
- data/src/apache2_module/ConfigGeneral/AutoGeneratedDefinitions.cpp +5 -0
- data/src/apache2_module/ConfigGeneral/AutoGeneratedManifestDefaultsInitialization.cpp +5 -0
- data/src/apache2_module/ConfigGeneral/AutoGeneratedSetterFuncs.cpp +18 -0
- data/src/apache2_module/DirConfig/AutoGeneratedCreateFunction.cpp +3 -0
- data/src/apache2_module/DirConfig/AutoGeneratedHeaderSerialization.cpp +3 -0
- data/src/apache2_module/DirConfig/AutoGeneratedManifestGeneration.cpp +11 -0
- data/src/apache2_module/DirConfig/AutoGeneratedMergeFunction.cpp +7 -0
- data/src/apache2_module/DirConfig/AutoGeneratedStruct.h +17 -0
- data/src/apache2_module/Hooks.cpp +1 -0
- data/src/cxx_supportlib/Constants.h +1 -1
- data/src/cxx_supportlib/vendor-modified/boost/align/align.hpp +19 -0
- data/src/cxx_supportlib/vendor-modified/boost/align/alignment_of.hpp +54 -0
- data/src/cxx_supportlib/vendor-modified/boost/align/alignment_of_forward.hpp +20 -0
- data/src/cxx_supportlib/vendor-modified/boost/align/detail/align_cxx11.hpp +21 -0
- data/src/cxx_supportlib/vendor-modified/boost/align/detail/aligned_alloc.hpp +52 -0
- data/src/cxx_supportlib/vendor-modified/boost/align/detail/alignment_of.hpp +31 -0
- data/src/cxx_supportlib/vendor-modified/boost/align/detail/alignment_of_cxx11.hpp +23 -0
- data/src/cxx_supportlib/vendor-modified/boost/align/detail/element_type.hpp +91 -0
- data/src/cxx_supportlib/vendor-modified/boost/align/detail/integral_constant.hpp +53 -0
- data/src/cxx_supportlib/vendor-modified/boost/align/detail/min_size.hpp +26 -0
- data/src/nginx_module/ConfigGeneral/AutoGeneratedDefinitions.c +8 -0
- data/src/nginx_module/ConfigGeneral/AutoGeneratedManifestDefaultsInitialization.c +6 -0
- data/src/nginx_module/ConfigGeneral/AutoGeneratedSetterFuncs.c +12 -0
- data/src/nginx_module/LocationConfig/AutoGeneratedCreateFunction.c +5 -0
- data/src/nginx_module/LocationConfig/AutoGeneratedHeaderSerialization.c +18 -0
- data/src/nginx_module/LocationConfig/AutoGeneratedManifestGeneration.c +13 -0
- data/src/nginx_module/LocationConfig/AutoGeneratedMergeFunction.c +3 -0
- data/src/nginx_module/LocationConfig/AutoGeneratedStruct.h +4 -0
- data/src/nginx_module/ngx_http_passenger_module.c +1 -0
- data/src/nodejs_supportlib/vendor-copy/winston/lib/winston/common.js +50 -29
- data/src/nodejs_supportlib/vendor-copy/winston/lib/winston/config/cli-config.js +20 -20
- data/src/nodejs_supportlib/vendor-copy/winston/lib/winston/config/npm-config.js +11 -11
- data/src/nodejs_supportlib/vendor-copy/winston/lib/winston/config/syslog-config.js +3 -3
- data/src/nodejs_supportlib/vendor-copy/winston/lib/winston/config.js +8 -2
- data/src/nodejs_supportlib/vendor-copy/winston/lib/winston/container.js +2 -1
- data/src/nodejs_supportlib/vendor-copy/winston/lib/winston/logger.js +174 -146
- data/src/nodejs_supportlib/vendor-copy/winston/lib/winston/transports/console.js +4 -2
- data/src/nodejs_supportlib/vendor-copy/winston/lib/winston/transports/file.js +15 -5
- data/src/nodejs_supportlib/vendor-copy/winston/lib/winston/transports/http.js +14 -4
- data/src/nodejs_supportlib/vendor-copy/winston/lib/winston/transports.js +26 -24
- data/src/nodejs_supportlib/vendor-copy/winston/lib/winston.js +5 -5
- data/src/nodejs_supportlib/vendor-copy/winston/node_modules/async/package.json +4 -13
- data/src/nodejs_supportlib/vendor-copy/winston/node_modules/colors/package.json +19 -33
- data/src/nodejs_supportlib/vendor-copy/winston/node_modules/cycle/package.json +11 -29
- data/src/nodejs_supportlib/vendor-copy/winston/node_modules/eyes/package.json +12 -40
- data/src/nodejs_supportlib/vendor-copy/winston/node_modules/isstream/package.json +3 -12
- data/src/nodejs_supportlib/vendor-copy/winston/node_modules/stack-trace/lib/stack-trace.js +49 -24
- data/src/nodejs_supportlib/vendor-copy/winston/node_modules/stack-trace/package.json +4 -16
- data/src/nodejs_supportlib/vendor-copy/winston/package.json +11 -55
- data/src/ruby_supportlib/phusion_passenger/apache2/config_options.rb +6 -0
- data/src/ruby_supportlib/phusion_passenger/nginx/config_options.rb +6 -0
- data/src/ruby_supportlib/phusion_passenger/platform_info/linux.rb +2 -1
- data/src/ruby_supportlib/phusion_passenger/request_handler/thread_handler.rb +18 -18
- data/src/ruby_supportlib/phusion_passenger/standalone/config_options_list.rb +7 -1
- data/src/ruby_supportlib/phusion_passenger/standalone/start_command/builtin_engine.rb +1 -0
- data/src/ruby_supportlib/phusion_passenger.rb +5 -5
- metadata +12 -7
- data/src/nodejs_supportlib/vendor-copy/winston/lib/winston/transports/daily-rotate-file.js +0 -601
- data/src/nodejs_supportlib/vendor-copy/winston/lib/winston/transports/webhook.js +0 -146
- data/src/nodejs_supportlib/vendor-copy/winston/node_modules/pkginfo/LICENSE +0 -19
- data/src/nodejs_supportlib/vendor-copy/winston/node_modules/pkginfo/lib/pkginfo.js +0 -136
- data/src/nodejs_supportlib/vendor-copy/winston/node_modules/pkginfo/package.json +0 -56
|
@@ -32,7 +32,7 @@ exports.setLevels = function (target, past, current, isDefault) {
|
|
|
32
32
|
}
|
|
33
33
|
|
|
34
34
|
target.levels = current || config.npm.levels;
|
|
35
|
-
if (target.padLevels) {
|
|
35
|
+
if (target.hasOwnProperty('padLevels') && target.padLevels) {
|
|
36
36
|
target.levelLength = exports.longestElement(Object.keys(target.levels));
|
|
37
37
|
}
|
|
38
38
|
|
|
@@ -77,20 +77,15 @@ exports.longestElement = function (xs) {
|
|
|
77
77
|
// i.e. JSON objects that are either literals or objects (no Arrays, etc)
|
|
78
78
|
//
|
|
79
79
|
exports.clone = function (obj) {
|
|
80
|
-
//
|
|
81
|
-
// We only need to clone reference types (Object)
|
|
82
|
-
//
|
|
83
|
-
var copy = {};
|
|
84
|
-
|
|
85
80
|
if (obj instanceof Error) {
|
|
86
81
|
// With potential custom Error objects, this might not be exactly correct,
|
|
87
82
|
// but probably close-enough for purposes of this lib.
|
|
88
|
-
copy =
|
|
83
|
+
var copy = { message: obj.message };
|
|
89
84
|
Object.getOwnPropertyNames(obj).forEach(function (key) {
|
|
90
85
|
copy[key] = obj[key];
|
|
91
86
|
});
|
|
92
87
|
|
|
93
|
-
return copy;
|
|
88
|
+
return cycle.decycle(copy);
|
|
94
89
|
}
|
|
95
90
|
else if (!(obj instanceof Object)) {
|
|
96
91
|
return obj;
|
|
@@ -99,23 +94,34 @@ exports.clone = function (obj) {
|
|
|
99
94
|
return new Date(obj.getTime());
|
|
100
95
|
}
|
|
101
96
|
|
|
97
|
+
return clone(cycle.decycle(obj));
|
|
98
|
+
};
|
|
99
|
+
|
|
100
|
+
function clone(obj) {
|
|
101
|
+
//
|
|
102
|
+
// We only need to clone reference types (Object)
|
|
103
|
+
//
|
|
104
|
+
var copy = Array.isArray(obj) ? [] : {};
|
|
105
|
+
|
|
102
106
|
for (var i in obj) {
|
|
103
|
-
if (
|
|
104
|
-
|
|
105
|
-
}
|
|
106
|
-
else if (obj[i] instanceof Buffer) {
|
|
107
|
+
if (obj.hasOwnProperty(i)) {
|
|
108
|
+
if (Array.isArray(obj[i])) {
|
|
107
109
|
copy[i] = obj[i].slice(0);
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
110
|
+
}
|
|
111
|
+
else if (obj[i] instanceof Buffer) {
|
|
112
|
+
copy[i] = obj[i].slice(0);
|
|
113
|
+
}
|
|
114
|
+
else if (typeof obj[i] != 'function') {
|
|
115
|
+
copy[i] = obj[i] instanceof Object ? exports.clone(obj[i]) : obj[i];
|
|
116
|
+
}
|
|
117
|
+
else if (typeof obj[i] === 'function') {
|
|
118
|
+
copy[i] = obj[i];
|
|
119
|
+
}
|
|
114
120
|
}
|
|
115
121
|
}
|
|
116
122
|
|
|
117
123
|
return copy;
|
|
118
|
-
}
|
|
124
|
+
}
|
|
119
125
|
|
|
120
126
|
//
|
|
121
127
|
// ### function log (options)
|
|
@@ -139,8 +145,8 @@ exports.log = function (options) {
|
|
|
139
145
|
: exports.timestamp,
|
|
140
146
|
timestamp = options.timestamp ? timestampFn() : null,
|
|
141
147
|
showLevel = options.showLevel === undefined ? true : options.showLevel,
|
|
142
|
-
meta = options.meta !== null && options.meta !== undefined
|
|
143
|
-
? exports.clone(
|
|
148
|
+
meta = options.meta !== null && options.meta !== undefined
|
|
149
|
+
? exports.clone(options.meta)
|
|
144
150
|
: options.meta || null,
|
|
145
151
|
output;
|
|
146
152
|
|
|
@@ -214,6 +220,12 @@ exports.log = function (options) {
|
|
|
214
220
|
// Remark: this should really be a call to `util.format`.
|
|
215
221
|
//
|
|
216
222
|
if (typeof options.formatter == 'function') {
|
|
223
|
+
options.meta = meta || options.meta;
|
|
224
|
+
if (options.meta instanceof Error) {
|
|
225
|
+
// Force converting the Error to an plain object now so it
|
|
226
|
+
// will not be messed up by decycle() when cloning options
|
|
227
|
+
options.meta = exports.clone(options.meta);
|
|
228
|
+
}
|
|
217
229
|
return String(options.formatter(exports.clone(options)));
|
|
218
230
|
}
|
|
219
231
|
|
|
@@ -232,10 +244,6 @@ exports.log = function (options) {
|
|
|
232
244
|
: options.message;
|
|
233
245
|
|
|
234
246
|
if (meta !== null && meta !== undefined) {
|
|
235
|
-
if (meta && meta instanceof Error && meta.stack) {
|
|
236
|
-
meta = meta.stack;
|
|
237
|
-
}
|
|
238
|
-
|
|
239
247
|
if (typeof meta !== 'object') {
|
|
240
248
|
output += ' ' + meta;
|
|
241
249
|
}
|
|
@@ -246,7 +254,7 @@ exports.log = function (options) {
|
|
|
246
254
|
output += ' ' + '\n' + util.inspect(meta, false, options.depth || null, options.colorize);
|
|
247
255
|
} else if (
|
|
248
256
|
options.humanReadableUnhandledException
|
|
249
|
-
&& Object.keys(meta).length
|
|
257
|
+
&& Object.keys(meta).length >= 5
|
|
250
258
|
&& meta.hasOwnProperty('date')
|
|
251
259
|
&& meta.hasOwnProperty('process')
|
|
252
260
|
&& meta.hasOwnProperty('os')
|
|
@@ -260,7 +268,10 @@ exports.log = function (options) {
|
|
|
260
268
|
delete meta.stack;
|
|
261
269
|
delete meta.trace;
|
|
262
270
|
output += ' ' + exports.serialize(meta);
|
|
263
|
-
|
|
271
|
+
|
|
272
|
+
if (stack) {
|
|
273
|
+
output += '\n' + stack.join('\n');
|
|
274
|
+
}
|
|
264
275
|
} else {
|
|
265
276
|
output += ' ' + exports.serialize(meta);
|
|
266
277
|
}
|
|
@@ -308,6 +319,14 @@ exports.timestamp = function () {
|
|
|
308
319
|
// logging to non-JSON inputs.
|
|
309
320
|
//
|
|
310
321
|
exports.serialize = function (obj, key) {
|
|
322
|
+
// symbols cannot be directly casted to strings
|
|
323
|
+
if (typeof key === 'symbol') {
|
|
324
|
+
key = key.toString()
|
|
325
|
+
}
|
|
326
|
+
if (typeof obj === 'symbol') {
|
|
327
|
+
obj = obj.toString()
|
|
328
|
+
}
|
|
329
|
+
|
|
311
330
|
if (obj === null) {
|
|
312
331
|
obj = 'null';
|
|
313
332
|
}
|
|
@@ -365,7 +384,7 @@ exports.serialize = function (obj, key) {
|
|
|
365
384
|
// `tail -f` a file. Options must include file.
|
|
366
385
|
//
|
|
367
386
|
exports.tailFile = function(options, callback) {
|
|
368
|
-
var buffer =
|
|
387
|
+
var buffer = Buffer.alloc(64 * 1024)
|
|
369
388
|
, decode = new StringDecoder('utf8')
|
|
370
389
|
, stream = new Stream
|
|
371
390
|
, buff = ''
|
|
@@ -396,7 +415,7 @@ exports.tailFile = function(options, callback) {
|
|
|
396
415
|
|
|
397
416
|
(function read() {
|
|
398
417
|
if (stream.destroyed) {
|
|
399
|
-
fs.close(fd);
|
|
418
|
+
fs.close(fd, nop);
|
|
400
419
|
return;
|
|
401
420
|
}
|
|
402
421
|
|
|
@@ -481,3 +500,5 @@ exports.stringArrayToSet = function (strArray, errMsg) {
|
|
|
481
500
|
return set;
|
|
482
501
|
}, Object.create(null));
|
|
483
502
|
};
|
|
503
|
+
|
|
504
|
+
function nop () {}
|
|
@@ -9,27 +9,27 @@
|
|
|
9
9
|
var cliConfig = exports;
|
|
10
10
|
|
|
11
11
|
cliConfig.levels = {
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
12
|
+
error: 0,
|
|
13
|
+
warn: 1,
|
|
14
|
+
help: 2,
|
|
15
|
+
data: 3,
|
|
16
|
+
info: 4,
|
|
17
|
+
debug: 5,
|
|
18
|
+
prompt: 6,
|
|
19
|
+
verbose: 7,
|
|
20
|
+
input: 8,
|
|
21
|
+
silly: 9,
|
|
22
22
|
};
|
|
23
23
|
|
|
24
24
|
cliConfig.colors = {
|
|
25
|
-
|
|
26
|
-
input: 'grey',
|
|
27
|
-
verbose: 'cyan',
|
|
28
|
-
prompt: 'grey',
|
|
29
|
-
debug: 'blue',
|
|
30
|
-
info: 'green',
|
|
31
|
-
data: 'grey',
|
|
32
|
-
help: 'cyan',
|
|
25
|
+
error: 'red',
|
|
33
26
|
warn: 'yellow',
|
|
34
|
-
|
|
35
|
-
|
|
27
|
+
help: 'cyan',
|
|
28
|
+
data: 'grey',
|
|
29
|
+
info: 'green',
|
|
30
|
+
debug: 'blue',
|
|
31
|
+
prompt: 'grey',
|
|
32
|
+
verbose: 'cyan',
|
|
33
|
+
input: 'grey',
|
|
34
|
+
silly: 'magenta'
|
|
35
|
+
};
|
|
@@ -9,19 +9,19 @@
|
|
|
9
9
|
var npmConfig = exports;
|
|
10
10
|
|
|
11
11
|
npmConfig.levels = {
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
12
|
+
error: 0,
|
|
13
|
+
warn: 1,
|
|
14
|
+
info: 2,
|
|
15
|
+
verbose: 3,
|
|
16
|
+
debug: 4,
|
|
17
|
+
silly: 5
|
|
18
18
|
};
|
|
19
19
|
|
|
20
20
|
npmConfig.colors = {
|
|
21
|
-
|
|
21
|
+
error: 'red',
|
|
22
|
+
warn: 'yellow',
|
|
23
|
+
info: 'green',
|
|
22
24
|
verbose: 'cyan',
|
|
23
25
|
debug: 'blue',
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
error: 'red'
|
|
27
|
-
};
|
|
26
|
+
silly: 'magenta'
|
|
27
|
+
};
|
|
@@ -16,7 +16,7 @@ syslogConfig.levels = {
|
|
|
16
16
|
warning: 4,
|
|
17
17
|
notice: 5,
|
|
18
18
|
info: 6,
|
|
19
|
-
debug: 7
|
|
19
|
+
debug: 7
|
|
20
20
|
};
|
|
21
21
|
|
|
22
22
|
syslogConfig.colors = {
|
|
@@ -27,5 +27,5 @@ syslogConfig.colors = {
|
|
|
27
27
|
warning: 'red',
|
|
28
28
|
notice: 'yellow',
|
|
29
29
|
info: 'green',
|
|
30
|
-
debug: 'blue'
|
|
31
|
-
};
|
|
30
|
+
debug: 'blue'
|
|
31
|
+
};
|
|
@@ -8,6 +8,9 @@
|
|
|
8
8
|
|
|
9
9
|
var colors = require('colors/safe');
|
|
10
10
|
|
|
11
|
+
// Fix colors not appearing in non-tty environments
|
|
12
|
+
colors.enabled = true;
|
|
13
|
+
|
|
11
14
|
var config = exports,
|
|
12
15
|
allColors = exports.allColors = {};
|
|
13
16
|
|
|
@@ -23,15 +26,18 @@ config.colorize = function (level, message) {
|
|
|
23
26
|
for (var i = 0, l = allColors[level].length; i < l; ++i) {
|
|
24
27
|
colorized = colors[allColors[level][i]](colorized);
|
|
25
28
|
}
|
|
26
|
-
}
|
|
29
|
+
}
|
|
30
|
+
else if (allColors[level].match(/\s/)) {
|
|
27
31
|
var colorArr = allColors[level].split(/\s+/);
|
|
28
32
|
for (var i = 0; i < colorArr.length; ++i) {
|
|
29
33
|
colorized = colors[colorArr[i]](colorized);
|
|
30
34
|
}
|
|
31
35
|
allColors[level] = colorArr;
|
|
32
|
-
}
|
|
36
|
+
}
|
|
37
|
+
else {
|
|
33
38
|
colorized = colors[allColors[level]](colorized);
|
|
34
39
|
}
|
|
40
|
+
|
|
35
41
|
return colorized;
|
|
36
42
|
};
|
|
37
43
|
|
|
@@ -58,7 +58,7 @@ Container.prototype.get = Container.prototype.add = function (id, options) {
|
|
|
58
58
|
}
|
|
59
59
|
|
|
60
60
|
Object.keys(options).forEach(function (key) {
|
|
61
|
-
if (key === 'transports') {
|
|
61
|
+
if (key === 'transports' || key === 'filters' || key === 'rewriters') {
|
|
62
62
|
return;
|
|
63
63
|
}
|
|
64
64
|
|
|
@@ -73,6 +73,7 @@ Container.prototype.get = Container.prototype.add = function (id, options) {
|
|
|
73
73
|
options.transports.push(new (winston.transports[name])(namedOptions));
|
|
74
74
|
});
|
|
75
75
|
|
|
76
|
+
options.id = id;
|
|
76
77
|
this.loggers[id] = new winston.Logger(options);
|
|
77
78
|
|
|
78
79
|
this.loggers[id].on('close', function () {
|