On Thu, Jun 6, 2019, at 10:35 AM, Marco Aurélio Deleu wrote:
> Hi everyone,
>
> I was wondering if there ever was or if there is interest in defining a
> standard for configurations / settings that would mostly benefit
> package deveiclopers. A few months ago Laravel 5.8 broke a lot of
Disclaimer: I work for a web hosting company that provides service credentials and various other information via environment variables. We also recently released some abstraction libraries for said environment variables in multiple languages. Nearly any application then needs some sort of glue code to map from our env vars into its own configuration, which could be its own env vars or container parameters or some global array or whatever it does. That said, I am speaking for myself and not on behalf of my employer.
I am not sure I agree that environment variables are something to avoid. I have read arguments that they are sub-optimal, but the only alternative I've seen is "env vars, but encrypted".
That said, I have considered in the past a spec on standardizing the environment variables. Even something simple like how Symfony and Laravel both have env vars for the primary database, but they use two entirely different formats and structures (neither of which is what Platform.sh outputs by default). Or even something as simple as the secret hash key, which should be just a single value string but... no standards.
From a host POV, a standard way to expose common information to applications would be great. Even if it's language-specific so we are just offering a common bridge library, that would be better than the status quo. The difficulty is that it will get out of the "easy" realm above very quickly.
So I'd be in favor in general, but we'd need to get the major framworks/applications on board as well as a couple of hosts to make it worthwhile.
I'm pretty sure I can get Platform.sh on board, if for no other reason than I'd be the one writing the unified bridge code on our end. :-)
--Larry Garfield