Mercurial > hg > nginx-site
comparison xml/en/docs/njs/reference.xml @ 2405:dbf68c949522
Documented the "process" global object.
author | Yaroslav Zhuravlev <yar@nginx.com> |
---|---|
date | Wed, 03 Jul 2019 20:16:49 +0300 |
parents | bde611cbb7ae |
children | 3b7223f9aac8 |
comparison
equal
deleted
inserted
replaced
2404:65961cddec7c | 2405:dbf68c949522 |
---|---|
7 <!DOCTYPE article SYSTEM "../../../../dtd/article.dtd"> | 7 <!DOCTYPE article SYSTEM "../../../../dtd/article.dtd"> |
8 | 8 |
9 <article name="Reference" | 9 <article name="Reference" |
10 link="/en/docs/njs/reference.html" | 10 link="/en/docs/njs/reference.html" |
11 lang="en" | 11 lang="en" |
12 rev="28"> | 12 rev="29"> |
13 | 13 |
14 <section id="summary"> | 14 <section id="summary"> |
15 | 15 |
16 <para> | 16 <para> |
17 <link doc="index.xml">njs</link> provides objects, methods and properties | 17 <link doc="index.xml">njs</link> provides objects, methods and properties |
367 | 367 |
368 </section> | 368 </section> |
369 | 369 |
370 | 370 |
371 <section id="core" name="Core"> | 371 <section id="core" name="Core"> |
372 | |
373 | |
374 <section id="core_global" name="Global"> | |
375 | |
376 | |
377 <section id="process" name="Process"> | |
378 | |
379 <para> | |
380 The <literal>process</literal> object is a global object | |
381 that provides information about the current process | |
382 (<link doc="changes.xml" id="njs0.3.3">0.3.3</link>). | |
383 </para> | |
384 | |
385 | |
386 <para> | |
387 <list type="tag"> | |
388 | |
389 <tag-name id="process_argv"><literal>process.argv</literal></tag-name> | |
390 <tag-desc> | |
391 Returns an array that contains the command line arguments | |
392 passed when the current process was launched. | |
393 </tag-desc> | |
394 | |
395 <tag-name id="process_env"><literal>process.env</literal></tag-name> | |
396 <tag-desc> | |
397 Returns an object containing the user environment. | |
398 <note> | |
399 By default, nginx removes all environment variables inherited | |
400 from its parent process except the TZ variable. | |
401 Use the <link doc="../ngx_core_module.xml" id="env"/> directive | |
402 to preserve some of the inherited variables. | |
403 </note> | |
404 </tag-desc> | |
405 | |
406 <tag-name id="process_pid"><literal>process.pid</literal></tag-name> | |
407 <tag-desc> | |
408 Returns the PID of the current process. | |
409 </tag-desc> | |
410 | |
411 <tag-name id="process_ppid"><literal>process.ppid</literal></tag-name> | |
412 <tag-desc> | |
413 Returns the PID of the current parent process. | |
414 </tag-desc> | |
415 | |
416 </list> | |
417 </para> | |
418 | |
419 </section> | |
420 | |
421 </section> | |
372 | 422 |
373 | 423 |
374 <section id="core_object" name="Object"> | 424 <section id="core_object" name="Object"> |
375 | 425 |
376 <para> | 426 <para> |