Skip to content

[💡 FEATURE REQUEST]: environment variables in the config #205

Description

@roxblnfk

I have an idea!

Set environment variables for workers in rapira.toml, like env[] in a PHP-FPM pool or server.env in RoadRunner.

Today workers get only the environment of whoever runs rapira serve. So a Symfony project picks the runtime either in composer.json (extra.runtime.class) or with a wrapper around the launch command (rapira-rs/symfony#1 (comment)).

Behaviour

  • The values are set in the worker environment before PHP starts and win over inherited ones, so getenv(), the boot-time $_SERVER and $_ENV agree.
  • An invalid name or value refuses to boot.

To weigh

  • Classic mode: whether the variables also go into each request's $_SERVER, as under PHP-FPM.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

C-feature-request💡 Suggest an idea for this project

Projects

Relationships

None yet

Development

No branches or pull requests

Issue actions