Nginx: stat() failed (13: permission denied)

后端 未结 16 1865
梦谈多话
梦谈多话 2020-12-04 05:04

I am using the default config while adding the specific directory with nginx installed on my ubuntu 12.04 machine.

server {
        #listen   80; ## listen          


        
16条回答
  •  执念已碎
    2020-12-04 05:46

    By default the static data, when you install the nginx, will be in /var/www/html. So you can just copy your static folder into /var/html/ and set the

    root /var/www/
    

    in ngix.conf (or /etc/nginx/sites-available/default)

    This worked for me on ubuntu but I guess it should not be much different for other distros.

    Hope it helps.

提交回复
热议问题