-
Notifications
You must be signed in to change notification settings - Fork 9
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Support ENV
based database credentials
#2
Comments
Is what you need already in https://github.com/backdrop-ops/backdrop-pantheon ? If so, maybe the answer is to start with that repo instead? |
I think we would need to do something like what @populist did on the pantheon-side in backdrop-ops/backdrop-pantheon#1 just on the docker-image side here. Let me do a quick PoC and on what this would look like! |
For background on the current
I think that having both I'm also not sure about the granularity of such options. I think I might prefer a single string for database as we have in settings.php:
Though I am ignorant of whether that is considered atypical compared to other systems. |
sorry sorry, by ENV i meant the environmental variables defined by the user in docker via the I'm with you on the granularity but i think its probably less brittle to take the granular pieces and build up BACKDROP_SETTINGS vs parsing a connection string in BASH and then doing the same. Going to push up what i had in mind in a sec for you to scope out. |
@quicksketch ^ check that out. |
Ah! The PR makes it all much more clear. Thanks! Seems like a no-brainer to me. If this ready, feel free to merge it! |
i def think this is certainly ready enough so ill merge and we can go from there |
#2: Add support for DB creds in the ENV because its 2016
This is merged. closing. reopen if necessary. |
…ts 2016" because it didn't make sense even in 2016 This reverts commit 2b27e44.
Similar to Wordpress, Backdrop is a CMS firmly rooted in the 2010's. As a result you can set your database creds in the environment instead of in a flat file. Docker tooling makes this pretty easy and awesome and a good working example is over at https://hub.docker.com/_/wordpress/
Here is a first pass on what ENV might be worth adding
@jenlampton @quicksketch i would totally be down to add support for this so in kalabox spin ups that are not tied to pantheon the user doesnt get annoyed entering their DB credentials like this is drupal 8 or something.
Presumably we could take the user defined ENV responses and merge them with defaults we set and then construct the
BACKDROP_SETTINGS
json and inject it into $_SERVER. That would provide some limitations to the user re: usingBACKDROP_SETTINGS
for other purposes.Anyway, LMK!
The text was updated successfully, but these errors were encountered: