php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Request #73477 Environmental Variables
Submitted: 2016-11-08 14:04 UTC Modified: 2021-06-06 04:22 UTC
From: smith_it2000 at yahoo dot com Assigned: cmb (profile)
Status: No Feedback Package: FPM related
PHP Version: 7.0.13RC1 OS: Ubuntu
Private report: No CVE-ID: None
View Add Comment Developer Edit
Anyone can comment on a bug. Have a simpler test case? Does it work for you on a different platform? Let us know!
Just going to say 'Me too!'? Don't clutter the database with that please — but make sure to vote on the bug!
Your email address:
MUST BE VALID
Solve the problem:
11 + 34 = ?
Subscribe to this entry?

 
 [2016-11-08 14:04 UTC] smith_it2000 at yahoo dot com
Description:
------------
Allow the easy programmatic setting of environmental variables for php scripts in FPM.

Such that getenv('var') works.

It could work like this;

Specify a bash or php script in the pool config file, this script is run once when php-fpm starts. The script can be used to set environmental variables that are available to the php script when executed.

Do NOT want to set environmental variables in php-fpm config files. Want the FPM environment to mirror the CLI environment.






Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2021-05-28 11:12 UTC] cmb@php.net
-Status: Open +Status: Feedback -Assigned To: +Assigned To: cmb
 [2021-05-28 11:12 UTC] cmb@php.net
Are you looking for the existing option clear_env[1]?

[1] <https://www.php.net/manual/en/install.fpm.configuration.php>
 [2021-06-06 04:22 UTC] php-bugs at lists dot php dot net
No feedback was provided. The bug is being suspended because
we assume that you are no longer experiencing the problem.
If this is not the case and you are able to provide the
information that was requested earlier, please do so and
change the status of the bug back to "Re-Opened". Thank you.
 
PHP Copyright © 2001-2021 The PHP Group
All rights reserved.
Last updated: Sun Sep 26 11:03:37 2021 UTC