How to configure nginx with laravel so that it does not show files

0

As we all know, Apache has the .htaccess, I'm moving to nginx and I have a problem.

My system works fine, but on the server nginx it shows me the files of the folders in this case those that are within PUBLIC of laravel.

this does not happen with apache. but with nginx yes.

what is the correct configuration so that this does not happen in nginx?

Capture - >

Thanks! Laravel 5.6 nginx 1.12.0

    
asked by juankstylez 26.04.2018 в 02:02
source

1 answer

2

the option in nginx.conf is

autoindex on;

change it to

autoindex off;

then a service nginx restart and take the configuration

    
answered by 26.04.2018 / 02:53
source