server {
listen 80; -sharp
server_name localhost; -sharp
index index.html;
charset utf-8; -sharp
root /data/static; -sharp
location / {
autoindex on; -sharp
autoindex_exact_size off; -sharp byteskbmbgb
autoindex_localtime on; -sharp GMT
}
}
I set up the download server through nginx
. When I open my server 118.118.118.118
, it displays a list of files in one of my / data/static
directories.
now I don"t want to change 118.118.118.118
to 118.118.118.118/download
I have tried the following operations
-sharp ...
location /download {
-sharp...
}
-sharp ...
location ~/download {
-sharp...
}
-sharp ...
location / {
root download;
-sharp...
}
can not be successful, so I would like to ask how to set it?