1

After updating my laravel application with composer update my .env file is not loaded into scripts anymore. When I var_dump($_ENV) I get an empty array.

I use docker - and precisely laradock - to host my application. I only boot docker-compose up nginx mariadb so I only have the following containers running: nginx, php-fpm, workspace, mariadb and docker-in-docker.

When I ssh into the container docker-composer exec workspace /bin/bash and cat .env in the /var/www directory, I see that the .env file with all variables is available inside the container. But still, the $_ENV array is empty.

Solutions provided this question did not work form me. As laradock is not part of my composer definition nothing changed about the server setup and there is no .htaccess file that might mess things up as nginx is doing the job.

Any ideas where to start debugging?

marks
  • 1,501
  • 9
  • 24
  • 1
    Does this answer your question? [Why is my $\_ENV empty?](https://stackoverflow.com/questions/3780866/why-is-my-env-empty) – Silidrone Feb 11 '21 at 09:41
  • Unfortunately not, I have been looking into that one before. But as laradock is not part of my composer definitions nothing changed about the server setup. `variables_order` is as it was and also I don't have an .htaccess that might mess up due to nginx doing the work – marks Feb 11 '21 at 09:47

0 Answers0