M
M
Maxim Lagoysky2019-03-05 17:59:49
symfony
Maxim Lagoysky, 2019-03-05 17:59:49

How to configure database connection in nginx config?

Good evening everyone. How to transfer some application settings to nginx? In searches on the Internet, I came across such a solution, add variables to the nginx config

fastcgi_param APP_ENV prod;
fastcgi_param APP_SECRET some_new_secret_123;
fastcgi_param APP_DEBUG 0;
fastcgi_param DATABASE_URL "mysql://user:[email protected]:3306/symfony";

But then the database will not work in the console, how can this be solved?

Answer the question

In order to leave comments, you need to log in

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question