Allow specifying the location of the .env file

Created on 12 July 2024, about 2 months ago
Updated 23 August 2024, 16 days ago

In some cases it's not possible to place a .env file above the webroot. Symfony makes allowance for that as described here: https://symfony.com/doc/current/configuration/override_dir_structure.html.

But if I implement the composer-based solution they show, the Symfony dotenv dump winds up with two paths to .env, one of which can't be found because this plugin hardwires it with $container->setParameter('dotenv.project_dir', DRUPAL_ROOT . '/..'); . So drush dotenv:dump winds up failing.

I've fixed it for my own project with a simple patch file, but it might be useful to update this in a way that provides an argument, permitting a different project_dir.

If I roll that myself, I'll provide it here, but I also offer it as a question or request.

✨ Feature request
Status

Fixed

Version

1.2

Component

Code

Created by

πŸ‡ΊπŸ‡ΈUnited States datawench

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Merge Requests

Comments & Activities

Production build 0.71.5 2024