Skip to content

Commit 6af4833

Browse files
authored
Copy .env files into build directory
Added functionality to copy .env files during build process so that we have sane defaults for APP_ENV and APP_DEBUG
1 parent 7bdc3f7 commit 6af4833

1 file changed

Lines changed: 4 additions & 0 deletions

File tree

recipe/shopware.php

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -181,6 +181,10 @@ function getPlugins(): array
181181
if (!test('[ -d {{current_path}} ]')) {
182182
return;
183183
}
184+
// Copy .env files into build directory so we don't default to APP_ENV=dev and APP_DEBUG=1 during build
185+
download("{{current_path}}/", "./", [
186+
"options" => ["--copy-links", "--include=.env*", "--exclude=*"],
187+
]);
184188
within('{{current_path}}', function () {
185189
run('{{bin/php}} ./bin/console bundle:dump');
186190
download('{{current_path}}/var/plugins.json', './var/');

0 commit comments

Comments
 (0)