Discrepancy between Hugo server and Public website

Hello,
I am rather new to Hugo so I apologize in advance for what is probably a rather simple mistake that I don’t quite see.

Here is my Hugo config file:

baseurl =“./”
languageCode = “en-us”
title = “Welcome”

contentdir = “content”

canonifyurls = false
relativeURLS = true
uglyurls = true

disable404 = false
enableRobotsTXT = true

[Params]
Author = “dbs”

[blackfriday]
angledQuotes = true
fractions = false
plainIDAnchors = true
extensions = [“hardLineBreak”]

I am using a firefox desktop bowser.
Using this file when I generate a simple website and render it on hugo server everything works fine.

However the local copy of the published website in ~/wbdir/public/ is not rendered correctly. The main index file ~/wbdir/public/index.html is fine. But when I navigate to a subfolder say ~/wbdir/public/posts/ I do not see the expected pages. I see a list of files/folders in that subdirectory and an index file there ( ~/wbdir/public/posts/index.html ) . The index file ( ~/wbdir/public/posts/index.html ) then has to be clicked to see the expected structure. The same issue happens with subfolders of a folder …etc.

I am attaching the structure of my ~/wbdir/public

> public ├── 404.html ├── assets │ ├── apple-touch-icon-144-precomposed.png │ └── favicon.ico ├── css │ ├── lanyon.css │ ├── poole.css │ └── syntax.css ├── fixed │ ├── about │ │ └── index.html │ ├── altab │ │ └── index.html │ ├── contact │ │ └── index.html │ ├── index.html │ └── index.xml ├── index.html ├── index.xml ├── posts │ ├── 2013-12-31-whats-jekyll │ │ └── index.html │ ├── 2014-01-01-example-content │ │ └── index.html │ ├── 2014-01-02-introducing-lanyon │ │ └── index.html │ ├── index.html │ └── index.xml ├── robots.txt └── sitemap.xml

For testing I deployed the published website to an apache server (using rsync) and I have the same problem.

My guess is that I am making a mistake with the config file but I am probably wrong. I will appreciate any help with this problem and would be happy to provide any information.

Thank you.

I’m not having this issue when I just tested ugly URLS (you don’t want pretty URLs?). You can set baseurl = "" and try setting your uglyurls = true to uglyURLs = true. Just a stab in the dark…

The generated files look correct on first glance. When you’re checking the public folder locally, how are you doing it?

And when you’re serving the files via Apache on your server, are you sure you have correctly configured Apache to automatically show index.html files when navigating to a folder?

Okay I was able to solve the problem by fixing uglyurls to uglyURLSs and there seems to be another problem.
Thanks a ton for your help!

@dbs Good news. Add a new thread for the other problem and maybe I can lend you a hand…