So when I started Caddy for the first time, I tested it with a simple HTML file and it worked fine. I noticed PHP files only displayed pure text. So, after a quick google search, I found I had to enable fastcgi.
So, adding this to my Caddyfile, assuming this was right:
fastcgi {
root (my site's directory)
}
After adding this, I started Caddy using the command line “caddy” within a screen (bear in mind this was working fine before I inputted this), an error was thrown up:
Activating privacy features...2017/08/11 18:56:12 [fastcgi] failed to get certificate: acme: Error 400 - urn:acme:error:malformed - Error creating new authz :: DNS name does not have enough labels
I don’t know if this is an issue with the configuration of this, but I just wanted it done in the minimum amount of lines.
My domain is pointing at my server, and a valid certificate is running via Letsencrypt. You can see for yourself as they make everything public - oxro.co
Is there another way of doing this without using fastcgi?
Any help would be greatly appreciated regarding the matter.
Ah, yes, well the name “fastcgi” is a directive, but it is in the location of a site address. Caddy is trying to obtain a certificate for the domain “fastcgi” but it can’t because it doesn’t contain enough labels. If you want to use that as a site domain, you’ll have to turn TLS off or provide your own certificate for that (odd) domain…
So I tried various other options, none seemed to work. Would you mind giving me an example that would work in my situation with minimal amount of lines?