[SOLVED] There is a problem creating an nginx dir with “autoindex on”

I have set up this sort of thing happily on my own servers in the past but this time it is on a Digital Ocean server and I wonder if that is an issue. I have looked at the dir and file permissions and config syntax etc etc and I have looked at dozens of help pages and tried many permutations but always get error 403 for this:

location /tst/ {
root /home/0_www ;
allow all;
autoindex on;
}

in /etc/nginx/conf.d/default.conf

  • any idea what the problem is?

Thanks.
Phil.

Problem solved - it worked for private IPs but not public IPs:

I needed to add the autoindex block to the domainname.conf block as well as the default.conf block . . doh!

Thank you for the follow up!