facts:
- I have repo with a website on https://codeberg.org/stepanzak/pages .
- It has two branches: main and pages .
- In the main branch, there are source files for the zola static site generator.
- On every push on main, woodpecker ci runs a job that builds the static site using zola and pushes the output to the pages branch.
- The generated static site is available at https://stepanzak.codeberg.page .
- I have a domain, stepanzak.cc, managed fully with CloudFlare.
- The domain has ony following DNS records:
- image
- For the CNAME at the apex domain, CloudFlare uses CNAME flattening, so it's actually like ALIAS. That's why I also have the TXT record in there
the problem:
When I visited https://stepanzak.cc , it displayed Codeberg pages 404 error. I spent a lot of time trying to figure out why, then I thought maybe it's serving from the main branch. I added index.html to main as a test, and it worked.
So, now I have https://stepanzak.codeberg.page being served from the pages branch, and https://stepanzak.cc being served from the main branch.
expected behavior:
I would expect both codeberg.page and custom domain to behave consistently, serving from the pages branch.
### Comment
### facts:
- I have repo with a website on https://codeberg.org/stepanzak/pages .
- It has two branches: _main_ and _pages_ .
- In the _main_ branch, there are source files for the [zola](https://www.getzola.org) static site generator.
- On every push on _main_, woodpecker ci runs a job that builds the static site using zola and pushes the output to the _pages_ branch.
- The generated static site is available at https://stepanzak.codeberg.page .
- I have a domain, stepanzak.cc, managed fully with CloudFlare.
- The domain has ony following DNS records:
- 
- For the CNAME at the apex domain, CloudFlare uses CNAME flattening, so it's actually like ALIAS. That's why I also have the TXT record in there
### the problem:
When I visited https://stepanzak.cc , it displayed Codeberg pages 404 error. I spent a lot of time trying to figure out why, then I thought maybe it's serving from the _main_ branch. I added index.html to _main_ as a test, and it worked.
So, now I have https://stepanzak.codeberg.page being served from the _pages_ branch, and https://stepanzak.cc being served from the _main_ branch.
### expected behavior:
I would expect both codeberg.page and custom domain to behave consistently, serving from the _pages_ branch.