Liferay 7.4 is a Java portal (excellent). It runs on top of Tomcat, but all the posts I found about Caddy did not work. The problem turned out to be with missing settings on Liferay, not Caddy.
The Caddyfile I use looks like this:
staff.dasko.org {
encode gzip
reverse_proxy localhost:8080
log {
output file /var/log/caddy/staff.log
}
}
With only this setting, Firefox complained of mixed content (http & https).
I solved the problem by adding these lines to the Liferay setup file portal-ext.properties:
web.server.http.port=80
web.server.https.port=443
web.server.protocol=https
That was it!
Thank you Caddy developers for an excellent and easy to use product!
I hope this article helps other Liferay-ers!