My Hugo site is served from a VPS; I develop locally, and then rsync all the files to a directory on the VPS. This works fine.
However, I have another bunch of files - in this case presentations developed with reveal.js - which I’d also like to make available. The trouble is, I’m not sure where or how to serve them so that can be displayed with an appropriate url.
For example, I’ve added a directory “Talks” to my Hugo’s public directory. In that directory are the reveal.js files, the talk files, and various media and other files needed. I’ve set everything up to use relative addresses. Suppose the blog site is https://mysite.net. I’d hope that something like
would work, but of course it doesn’t - it just gives me a 404 error. Should I be adding the Talks directory to the static directory … or somewhere else?
What do I need to add - either in my configuration, or in theme files, or elsewhere, to allow me to access html pages in a non-blog directory? And where should those files sit?
[ I know that questions similar to this have been asked before, but I haven’t been able to work with any of the answers. ] Many thanks.
Thank you very much! My web server is Caddy, within a Docker container, and which acts as a reverse proxy, serving Lets Encrypt TLS certificates to all my various containerized apps. Caddy is designed to be very simple to deploy, with one directory designated as the root of the files to be served. Currently this simply points to where my Hugo files sit.
I’ll shift the directory Talks into static and see how I go!
My current theme is hugo-clarity, but I might switch to PaperMod which has some advantages, I think.
Worked it out! And I should have checked this first: I’d changed the Docker bind mount in my Caddy container for the directory to be served. However, I needed to stop the Caddy container, remove it, and restart a new container with the new parameters. And it now works fine. My apologies for wasting bandwidth and your time.