Hi everyone again, hope all is positive. My question is again related to the configuration of Caddy with Hugo. Before this I was working with Caddy alone with PHP and it works beautifully, today I wanted to add Hugo to it, basically this is the Caddyfile:
https://tour.testingsite.com {
gzip
tls luisalvaradox@gmail.com
root /var/www/html/tour
ext .php .html .htm
fastcgi / 127.0.0.1:9000 php
expires {
match .js 30s
match .css 30s
match .html 30s
}
}
https://test.testingsite.com {
gzip
tls luisalvaradox@gmail.com
root /var/www/html/test
ext .php .html .htm
fastcgi / 127.0.0.1:9000 php
expires {
match .js 30s
match .css 30s
match .html 30s
}
}
The above works perfectly between caddy and php. No problem there whatsoever. Now, if I add hugo which am basing it on the documentation and information thanks to Henrique I used this:
https://tdc.eworkbox.com {
gzip
tls luisalvaradox@gmail.com
root /var/www/html/tdc/public
hugo /var/www/html/tdc {
flag bind 0.0.0.0
}
basicauth /admin username password
log stdout
errors {
log stderr
404 404.html
}
}
I get this:
Activating privacy features… done.
2017/04/24 18:38:27 Caddyfile:37 - Parse error: Expecting a numeric status code or ‘*’, got ‘log’
And if I remove the whole error block I get this on the terminal:
Error: unknown flag: --bind
and the website shows a 404 Not Found message
Please let me know if I am missing anything else to explain the situation and obviously, what I am doing very wrong here. Thank you guys.