Trying to add a file to the theme root directory but always add slash when request

@Kevin As I said earlier I did both tests, and took care of every detail that caused problems, but to no avail in either case.

Alternatively I talked to the developer of my Theme (Nurui Theme), and asked for a parallel opinion, where he himself also said that there is a block for Ghost-related ads.txt, and he himself recommended that I test other names and that would work correctly.

My setup is working normally and I have several clients with Ghost, using Nginx, Varnish and CWP and without any kind of bug except curiosity about this file.

Currently I was able to reproduce the domain.com/ads.txt lock on my server, and my theme owner also had the same problem, and you say you didn’t reproduce the same problem on local tests.

I’m going to upload a test instance and do a fresh install with Ghost-CLI, so I’ll have a fourth test to complete on this issue…I’ll be back here to share other tests :slight_smile:

@f1sc4ll I can assure you there is no ads.txt related block in Ghost, the issue is definitely in your environment or setup somewhere. As an example I’ve just added an ads.txt file to my theme and uploaded it to my Ghost blog, you can see it here https://lookingsideways.co.uk/ads.txt

➜ curl "https://lookingsideways.co.uk/ads.txt" 
This is my ads.txt file.

@Kevin I understood that you did it…

Now why my installation is returning a redirect 301 to /ads.txt/ is a mystery…I just did a test here with a new installation in the same environment and it worked.

#Mysteries :rofl:

Hello as of Casper 3.0.6 I have no trouble in adding the ads.txt. I just placed it in the theme’s root folder. After uploading the them I can successfully do:

curl https://randomcodetips.com/ads.txt