From: "Bráulio Bhavamitra" <braulio@eita.org.br>
To: Eric Wong <e@80x24.org>
Cc: unicorn-public <unicorn-public@bogomips.org>
Subject: Re: Does the the environment is preserved on USR2?
Date: Fri, 26 Jun 2015 20:38:30 -0300 [thread overview]
Message-ID: <CAJri6_s5esHh1be2thB6S+7ag5nHpSYwwY1hH0vaArPsY=k4iQ@mail.gmail.com> (raw)
In-Reply-To: <20150626231412.GB10361@dcvr.yhbt.net>
On Fri, Jun 26, 2015 at 8:14 PM, Eric Wong <e@80x24.org> wrote:
> Eric Wong <e@80x24.org> wrote:
>> USR2 should not change environment variables besides UNICORN_FD
>> and PWD (if working_directory is used).
>>
>> On most Linux versions, you can check the initial environment of a
>> running process by inspecting the environ file for the process:
>>
>> tr '\0' '\n' < /proc/$PID/environ
>>
>> This may not reflect environment changes after the process is started.
>
> Actually, I noticed this doesn't even reflect ENV changes on
> fork from Ruby (but system("env") displays the correct result
> from a forked process) using Linux 4.0.6
>
>> However, you can use ENV inside Ruby code to check that. Maybe add a
>> private Rack endpoint to show ENV.inspect output to your app to check
>> this...
>
> So use ENV from Ruby instead :)
Thanks Eric, will try this!
prev parent reply other threads:[~2015-06-26 23:39 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-06-26 22:18 Does the the environment is preserved on USR2? Bráulio Bhavamitra
2015-06-26 22:31 ` Eric Wong
2015-06-26 23:14 ` Eric Wong
2015-06-26 23:38 ` Bráulio Bhavamitra [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://yhbt.net/unicorn/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to='CAJri6_s5esHh1be2thB6S+7ag5nHpSYwwY1hH0vaArPsY=k4iQ@mail.gmail.com' \
--to=braulio@eita.org.br \
--cc=e@80x24.org \
--cc=unicorn-public@bogomips.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://yhbt.net/unicorn.git/
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).