Nginx does not serve some hugo pages

Nginx does not serve index of tags, posts and about page. Altough it works fine on hugo server and vercel.

tree of public

.
├── about
│   └── index.html
├── about-hugo
│   └── index.html
├── about-us
│   └── index.html
├── categories
│   ├── index.html
│   └── index.xml
├── contact
│   └── index.html
├── css
│   ├── dark.726cd11ca6eb7c4f7d48eb420354f814e5c1b94281aaf8fd0511c1319f7f78a4.css
│   ├── fonts.b685ac6f654695232de7b82a9143a46f9e049c8e3af3a21d9737b01f4be211d1.css
│   └── main.2f9b5946627215dc1ae7fa5f82bfc9cfcab000329136befeea5733f21e77d68f.css
├── fonts
│   ├── fira-sans-v10-latin-regular.eot
│   ├── fira-sans-v10-latin-regular.svg
│   ├── fira-sans-v10-latin-regular.ttf
│   ├── fira-sans-v10-latin-regular.woff
│   ├── fira-sans-v10-latin-regular.woff2
│   ├── ibm-plex-mono-v6-latin-500italic.eot
│   ├── ibm-plex-mono-v6-latin-500italic.svg
│   ├── ibm-plex-mono-v6-latin-500italic.ttf
│   ├── ibm-plex-mono-v6-latin-500italic.woff
│   ├── ibm-plex-mono-v6-latin-500italic.woff2
│   ├── roboto-mono-v12-latin-regular.eot
│   ├── roboto-mono-v12-latin-regular.svg
│   ├── roboto-mono-v12-latin-regular.ttf
│   ├── roboto-mono-v12-latin-regular.woff
│   └── roboto-mono-v12-latin-regular.woff2
├── index.html
├── index.xml
├── js
│   ├── feather.min.js
│   ├── main.js
│   └── themetoggle.js
├── page
│   ├── 1
│   │   └── index.html
│   ├── 2
│   │   └── index.html
│   └── 3
│       └── index.html
├── posts
│   ├── index.html
│   ├── index.xml
│   ├── post-1
│   │   └── index.html
│   ├── post-2
│   │   └── index.html
│   ├── post-3
│   │   └── index.html
│   ├── post-4
│   │   └── index.html
│   ├── post-5
│   │   └── index.html
│   ├── post-7
│   │   └── index.html
│   └── tg-gh
│       └── index.html
├── sitemap.xml
└── tags
    ├── index.html
    ├── index.xml
    ├── primer
    │   ├── index.html
    │   └── index.xml
    ├── procrastinating
    │   ├── index.html
    │   └── index.xml
    ├── space
    │   ├── index.html
    │   └── index.xml
    └── todo
        ├── index.html
        └── index.xml

nginx confiure

server {
    listen       80;
    server_name mydomain;
    root /myblog;
    index index.html;
    location / {
        try_files $uri $uri/ =404;
    }
}

nginx serves posts/post name and page/page num properly. I can not understand why nginx can’t serve it. I also tried

location /posts {
alias /myblog/posts;
index index.html;
}

it did not work…
and also nginx does not throw 404 error. what should i configure to serve the static site properly?

1) Please use code fences (three backticks) when you post code, directory listings, etc. I edited your post accordingly.

2) I understand that your site is served correctly by hugo server and Vercel. However, I would like to verify that myself. Please post a link to the public repository for your project.

3) If this is purely a NGINX issue (no Hugo configuration issues), your question is better suited for Stack Overflow or Server Fault.