ci(docs): Fix docs workflow, finish moving docs to Grebedoc #2574

Open
julian45 wants to merge 6 commits from julian45/continuwuity:julian/docs/grebedoc-2 into main
Member

This pull request fixes the documentation workflow firing conditions merged in !2538 so that the workflow-level on conditions are properly respected.

It also fully removes Cloudflare Pages as a deployment target in favor of Grebedoc, and makes the docs a little more UX-friendly by respecting dark mode preferences (while still preserving the option to manually pick a mode).

Fixes #2500

Pull request checklist:

  • This pull request targets the main branch, and the branch is named something other than
    main.
  • I have written an appropriate pull request title and my description is clear.
  • I understand I am responsible for the contents of this pull request.
  • I have followed the contributing guidelines:
<!-- In order to help reviewers know what your pull request does at a glance, you should ensure that 1. Your PR title is a short, single sentence describing what you changed 2. You have described in more detail what you have changed, why you have changed it, what the intended effect is, and why you think this will be beneficial to the project. If you have made any potentially strange/questionable design choices, but didn't feel they'd benefit from code comments, please don't mention them here - after opening your pull request, go to "files changed", and click on the "+" symbol in the line number gutter, and attach comments to the lines that you think would benefit from some clarification. --> This pull request fixes the documentation workflow firing conditions merged in !2538 so that the workflow-level `on` conditions are properly respected. It also fully removes Cloudflare Pages as a deployment target in favor of Grebedoc, and makes the docs a little more UX-friendly by respecting dark mode preferences (while still preserving the option to manually pick a mode). Fixes #2500 **Pull request checklist:** - [x] This pull request targets the `main` branch, and the branch is named something other than `main`. - [x] I have written an appropriate pull request title and my description is clear. - [x] I understand I am responsible for the contents of this pull request. - I have followed the [contributing guidelines][c1]: - [x] My contribution follows the [code style][c2], if applicable. - [x] I ran [pre-commit checks][c1pc] before opening/drafting this pull request. - [x] I have [tested my contribution][c1t] (or proof-read it for documentation-only changes) myself, if applicable. This includes ensuring code compiles. - [x] My commit messages follow the [commit message format][c1cm] and are descriptive. [c1]: https://forgejo.ellis.link/continuwuation/continuwuity/src/branch/main/CONTRIBUTING.md [c2]: https://forgejo.ellis.link/continuwuation/continuwuity/src/branch/main/docs/development/code_style.mdx [c1pc]: https://forgejo.ellis.link/continuwuation/continuwuity/src/branch/main/CONTRIBUTING.md#pre-commit-checks [c1t]: https://forgejo.ellis.link/continuwuation/continuwuity/src/branch/main/CONTRIBUTING.md#running-tests-locally [c1cm]: https://forgejo.ellis.link/continuwuation/continuwuity/src/branch/main/CONTRIBUTING.md#commit-messages
ci(docs): Fix documentation workflow run conditions
Some checks failed
Auto Labeler / Apply labels based on changed files (pull_request_target) Successful in 4s
Checks / Changelog / Check changelog is added (pull_request_target) Successful in 7s
Checks / Prek / Check changed files (pull_request) Successful in 7s
Checks / Prek / Clippy and Cargo Tests (pull_request) Has been skipped
Checks / Prek / Pre-commit & Formatting (pull_request) Successful in 56s
Documentation / Build and Deploy Documentation (pull_request) Failing after 1m2s
7e4f9aef6b
julian45 force-pushed julian/docs/grebedoc-2 from 7e4f9aef6b
Some checks failed
Auto Labeler / Apply labels based on changed files (pull_request_target) Successful in 4s
Checks / Changelog / Check changelog is added (pull_request_target) Successful in 7s
Checks / Prek / Check changed files (pull_request) Successful in 7s
Checks / Prek / Clippy and Cargo Tests (pull_request) Has been skipped
Checks / Prek / Pre-commit & Formatting (pull_request) Successful in 56s
Documentation / Build and Deploy Documentation (pull_request) Failing after 1m2s
to 4b18a150fb
Some checks failed
Checks / Changelog / Check changelog is added (pull_request_target) Successful in 7s
Checks / Prek / Check changed files (pull_request) Successful in 6s
Checks / Prek / Clippy and Cargo Tests (pull_request) Has been skipped
Checks / Prek / Pre-commit & Formatting (pull_request) Successful in 1m55s
Documentation / Build and Deploy Documentation (pull_request) Failing after 47s
2026-11-21 20:47:09 +00:00
Compare
ci(docs): Use git-pages-cli directly instead of action
Some checks failed
Documentation / Build and Deploy Documentation (pull_request) Failing after 0s
Checks / Changelog / Check changelog is added (pull_request_target) Successful in 7s
Checks / Prek / Check changed files (pull_request) Successful in 9s
Checks / Prek / Clippy and Cargo Tests (pull_request) Has been skipped
Checks / Prek / Pre-commit & Formatting (pull_request) Has been cancelled
97eba66c24
ci(docs): D'oh
Some checks failed
Checks / Changelog / Check changelog is added (pull_request_target) Successful in 7s
Checks / Prek / Check changed files (pull_request) Successful in 7s
Checks / Prek / Clippy and Cargo Tests (pull_request) Has been skipped
Documentation / Build and Deploy Documentation (pull_request) Has been cancelled
Checks / Prek / Pre-commit & Formatting (pull_request) Has been cancelled
28f2e4528d
julian45 force-pushed julian/docs/grebedoc-2 from 28f2e4528d
Some checks failed
Checks / Changelog / Check changelog is added (pull_request_target) Successful in 7s
Checks / Prek / Check changed files (pull_request) Successful in 7s
Checks / Prek / Clippy and Cargo Tests (pull_request) Has been skipped
Documentation / Build and Deploy Documentation (pull_request) Has been cancelled
Checks / Prek / Pre-commit & Formatting (pull_request) Has been cancelled
to 1c25ec6e00
Some checks failed
Checks / Changelog / Check changelog is added (pull_request_target) Successful in 8s
Checks / Prek / Check changed files (pull_request) Successful in 8s
Checks / Prek / Clippy and Cargo Tests (pull_request) Has been skipped
Checks / Prek / Pre-commit & Formatting (pull_request) Successful in 57s
Documentation / Build and Deploy Documentation (pull_request) Failing after 1m35s
2026-11-21 21:09:09 +00:00
Compare
ci(docs): Specify path to Go bin
Some checks failed
Checks / Prek / Check changed files (pull_request) Successful in 6s
Checks / Changelog / Check changelog is added (pull_request_target) Successful in 7s
Checks / Prek / Clippy and Cargo Tests (pull_request) Has been skipped
Documentation / Build and Deploy Documentation (pull_request) Failing after 1m5s
Checks / Prek / Pre-commit & Formatting (pull_request) Successful in 1m57s
85e15d4a25
julian45 force-pushed julian/docs/grebedoc-2 from 85e15d4a25
Some checks failed
Checks / Prek / Check changed files (pull_request) Successful in 6s
Checks / Changelog / Check changelog is added (pull_request_target) Successful in 7s
Checks / Prek / Clippy and Cargo Tests (pull_request) Has been skipped
Documentation / Build and Deploy Documentation (pull_request) Failing after 1m5s
Checks / Prek / Pre-commit & Formatting (pull_request) Successful in 1m57s
to 183634e4e6
Some checks failed
Checks / Changelog / Check changelog is added (pull_request_target) Successful in 7s
Checks / Prek / Check changed files (pull_request) Successful in 8s
Checks / Prek / Clippy and Cargo Tests (pull_request) Has been skipped
Documentation / Build and Deploy Documentation (pull_request) Failing after 1m6s
Checks / Prek / Pre-commit & Formatting (pull_request) Successful in 1m58s
2026-11-21 21:24:46 +00:00
Compare
Author
Member

Hi @Jade,

It has become clear that Grebedoc's "method A" was insufficient to enable pushing to Grebedoc without a dedicated pages branch :(

Please do the following steps:

  • Generate a password and resulting DNS challenge record for Grebedoc purposes that'll live under preview.continuwuity.org, either via the CLI (e.g. git-pages-cli https://preview.continuwuity.org --challenge) or via the "method B" form here.
  • Put the requisite challenge TXT record(s) in DNS.
  • Store the password as an actions secret:
    • if you don't mind reusing the same "password" for both production and preview deploys, a single secret GREBEDOC_PASSWORD
    • if you'd prefer to keep separate secrets for production and dev, specific GREBEDOC_PROD_PASSWORD and GREBEDOC_PREVIEW_PASSWORD secrets
  • Let me know when you've accomplished these steps, and whether you decided to use a single secret or two separate secrets.
Hi @Jade, It has become clear that Grebedoc's "method A" was insufficient to enable pushing to Grebedoc without a dedicated `pages` branch :( Please do the following steps: - Generate a password and resulting DNS challenge record for Grebedoc purposes that'll live under preview.continuwuity.org, either [via the CLI](https://codeberg.org/git-pages/git-pages-cli#usage) (e.g. `git-pages-cli https://preview.continuwuity.org --challenge`) or via the "method B" form [here](https://grebedoc.dev/#own-domain). - Put the requisite challenge TXT record(s) in DNS. - Store the password as an actions secret: - if you don't mind reusing the same "password" for both production and preview deploys, a single secret `GREBEDOC_PASSWORD` - if you'd prefer to keep separate secrets for production and dev, specific `GREBEDOC_PROD_PASSWORD` and `GREBEDOC_PREVIEW_PASSWORD` secrets - Let me know when you've accomplished these steps, and whether you decided to use a single secret or two separate secrets.
Owner

DNS records updated, with both domains using the same password for now

DNS records updated, with both domains using the same password for now
ci(docs): Switch to Grebedoc Method B for domain control proof
Some checks failed
Checks / Changelog / Check changelog is added (pull_request_target) Successful in 8s
Checks / Prek / Check changed files (pull_request) Successful in 7s
Checks / Prek / Clippy and Cargo Tests (pull_request) Has been skipped
Checks / Prek / Pre-commit & Formatting (pull_request) Successful in 2m11s
Documentation / Build and Deploy Documentation (pull_request) Failing after 2m11s
0ea16ba06d
julian45 force-pushed julian/docs/grebedoc-2 from 0ea16ba06d
Some checks failed
Checks / Changelog / Check changelog is added (pull_request_target) Successful in 8s
Checks / Prek / Check changed files (pull_request) Successful in 7s
Checks / Prek / Clippy and Cargo Tests (pull_request) Has been skipped
Checks / Prek / Pre-commit & Formatting (pull_request) Successful in 2m11s
Documentation / Build and Deploy Documentation (pull_request) Failing after 2m11s
to 4945967a33
Some checks failed
Checks / Changelog / Check changelog is added (pull_request_target) Successful in 7s
Checks / Prek / Check changed files (pull_request) Successful in 8s
Checks / Prek / Clippy and Cargo Tests (pull_request) Has been skipped
Documentation / Build and Deploy Documentation (pull_request) Failing after 43s
Checks / Prek / Pre-commit & Formatting (pull_request) Successful in 2m8s
2026-11-21 22:20:23 +00:00
Compare
ci(docs/preview): Use dind with specified container like prior art
Some checks failed
Checks / Prek / Check changed files (pull_request) Successful in 7s
Checks / Prek / Clippy and Cargo Tests (pull_request) Has been skipped
Checks / Changelog / Check changelog is added (pull_request_target) Successful in 10s
Documentation / Build and Deploy Documentation (pull_request) Failing after 47s
Checks / Prek / Pre-commit & Formatting (pull_request) Successful in 2m3s
d0040c3b14
julian45 force-pushed julian/docs/grebedoc-2 from d0040c3b14
Some checks failed
Checks / Prek / Check changed files (pull_request) Successful in 7s
Checks / Prek / Clippy and Cargo Tests (pull_request) Has been skipped
Checks / Changelog / Check changelog is added (pull_request_target) Successful in 10s
Documentation / Build and Deploy Documentation (pull_request) Failing after 47s
Checks / Prek / Pre-commit & Formatting (pull_request) Successful in 2m3s
to e5b7badc75
Some checks failed
Checks / Changelog / Check changelog is added (pull_request_target) Successful in 8s
Documentation / Build and Deploy Documentation (pull_request) Failing after 25s
Checks / Prek / Check changed files (pull_request) Successful in 6s
Checks / Prek / Clippy and Cargo Tests (pull_request) Has been skipped
Checks / Prek / Pre-commit & Formatting (pull_request) Successful in 1m11s
Update flake hashes / update-flake-hashes (pull_request) Successful in 1m24s
2026-11-23 21:02:08 +00:00
Compare
julian45 force-pushed julian/docs/grebedoc-2 from e5b7badc75
Some checks failed
Checks / Changelog / Check changelog is added (pull_request_target) Successful in 8s
Documentation / Build and Deploy Documentation (pull_request) Failing after 25s
Checks / Prek / Check changed files (pull_request) Successful in 6s
Checks / Prek / Clippy and Cargo Tests (pull_request) Has been skipped
Checks / Prek / Pre-commit & Formatting (pull_request) Successful in 1m11s
Update flake hashes / update-flake-hashes (pull_request) Successful in 1m24s
to 1431a981bd
Some checks failed
Checks / Changelog / Check changelog is added (pull_request_target) Successful in 6s
Checks / Prek / Check changed files (pull_request) Successful in 4s
Checks / Prek / Clippy and Cargo Tests (pull_request) Has been skipped
Checks / Prek / Pre-commit & Formatting (pull_request) Successful in 1m50s
Documentation / Build and Deploy Documentation (pull_request) Failing after 1m51s
2026-11-23 21:25:09 +00:00
Compare
julian45 force-pushed julian/docs/grebedoc-2 from 1431a981bd
Some checks failed
Checks / Changelog / Check changelog is added (pull_request_target) Successful in 6s
Checks / Prek / Check changed files (pull_request) Successful in 4s
Checks / Prek / Clippy and Cargo Tests (pull_request) Has been skipped
Checks / Prek / Pre-commit & Formatting (pull_request) Successful in 1m50s
Documentation / Build and Deploy Documentation (pull_request) Failing after 1m51s
to 61cdc95a47
Some checks failed
Checks / Prek / Check changed files (pull_request) Successful in 4s
Checks / Prek / Clippy and Cargo Tests (pull_request) Has been skipped
Checks / Changelog / Check changelog is added (pull_request_target) Successful in 9s
Checks / Prek / Pre-commit & Formatting (pull_request) Successful in 1m13s
Documentation / Build and Deploy Documentation (pull_request) Failing after 1m19s
2026-11-23 21:29:37 +00:00
Compare
julian45 force-pushed julian/docs/grebedoc-2 from 61cdc95a47
Some checks failed
Checks / Prek / Check changed files (pull_request) Successful in 4s
Checks / Prek / Clippy and Cargo Tests (pull_request) Has been skipped
Checks / Changelog / Check changelog is added (pull_request_target) Successful in 9s
Checks / Prek / Pre-commit & Formatting (pull_request) Successful in 1m13s
Documentation / Build and Deploy Documentation (pull_request) Failing after 1m19s
to 08dcaa2166
Some checks failed
Checks / Changelog / Check changelog is added (pull_request_target) Successful in 7s
Checks / Prek / Check changed files (pull_request) Successful in 17s
Checks / Prek / Clippy and Cargo Tests (pull_request) Has been skipped
Documentation / Build and Deploy Documentation (pull_request) Failing after 1m13s
Checks / Prek / Pre-commit & Formatting (pull_request) Successful in 1m16s
2026-11-23 21:35:40 +00:00
Compare
Owner

While you're here, we might as well deploy main to grebedoc too and remove the cloudflare stuff btw

While you're here, we might as well deploy main to grebedoc too and remove the cloudflare stuff btw
Author
Member

@Jade wrote in #2574 (comment):

While you're here, we might as well deploy main to grebedoc too and remove the cloudflare stuff btw

Sure, when that's ready.
Two edges to this problem:

  • Merges to main after my last docs PR simply aren't firing for grebedoc because the if logic wasn't quite right.
  • The grebedoc part doesn't work quite yet 😭 (hence all the force-pushes here)
@Jade wrote in https://forgejo.ellis.link/continuwuation/continuwuity/pulls/2574#issuecomment-41042: > While you're here, we might as well deploy main to grebedoc too and remove the cloudflare stuff btw Sure, when that's ready. Two edges to this problem: - Merges to main after my last docs PR simply aren't firing for grebedoc because the `if` logic wasn't quite right. - The grebedoc part doesn't work quite yet 😭 (hence all the force-pushes here)
julian45 force-pushed julian/docs/grebedoc-2 from 08dcaa2166
Some checks failed
Checks / Changelog / Check changelog is added (pull_request_target) Successful in 7s
Checks / Prek / Check changed files (pull_request) Successful in 17s
Checks / Prek / Clippy and Cargo Tests (pull_request) Has been skipped
Documentation / Build and Deploy Documentation (pull_request) Failing after 1m13s
Checks / Prek / Pre-commit & Formatting (pull_request) Successful in 1m16s
to 699b6cfad0
Some checks failed
Checks / Changelog / Check changelog is added (pull_request_target) Successful in 8s
Checks / Prek / Check changed files (pull_request) Successful in 7s
Checks / Prek / Clippy and Cargo Tests (pull_request) Has been skipped
Documentation / Build and Deploy Documentation (pull_request) Failing after 1m8s
Checks / Prek / Pre-commit & Formatting (pull_request) Successful in 1m11s
2026-11-23 21:54:42 +00:00
Compare
julian45 force-pushed julian/docs/grebedoc-2 from 699b6cfad0
Some checks failed
Checks / Changelog / Check changelog is added (pull_request_target) Successful in 8s
Checks / Prek / Check changed files (pull_request) Successful in 7s
Checks / Prek / Clippy and Cargo Tests (pull_request) Has been skipped
Documentation / Build and Deploy Documentation (pull_request) Failing after 1m8s
Checks / Prek / Pre-commit & Formatting (pull_request) Successful in 1m11s
to 82a3bb4008
Some checks failed
Checks / Prek / Check changed files (pull_request) Successful in 6s
Checks / Changelog / Check changelog is added (pull_request_target) Successful in 7s
Checks / Prek / Clippy and Cargo Tests (pull_request) Has been skipped
Checks / Prek / Pre-commit & Formatting (pull_request) Successful in 1m13s
Documentation / Build and Deploy Documentation (pull_request) Failing after 43s
2026-11-23 22:08:32 +00:00
Compare
julian45 force-pushed julian/docs/grebedoc-2 from 82a3bb4008
Some checks failed
Checks / Prek / Check changed files (pull_request) Successful in 6s
Checks / Changelog / Check changelog is added (pull_request_target) Successful in 7s
Checks / Prek / Clippy and Cargo Tests (pull_request) Has been skipped
Checks / Prek / Pre-commit & Formatting (pull_request) Successful in 1m13s
Documentation / Build and Deploy Documentation (pull_request) Failing after 43s
to ec79b757e9
Some checks failed
Checks / Prek / Check changed files (pull_request) Successful in 5s
Checks / Prek / Clippy and Cargo Tests (pull_request) Has been skipped
Checks / Changelog / Check changelog is added (pull_request_target) Successful in 10s
Documentation / Build and Deploy Documentation (pull_request) Failing after 1m6s
Checks / Prek / Pre-commit & Formatting (pull_request) Successful in 1m11s
2026-11-24 00:20:40 +00:00
Compare
julian45 force-pushed julian/docs/grebedoc-2 from ec79b757e9
Some checks failed
Checks / Prek / Check changed files (pull_request) Successful in 5s
Checks / Prek / Clippy and Cargo Tests (pull_request) Has been skipped
Checks / Changelog / Check changelog is added (pull_request_target) Successful in 10s
Documentation / Build and Deploy Documentation (pull_request) Failing after 1m6s
Checks / Prek / Pre-commit & Formatting (pull_request) Successful in 1m11s
to 0472235d3f
Some checks failed
Checks / Prek / Check changed files (pull_request) Successful in 7s
Checks / Prek / Clippy and Cargo Tests (pull_request) Has been skipped
Checks / Changelog / Check changelog is added (pull_request_target) Successful in 8s
Documentation / Build and Deploy Documentation (pull_request) Failing after 1m5s
Checks / Prek / Pre-commit & Formatting (pull_request) Successful in 1m11s
2026-11-24 00:46:47 +00:00
Compare
julian45 force-pushed julian/docs/grebedoc-2 from 0472235d3f
Some checks failed
Checks / Prek / Check changed files (pull_request) Successful in 7s
Checks / Prek / Clippy and Cargo Tests (pull_request) Has been skipped
Checks / Changelog / Check changelog is added (pull_request_target) Successful in 8s
Documentation / Build and Deploy Documentation (pull_request) Failing after 1m5s
Checks / Prek / Pre-commit & Formatting (pull_request) Successful in 1m11s
to dd2621322b
Some checks failed
Checks / Changelog / Check changelog is added (pull_request_target) Successful in 8s
Checks / Prek / Check changed files (pull_request) Successful in 9s
Checks / Prek / Clippy and Cargo Tests (pull_request) Has been skipped
Documentation / Build and Deploy Documentation (pull_request) Failing after 1m8s
Checks / Prek / Pre-commit & Formatting (pull_request) Successful in 1m12s
2026-11-24 00:54:58 +00:00
Compare
ci(docs/preview): Smoke test to induce a particular failure case
Some checks failed
Checks / Prek / Check changed files (pull_request) Successful in 6s
Checks / Prek / Clippy and Cargo Tests (pull_request) Has been skipped
Checks / Changelog / Check changelog is added (pull_request_target) Successful in 8s
Documentation / Build and Deploy Documentation (pull_request) Failing after 1m5s
Checks / Prek / Pre-commit & Formatting (pull_request) Successful in 1m11s
a5584f520d
julian45 force-pushed julian/docs/grebedoc-2 from a5584f520d
Some checks failed
Checks / Prek / Check changed files (pull_request) Successful in 6s
Checks / Prek / Clippy and Cargo Tests (pull_request) Has been skipped
Checks / Changelog / Check changelog is added (pull_request_target) Successful in 8s
Documentation / Build and Deploy Documentation (pull_request) Failing after 1m5s
Checks / Prek / Pre-commit & Formatting (pull_request) Successful in 1m11s
to 0d4dec8153
Some checks failed
Checks / Prek / Check changed files (pull_request) Successful in 6s
Checks / Changelog / Check changelog is added (pull_request_target) Successful in 7s
Checks / Prek / Clippy and Cargo Tests (pull_request) Has been skipped
Checks / Prek / Pre-commit & Formatting (pull_request) Successful in 1m34s
Documentation / Build and Deploy Documentation (pull_request) Failing after 1m7s
2026-11-24 01:01:15 +00:00
Compare
ci(docs/preview): Try dind again
Some checks failed
Checks / Prek / Check changed files (pull_request) Successful in 6s
Checks / Prek / Clippy and Cargo Tests (pull_request) Has been skipped
Checks / Changelog / Check changelog is added (pull_request_target) Successful in 9s
Documentation / Build and Deploy Documentation (pull_request) Failing after 1m6s
Checks / Prek / Pre-commit & Formatting (pull_request) Successful in 1m12s
f1e49244ef
julian45 force-pushed julian/docs/grebedoc-2 from f1e49244ef
Some checks failed
Checks / Prek / Check changed files (pull_request) Successful in 6s
Checks / Prek / Clippy and Cargo Tests (pull_request) Has been skipped
Checks / Changelog / Check changelog is added (pull_request_target) Successful in 9s
Documentation / Build and Deploy Documentation (pull_request) Failing after 1m6s
Checks / Prek / Pre-commit & Formatting (pull_request) Successful in 1m12s
to 0d4dec8153
Some checks failed
Checks / Prek / Check changed files (pull_request) Successful in 6s
Checks / Changelog / Check changelog is added (pull_request_target) Successful in 7s
Checks / Prek / Clippy and Cargo Tests (pull_request) Has been skipped
Checks / Prek / Pre-commit & Formatting (pull_request) Successful in 1m34s
Documentation / Build and Deploy Documentation (pull_request) Failing after 1m7s
2026-11-24 01:22:28 +00:00
Compare
julian45 force-pushed julian/docs/grebedoc-2 from 0d4dec8153
Some checks failed
Checks / Prek / Check changed files (pull_request) Successful in 6s
Checks / Changelog / Check changelog is added (pull_request_target) Successful in 7s
Checks / Prek / Clippy and Cargo Tests (pull_request) Has been skipped
Checks / Prek / Pre-commit & Formatting (pull_request) Successful in 1m34s
Documentation / Build and Deploy Documentation (pull_request) Failing after 1m7s
to 5f4dcf9333
Some checks failed
Checks / Changelog / Check changelog is added (pull_request_target) Successful in 8s
Checks / Prek / Check changed files (pull_request) Successful in 7s
Checks / Prek / Clippy and Cargo Tests (pull_request) Has been skipped
Checks / Prek / Pre-commit & Formatting (pull_request) Successful in 41s
Documentation / Build and Deploy Documentation (pull_request) Failing after 1m17s
2026-11-24 01:26:03 +00:00
Compare
julian45 force-pushed julian/docs/grebedoc-2 from 5f4dcf9333
Some checks failed
Checks / Changelog / Check changelog is added (pull_request_target) Successful in 8s
Checks / Prek / Check changed files (pull_request) Successful in 7s
Checks / Prek / Clippy and Cargo Tests (pull_request) Has been skipped
Checks / Prek / Pre-commit & Formatting (pull_request) Successful in 41s
Documentation / Build and Deploy Documentation (pull_request) Failing after 1m17s
to 8205455ec5
Some checks failed
Checks / Prek / Check changed files (pull_request) Successful in 7s
Checks / Changelog / Check changelog is added (pull_request_target) Successful in 7s
Checks / Prek / Clippy and Cargo Tests (pull_request) Has been skipped
Documentation / Build and Deploy Documentation (pull_request) Failing after 1m9s
Checks / Prek / Pre-commit & Formatting (pull_request) Successful in 2m7s
2026-11-24 15:28:46 +00:00
Compare
Author
Member

Recapping the situation to date with this fix PR:

The only (partially) successful deploy of any docs to grebedoc so far has been with my laptop, using a local clone of the repo and the CLI, like so:

λ › git-pages-cli http://preview.continuwuity.org \
--password "[the correct password]" \
--upload-dir doc_build \
--pretty-urls \
--expires 14 \
--comment "helloworld" \
--verbose

(Didn't use a path for this first one since the domain alone needed to be initialized on Grebedoc anyway)

When attempting to do much the same thing in CI, we run into errors like this... this is boggling since:

  • GREBEDOC_PASSWORD is defined (see below), so the password-based path of git-pages-cli should trigger
    image
  • As such, Forge-Authorization shouldn't come into play since we're not using the token-based path, and --password and --token are supposed to be mutually exclusive anyway
  • I've verified that simply using an incorrect password locally results in a different and ultimately correct defeated by DNS challenge error.

Oh, and regarding the issues that the Grebedoc/git-pages maintainer highlighted here:

  • The _redirects seems to have been generated entirely within git-pages-cli during the upload process, as I can't find a copy locally
  • As for _headers, I can see now that Grebedoc doesn't allowlist Access-Control-Allow-Origin, leading to those errors. That seems less than ideal, as sometimes that header is necessary to get Matrix clients/servers to handle certain well-known paths correctly, but is perhaps manageable.
  • Finally, regarding the GlobalHead.0.0 error that came up in the deploy, I'm not sure what to make of that, as no such file or string exists anywhere in the repo (let alone built docs). Like with _redirects, it may originate with git-pages-cli's handling of the built docs.
Recapping the situation to date with this fix PR: The only (partially) successful deploy of *any* docs to grebedoc so far has been with my laptop, using a local clone of the repo and the CLI, like so: ``` λ › git-pages-cli http://preview.continuwuity.org \ --password "[the correct password]" \ --upload-dir doc_build \ --pretty-urls \ --expires 14 \ --comment "helloworld" \ --verbose ``` (Didn't use a path for this first one since the domain alone needed to be initialized on Grebedoc anyway) When attempting to do [much the same thing](https://forgejo.ellis.link/julian45/continuwuity/src/branch/julian/docs/grebedoc-2/.forgejo/workflows/documentation.yml#L75-L82) in CI, we run into [errors like this](https://forgejo.ellis.link/continuwuation/continuwuity/actions/runs/28263/jobs/0/attempt/1#jobstep-10-159)... this is boggling since: - `GREBEDOC_PASSWORD` *is* defined (see below), so the password-based path of git-pages-cli should trigger ![image](/attachments/a8d5bfee-d899-463d-9648-bdec6fc59df0) - As such, `Forge-Authorization` shouldn't come into play since we're not using the token-based path, and `--password` and `--token` [are supposed to be mutually exclusive anyway](https://codeberg.org/git-pages/git-pages-cli/src/commit/60817d94e957d41c1b7b51f2f0bc2ccab855dda6/main.go#L477) - I've verified that simply using an *incorrect* password locally results in a different and ultimately correct `defeated by DNS challenge` error. Oh, and regarding the issues that the Grebedoc/git-pages maintainer highlighted [here](https://forgejo.ellis.link/continuwuation/continuwuity/pulls/2538#issuecomment-41119): - The `_redirects` seems to have been generated entirely within git-pages-cli during the upload process, as I can't find a copy locally - As for `_headers`, I can see now that Grebedoc [doesn't allowlist `Access-Control-Allow-Origin`](https://grebedoc.dev/#headers), leading to those errors. That seems less than ideal, as sometimes that header is necessary to get Matrix clients/servers to handle certain `well-known` paths correctly, but is perhaps manageable. - Finally, regarding the `GlobalHead.0.0` error that came up in the deploy, I'm not sure what to make of that, as no such file or string exists anywhere in the repo (let alone built docs). Like with `_redirects`, it may originate with git-pages-cli's handling of the built docs.
@ -77,3 +72,1 @@
pretty-urls: true
expires: 14
comment: ${{ forgejo.sha }}
# Needs http for at least first deploy per docs:
Member

This might not be true: https://grebedoc.dev/#https-only

Adding --server=grebedoc.dev might be enough to allow https immediately

This might not be true: https://grebedoc.dev/#https-only Adding `--server=grebedoc.dev` might be enough to allow https immediately
Author
Member

Perhaps true, but we can cross that bridge after other deployment issues are resolved.

Perhaps true, but we can cross that bridge after other deployment issues are resolved.
First-time contributor

I do recommend --server=grebedoc.dev in any case.

I do recommend `--server=grebedoc.dev` in any case.
julian45 marked this conversation as resolved
First-time contributor

@julian45 wrote in #2574 (comment):

When attempting to do much the same thing in CI, we run into errors like this... this is boggling since:

Sorry about this! Seems like you're hitting some major UX papercuts.

  • GREBEDOC_PASSWORD is defined (see below), so the password-based path of git-pages-cli should trigger
    image

It does sound like the secret is somehow not defined. I don't have access to verify this, but maybe you could set it to a dummy value and then echo to make sure it's provided?

The git-pages server always attempts authorization with every possible mechanism and tells you what failed if none of them work. This is better than any of the alternatives I've explored.

  • I've verified that simply using an incorrect password locally results in a different and ultimately correct defeated by DNS challenge error.

Oh, and regarding the issues that the Grebedoc/git-pages maintainer highlighted here:

  • The _redirects seems to have been generated entirely within git-pages-cli during the upload process, as I can't find a copy locally

Ah yeah, you might have found a bug in --pretty-urls, I will look into it. Do you need pretty URLs?

  • As for _headers, I can see now that Grebedoc doesn't allowlist Access-Control-Allow-Origin, leading to those errors. That seems less than ideal, as sometimes that header is necessary to get Matrix clients/servers to handle certain well-known paths correctly, but is perhaps manageable.

I will add the header to the allowlist.

  • Finally, regarding the GlobalHead.0.0 error that came up in the deploy, I'm not sure what to make of that, as no such file or string exists anywhere in the repo (let alone built docs). Like with _redirects, it may originate with git-pages-cli's handling of the built docs.

This is what the --comment option becomes internally in the tar submission. I'm a little confused as to why the server is erroring out and I'm investigating that.

@julian45 wrote in https://forgejo.ellis.link/continuwuation/continuwuity/pulls/2574#issuecomment-41125: > When attempting to do [much the same thing](https://forgejo.ellis.link/julian45/continuwuity/src/branch/julian/docs/grebedoc-2/.forgejo/workflows/documentation.yml#L75-L82) in CI, we run into [errors like this](https://forgejo.ellis.link/continuwuation/continuwuity/actions/runs/28263/jobs/0/attempt/1#jobstep-10-159)... this is boggling since: Sorry about this! Seems like you're hitting some major UX papercuts. > > * `GREBEDOC_PASSWORD` _is_ defined (see below), so the password-based path of git-pages-cli should trigger > [![image](/attachments/a8d5bfee-d899-463d-9648-bdec6fc59df0)](/continuwuation/continuwuity/attachments/a8d5bfee-d899-463d-9648-bdec6fc59df0) It does sound like the secret is somehow not defined. I don't have access to verify this, but maybe you could set it to a dummy value and then `echo` to make sure it's provided? > * As such, `Forge-Authorization` shouldn't come into play since we're not using the token-based path, and `--password` and `--token` [are supposed to be mutually exclusive anyway](https://codeberg.org/git-pages/git-pages-cli/src/commit/60817d94e957d41c1b7b51f2f0bc2ccab855dda6/main.go#L477) The git-pages server always attempts authorization with every possible mechanism and tells you what failed if none of them work. This is better than any of the alternatives I've explored. > * I've verified that simply using an _incorrect_ password locally results in a different and ultimately correct `defeated by DNS challenge` error. > > Oh, and regarding the issues that the Grebedoc/git-pages maintainer highlighted [here](https://forgejo.ellis.link/continuwuation/continuwuity/pulls/2538#issuecomment-41119): > > * The `_redirects` seems to have been generated entirely within git-pages-cli during the upload process, as I can't find a copy locally Ah yeah, you might have found a bug in `--pretty-urls`, I will look into it. Do you *need* pretty URLs? > * As for `_headers`, I can see now that Grebedoc [doesn't allowlist `Access-Control-Allow-Origin`](https://grebedoc.dev/#headers), leading to those errors. That seems less than ideal, as sometimes that header is necessary to get Matrix clients/servers to handle certain `well-known` paths correctly, but is perhaps manageable. I will add the header to the allowlist. > * Finally, regarding the `GlobalHead.0.0` error that came up in the deploy, I'm not sure what to make of that, as no such file or string exists anywhere in the repo (let alone built docs). Like with `_redirects`, it may originate with git-pages-cli's handling of the built docs. This is what the `--comment` option becomes internally in the tar submission. I'm a little confused as to why the server is erroring out and I'm investigating that.
Member

@whitequark wrote in #2574 (comment):

@julian45 wrote in #2574 (comment):

  • The _redirects seems to have been generated entirely within git-pages-cli during the upload process, as I can't find a copy locally

Ah yeah, you might have found a bug in --pretty-urls, I will look into it. Do you need pretty URLs?

It would be ideal if we could have them, as we have a lot of links to docs that do not include the file extension, and thus pretty URLs would allow us to not go and manually change a large amount of links.

@whitequark wrote in https://forgejo.ellis.link/continuwuation/continuwuity/pulls/2574#issuecomment-41134: > @julian45 wrote in #2574 (comment): > > * The `_redirects` seems to have been generated entirely within git-pages-cli during the upload process, as I can't find a copy locally > > Ah yeah, you might have found a bug in `--pretty-urls`, I will look into it. Do you _need_ pretty URLs? It would be ideal if we could have them, as we have a lot of links to docs that do not include the file extension, and thus pretty URLs would allow us to not go and manually change a large amount of links.
First-time contributor

Regarding authorization, since you are not using preview.grebedoc.dev (that only works with Codeberg), have you tried _git-pages-forge-allowlist DNS record that doesn't require storing secrets? I think I've seen you mention it elsewhere on the tracker but I can't seem to find the record. Do you recall what went wrong? In general this is the recommended method.

Regarding authorization, since you are not using `preview.grebedoc.dev` (that only works with Codeberg), have you tried `_git-pages-forge-allowlist` DNS record that doesn't require storing secrets? I think I've seen you mention it elsewhere on the tracker but I can't seem to find the record. Do you recall what went wrong? In general this is the recommended method.
First-time contributor

@Henry-Hiles wrote in #2574 (comment):

It would be ideal if we could have them, as we have a lot of links to docs that do not include the file extension, and thus pretty URLs would allow us to not go and manually change a large amount of links.

I'll make sure they work for you then.

@Henry-Hiles wrote in https://forgejo.ellis.link/continuwuation/continuwuity/pulls/2574#issuecomment-41136: > It would be ideal if we could have them, as we have a lot of links to docs that do not include the file extension, and thus pretty URLs would allow us to not go and manually change a large amount of links. I'll make sure they work for you then.
First-time contributor

@whitequark wrote in #2574 (comment):

  • As for _headers, I can see now that Grebedoc doesn't allowlist Access-Control-Allow-Origin, leading to those errors. That seems less than ideal, as sometimes that header is necessary to get Matrix clients/servers to handle certain well-known paths correctly, but is perhaps manageable.

Actually, I don't think configuration needs to be changed, since git-pages sends Access-Control-Allow-Origin: * by default:

image

@julian45 wrote in #2574 (comment):

  • Finally, regarding the GlobalHead.0.0 error that came up in the deploy, I'm not sure what to make of that, as no such file or string exists anywhere in the repo (let alone built docs). Like with _redirects, it may originate with git-pages-cli's handling of the built docs.

So the error is indicative of an outdated git-pages version. I've upgraded git-pages on Grebedoc recently, and I deployed a site myself to Grebedoc just now without any errors. It should be gone now.

@whitequark wrote in https://forgejo.ellis.link/continuwuation/continuwuity/pulls/2574#issuecomment-41134: > > * As for `_headers`, I can see now that Grebedoc [doesn't allowlist `Access-Control-Allow-Origin`](https://grebedoc.dev/#headers), leading to those errors. That seems less than ideal, as sometimes that header is necessary to get Matrix clients/servers to handle certain `well-known` paths correctly, but is perhaps manageable. Actually, I don't think configuration needs to be changed, since git-pages sends `Access-Control-Allow-Origin: *` by default: ![image](/attachments/0916c800-0975-4b02-87a9-e0448eee9021) @julian45 wrote in https://forgejo.ellis.link/continuwuation/continuwuity/pulls/2574#issuecomment-41125: > * Finally, regarding the `GlobalHead.0.0` error that came up in the deploy, I'm not sure what to make of that, as no such file or string exists anywhere in the repo (let alone built docs). Like with `_redirects`, it may originate with git-pages-cli's handling of the built docs. So the error is indicative of an outdated git-pages version. I've upgraded git-pages on Grebedoc recently, and I deployed a site myself to Grebedoc just now without any errors. It should be gone now.
First-time contributor

@julian45 wrote in #2574 (comment):

  • GREBEDOC_PASSWORD is defined (see below), so the password-based path of git-pages-cli should trigger

Wait, you are expecting this to work from a pull request, right? This isn't going to happen as secrets aren't available in PRs (any PRs) for security reasons. A token wouldn't work either because git-pages will correctly determine that this token isn't allowed to push to the main repo (which might be why it didn't work for you before).

You have to run the workflow via any event but pull_request (including push or the very insecure pull_request_target) in order to have website push privileges (whether via secrets or token). Otherwise, imagine if anybody who sends you a PR would be able to overwrite the website?

Can you tell me about preview.continuwuity.org? Is the intent to deploy here docs from the main branch, or is the intent to deploy docs from PRs from potentially untrusted sources?

@julian45 wrote in https://forgejo.ellis.link/continuwuation/continuwuity/pulls/2574#issuecomment-41125: > * `GREBEDOC_PASSWORD` _is_ defined (see below), so the password-based path of git-pages-cli should trigger Wait, you are expecting this to work from a pull request, right? This isn't going to happen as secrets aren't available in PRs (any PRs) for security reasons. A token wouldn't work either because git-pages will correctly determine that this token isn't allowed to push to the main repo (which might be why it didn't work for you before). You *have* to run the workflow via any event but `pull_request` (including `push` or the very insecure `pull_request_target`) in order to have website push privileges (whether via secrets or token). Otherwise, imagine if anybody who sends you a PR would be able to overwrite the website? Can you tell me about `preview.continuwuity.org`? Is the intent to deploy here docs from the main branch, or is the intent to deploy docs from PRs from potentially untrusted sources?
Author
Member

@whitequark wrote in #2574 (comment):

Regarding authorization, since you are not using preview.grebedoc.dev (that only works with Codeberg), have you tried _git-pages-forge-allowlist DNS record that doesn't require storing secrets? I think I've seen you mention it elsewhere on the tracker but I can't seem to find the record. Do you recall what went wrong? In general this is the recommended method.

We went with "Method B" from the Grebedoc home page for a couple of reasons:

@whitequark wrote in https://forgejo.ellis.link/continuwuation/continuwuity/pulls/2574#issuecomment-41137: > Regarding authorization, since you are not using `preview.grebedoc.dev` (that only works with Codeberg), have you tried `_git-pages-forge-allowlist` DNS record that doesn't require storing secrets? I think I've seen you mention it elsewhere on the tracker but I can't seem to find the record. Do you recall what went wrong? In general this is the recommended method. We went with "Method B" from the [Grebedoc](https://grebedoc.dev/) home page for a couple of reasons: - @silversys had demonstrated success with that method [elsewhere](https://codeberg.org/silversys/website/src/branch/main/.forgejo/workflows/pages.yml#L37) for its own site, so that seemed the most surefire way to get deployments to Grebedoc off the ground - `_git-pages-forge-allowlist`, as described in the git-pages/action docs, sounded *just* similar enough to "Method A" that we were concerned [this described limitation to the `pages` branch only](https://grebedoc.dev/#:~:text=This%20method%20enables%20publishing%20the%20pages%20branch%20from%20the%20specified%20git%20clone%20URL) would apply to that method, as we don't use such a branch in this project. - Finally, when I [attempted to use that anyway](https://forgejo.ellis.link/continuwuation/continuwuity/commit/183634e4e6b5f82728d377fc3d5836e54d433bb3), I got a [*different* authorization error](https://forgejo.ellis.link/continuwuation/continuwuity/actions/runs/27884/jobs/0/attempt/1#jobstep-10-7).
First-time contributor

@julian45 wrote in #2574 (comment):

  • _git-pages-forge-allowlist, as described in the git-pages/action docs, sounded just similar enough to "Method A" that we were concerned this described limitation to the pages branch only would apply to that method, as we don't use such a branch in this project.

Right, so unfortunately I haven't found time to update the Grebedoc docs with latest git-pages features. Methods A & B were the original released authorization methods, but these days most people use forge-allowlist. There are no restrictions whatsoever on the branch because git-pages isn't even aware of which branch you're using. It only checks that the token is allowed to modify the repository.

@julian45 wrote in #2574 (comment):

This is a workflow initiated by a pull_request event:

image

A token from such a workflow indeed does not have push permissions (imagine if anybody who can open a PR could push to your main repo or update your main website).

@julian45 wrote in https://forgejo.ellis.link/continuwuation/continuwuity/pulls/2574#issuecomment-41141: > * `_git-pages-forge-allowlist`, as described in the git-pages/action docs, sounded _just_ similar enough to "Method A" that we were concerned [this described limitation to the `pages` branch only](https://grebedoc.dev/#:~:text=This%20method%20enables%20publishing%20the%20pages%20branch%20from%20the%20specified%20git%20clone%20URL) would apply to that method, as we don't use such a branch in this project. Right, so unfortunately I haven't found time to update the Grebedoc docs with latest git-pages features. Methods A & B were the original released authorization methods, but these days most people use forge-allowlist. There are no restrictions whatsoever on the branch because git-pages isn't even aware of which branch you're using. It only checks that the token is allowed to modify the repository. @julian45 wrote in https://forgejo.ellis.link/continuwuation/continuwuity/pulls/2574#issuecomment-41141: > * Finally, when I [attempted to use that anyway](https://forgejo.ellis.link/continuwuation/continuwuity/commit/183634e4e6b5f82728d377fc3d5836e54d433bb3), I got a [_different_ authorization error](https://forgejo.ellis.link/continuwuation/continuwuity/actions/runs/27884/jobs/0/attempt/1#jobstep-10-7). This is a workflow initiated by a `pull_request` event: ![image](/attachments/bb1bc01a-4758-4845-8564-00cc78a1ff22) A token from such a workflow indeed does not have push permissions (imagine if anybody who can open a PR could push to your main repo or update your main website).
Author
Member

@whitequark wrote in #2574 (comment):

@julian45 wrote in #2574 (comment):

  • GREBEDOC_PASSWORD is defined (see below), so the password-based path of git-pages-cli should trigger

Wait, you are expecting this to work from a pull request, right? This isn't going to happen as secrets aren't available in PRs (any PRs) for security reasons. A token wouldn't work either because git-pages will correctly determine that this token isn't allowed to push to the main repo (which might be why it didn't work for you before).
Ah, that'd do it.

You have to run the workflow via any event but pull_request (including push or the very insecure pull_request_target) in order to have website push privileges (whether via secrets or token). Otherwise, imagine if anybody who sends you a PR would be able to overwrite the website?

Yes, of course we wouldn't want to overwrite the main website.

Can you tell me about preview.continuwuity.org? Is the intent to deploy here docs from the main branch, or is the intent to deploy docs from PRs from potentially untrusted sources?

Sure. preview.continuwuity.org is more for the latter, or at least making sure changes from (even trusted) contributors that affect docs—e.g., changing the wording of some prose or regenerating the configuration file reference page—work properly. Hence, the notion of using PR-specific subpaths and expiring deployments under those after a while. This is an approximation of how things worked back when docs deployments were fully done with Cloudflare Pages: PR-based documentation changes would go elsewhere, while deployments upon merges to main would more or less go straight to the main site (the action output has a hash in the subdomain, but if I understand Cloudflare Pages correctly, continuwuity.org would eventually be made to point to that internally).

Eventually, we would like to have production docs deployments for continuwuity.org go to Grebedoc, but the idea of this PR and the other one you found was to "test the waters" with preview-tier deployments before a potentially disruptive migration of production docs (and yes, I'm aware there are ways to mitigate downtime in migrations).

@whitequark wrote in https://forgejo.ellis.link/continuwuation/continuwuity/pulls/2574#issuecomment-41140: > @julian45 wrote in #2574 (comment): > > > * `GREBEDOC_PASSWORD` _is_ defined (see below), so the password-based path of git-pages-cli should trigger > > Wait, you are expecting this to work from a pull request, right? This isn't going to happen as secrets aren't available in PRs (any PRs) for security reasons. A token wouldn't work either because git-pages will correctly determine that this token isn't allowed to push to the main repo (which might be why it didn't work for you before). Ah, that'd do it. > You _have_ to run the workflow via any event but `pull_request` (including `push` or the very insecure `pull_request_target`) in order to have website push privileges (whether via secrets or token). Otherwise, imagine if anybody who sends you a PR would be able to overwrite the website? Yes, of course we wouldn't want to overwrite the *main* website. > Can you tell me about `preview.continuwuity.org`? Is the intent to deploy here docs from the main branch, or is the intent to deploy docs from PRs from potentially untrusted sources? Sure. **preview**.continuwuity.org is more for the latter, or at least making sure changes from (even trusted) contributors that affect docs—e.g., changing the wording of some prose or regenerating the configuration file reference page—work properly. Hence, the notion of [using PR-specific subpaths](https://forgejo.ellis.link/julian45/continuwuity/src/branch/julian/docs/grebedoc-2/.forgejo/workflows/documentation.yml#L79) and [expiring deployments under those after a while](https://forgejo.ellis.link/julian45/continuwuity/src/branch/julian/docs/grebedoc-2/.forgejo/workflows/documentation.yml#L80). This is an approximation of how things worked back when docs deployments were fully done with Cloudflare Pages: [PR-based documentation changes would go elsewhere](https://forgejo.ellis.link/continuwuation/continuwuity/actions/runs/23780/jobs/0/attempt/1#jobstep-9-19), while deployments upon merges to main [would more or less go straight to the main site](https://forgejo.ellis.link/continuwuation/continuwuity/actions/runs/26044/jobs/0/attempt/1#jobstep-8-18) (the action output has a hash in the subdomain, but if I understand Cloudflare Pages correctly, continuwuity.org would eventually be made to point to that internally). Eventually, we would *like* to have production docs deployments for continuwuity.org go to Grebedoc, but the idea of this PR and the other one you found was to "test the waters" with preview-tier deployments before a potentially disruptive migration of production docs (and yes, I'm aware there are [ways to mitigate downtime in migrations](https://grebedoc.dev/#zero-downtime)).
First-time contributor

There are two ways to resolve this problem:

  1. Use a secret as you are doing right now, plus a pull_request_target workflow. This should be fine if you restrict it to trusted contributors (defined as "people who aren't likely to do something malicious and who aren't likely to let someone else borrow their credentials to do so"). This type of workflow is heavily discouraged by both GitHub (who defined it originally) and Forgejo project.
  2. Git-pages has a special mode for deploying preview websites that integrates with Forgejo to properly authorize pull_request (secret-less) workflow runs. However, it only works with wildcard domains. In practical terms, this means that there is a mapping, defined on the server, which matches e.g. a PR 1234 to https://username.codeberg.org/project/, with a site URL https://username.preview.codeberg.page/project@1234/, where the PR can write to that site and only that site.

Right now, Grebedoc only supports mode (2) for Codeberg specifically; every forge has to be added explicitly and forgejo.ellis.link is not in the list. There are a few possible ways to resolve this, but they will require changes to git-pages and/or Grebedoc, so first I'd like to confirm how you would like to proceed. I'm ready to support option (2) to be clear.

There are two ways to resolve this problem: 1. Use a secret as you are doing right now, plus a `pull_request_target` workflow. This should be fine if you restrict it to trusted contributors (defined as "people who aren't likely to do something malicious and who aren't likely to let someone else borrow their credentials to do so"). This type of workflow is *heavily* discouraged by both GitHub (who defined it originally) and Forgejo project. 2. Git-pages has a special mode for deploying preview websites that integrates with Forgejo to properly authorize `pull_request` (secret-less) workflow runs. However, it *only* works with wildcard domains. In practical terms, this means that there is a mapping, defined on the *server*, which matches e.g. a PR 1234 to `https://username.codeberg.org/project/`, with a site URL `https://username.preview.codeberg.page/project@1234/`, where the PR can write to that site and *only* that site. Right now, Grebedoc only supports mode (2) for Codeberg specifically; every forge has to be added explicitly and `forgejo.ellis.link` is not in the list. There are a few possible ways to resolve this, but they will require changes to git-pages and/or Grebedoc, so first I'd like to confirm how you would like to proceed. I'm ready to support option (2) to be clear.
First-time contributor

@julian45 wrote in #2574 (comment):

Eventually, we would like to have production docs deployments for continuwuity.org go to Grebedoc, but the idea of this PR and the other one you found was to "test the waters" with preview-tier deployments before a potentially disruptive migration of production docs (and yes, I'm aware there are ways to mitigate downtime in migrations).

(Perhaps ironically, preview deployments are actually a lot more complicated to set up than production deployments; the onboarding process I've had in mind when designing and documenting this functionality had them in reverse order compared to what you're doing here, i.e. I've assumed that the user has already successfully set up non-preview deployments. This seems to be one of the several reasons you're having a bad experience with git-pages.)

@julian45 wrote in https://forgejo.ellis.link/continuwuation/continuwuity/pulls/2574#issuecomment-41143: > Eventually, we would _like_ to have production docs deployments for continuwuity.org go to Grebedoc, but the idea of this PR and the other one you found was to "test the waters" with preview-tier deployments before a potentially disruptive migration of production docs (and yes, I'm aware there are [ways to mitigate downtime in migrations](https://grebedoc.dev/#zero-downtime)). (Perhaps ironically, preview deployments are actually a lot more complicated to set up than production deployments; the onboarding process I've had in mind when designing and documenting this functionality had them in reverse order compared to what you're doing here, i.e. I've assumed that the user has already successfully set up non-preview deployments. This seems to be one of the several reasons you're having a bad experience with git-pages.)
Author
Member

@whitequark wrote in #2574 (comment):

Eventually, we would like to have production docs deployments for continuwuity.org go to Grebedoc, but the idea of this PR and the other one you found was to "test the waters" with preview-tier deployments before a potentially disruptive migration of production docs (and yes, I'm aware there are ways to mitigate downtime in migrations).

(Perhaps ironically, preview deployments are actually a lot more complicated to set up than production deployments; the onboarding process I've had in mind when designing and documenting this functionality had them in reverse order compared to what you're doing here, i.e. I've assumed that the user has already successfully set up non-preview deployments. This seems to be one of the several reasons you're having a bad experience with git-pages.)

Yeah, I came to a similar conclusion recently. Given that a basic test of the "happy path" (i.e., putting the nature of the word preview aside, doing a non-preview-style deployment to preview.continuwuity.org) Just Works, it's evident that git-pages is definitely usable for a lot of folks' needs*, including existing contributors' own websites! :)
It just so happens that I've often worked in environments with rigid "always deploy to a non-production environment of some kind first, then promote to production" policies, leading towards the approach taken here and resulting discussion.

@whitequark wrote in #2574 (comment):

There are two ways to resolve this problem:

  1. Use a secret as you are doing right now, plus a pull_request_target workflow. This should be fine if you restrict it to trusted contributors (defined as "people who aren't likely to do something malicious and who aren't likely to let someone else borrow their credentials to do so"). This type of workflow is heavily discouraged by both GitHub (who defined it originally) and Forgejo project.

For the reason you've already contemplated, this doesn't seem like a great move.

  1. Git-pages has a special mode for deploying preview websites that integrates with Forgejo to properly authorize pull_request (secret-less) workflow runs. However, it only works with wildcard domains. In practical terms, this means that there is a mapping, defined on the server, which matches e.g. a PR 1234 to https://username.codeberg.org/project/, with a site URL https://username.preview.codeberg.page/project@1234/, where the PR can write to that site and only that site.

Right, I see a form of this in the git-pages/action documentation. Thanks for the additional information!

Right now, Grebedoc only supports mode (2) for Codeberg specifically; every forge has to be added explicitly and forgejo.ellis.link is not in the list. There are a few possible ways to resolve this, but they will require changes to git-pages and/or Grebedoc, so first I'd like to confirm how you would like to proceed. I'm ready to support option (2) to be clear.

(2) seems most likely to be apt, but I intend to discuss this with core project maintainers first to determine if that's something they'd like to pursue. I wouldn't want to ask this of you, just for it to not end up being ultimately wanted or used by others.

Thanks again for not only maintaining Grebedoc and git-pages, but also being willing to work on this with me and the team!

*(my own needs too, FWIW! I intend to deploy to Grebedoc—or Codeberg Pages at the very least—with my own domain in the near future)

@whitequark wrote in https://forgejo.ellis.link/continuwuation/continuwuity/pulls/2574#issuecomment-41145: > > > Eventually, we would _like_ to have production docs deployments for continuwuity.org go to Grebedoc, but the idea of this PR and the other one you found was to "test the waters" with preview-tier deployments before a potentially disruptive migration of production docs (and yes, I'm aware there are [ways to mitigate downtime in migrations](https://grebedoc.dev/#zero-downtime)). > > (Perhaps ironically, preview deployments are actually a lot more complicated to set up than production deployments; the onboarding process I've had in mind when designing and documenting this functionality had them in reverse order compared to what you're doing here, i.e. I've assumed that the user has already successfully set up non-preview deployments. This seems to be one of the several reasons you're having a bad experience with git-pages.) Yeah, I came to a similar conclusion recently. Given that a basic test of the "happy path" (i.e., putting the nature of the word `preview` aside, doing a non-preview-style deployment to `preview.continuwuity.org`) Just Works, it's evident that git-pages is definitely usable for a lot of folks' needs*, including existing contributors' own websites! :) It just so happens that I've often worked in environments with rigid "always deploy to a non-production environment of some kind first, *then* promote to production" policies, leading towards the approach taken here and resulting discussion. @whitequark wrote in https://forgejo.ellis.link/continuwuation/continuwuity/pulls/2574#issuecomment-41144: > There are two ways to resolve this problem: > > 1. Use a secret as you are doing right now, plus a `pull_request_target` workflow. This should be fine if you restrict it to trusted contributors (defined as "people who aren't likely to do something malicious and who aren't likely to let someone else borrow their credentials to do so"). This type of workflow is _heavily_ discouraged by both GitHub (who defined it originally) and Forgejo project. For the reason you've already contemplated, this doesn't seem like a great move. > 2. Git-pages has a special mode for deploying preview websites that integrates with Forgejo to properly authorize `pull_request` (secret-less) workflow runs. However, it _only_ works with wildcard domains. In practical terms, this means that there is a mapping, defined on the _server_, which matches e.g. a PR 1234 to `https://username.codeberg.org/project/`, with a site URL `https://username.preview.codeberg.page/project@1234/`, where the PR can write to that site and _only_ that site. Right, I see a form of this in the [git-pages/action documentation](https://codeberg.org/git-pages/action#with-a-wildcard-domain-matching-pull-request). Thanks for the additional information! > Right now, Grebedoc only supports mode (2) for Codeberg specifically; every forge has to be added explicitly and `forgejo.ellis.link` is not in the list. There are a few possible ways to resolve this, but they will require changes to git-pages and/or Grebedoc, so first I'd like to confirm how you would like to proceed. I'm ready to support option (2) to be clear. (2) seems most likely to be apt, but I intend to discuss this with core project maintainers first to determine if that's something they'd like to pursue. I wouldn't want to ask this of you, just for it to not end up being ultimately wanted or used by others. Thanks again for not only maintaining Grebedoc and git-pages, but also being willing to work on this with me and the team! *(my own needs too, FWIW! I intend to deploy to Grebedoc—or Codeberg Pages at the very least—with my own domain in the near future)
First-time contributor

So, I actually went ahead and implemented option (2): https://codeberg.org/git-pages/git-pages/pulls/318. It's deployed on Grebedoc now. (I've decided that this functionality will be useful to others if not to you specifically.)

You should be able to configure

_git-pages-forge-preview-allowlist.preview.continuwuity.org. TXT "https://forgejo.ellis.link/continuwuation/continuwuity.git"

and then deploy to

https://preview.continuwuity.org/@${{ forgejo.event.number }}/

from within your pull_request workflow using the --token authorization method.

edits: clarification and typos

So, I actually went ahead and implemented option (2): https://codeberg.org/git-pages/git-pages/pulls/318. It's deployed on Grebedoc now. (I've decided that this functionality will be useful to others if not to you specifically.) You should be able to configure ``` _git-pages-forge-preview-allowlist.preview.continuwuity.org. TXT "https://forgejo.ellis.link/continuwuation/continuwuity.git" ``` and then deploy to ``` https://preview.continuwuity.org/@${{ forgejo.event.number }}/ ``` from within your `pull_request` workflow using the `--token` authorization method. edits: clarification and typos
First-time contributor

@julian45 wrote in #2574 (comment):

It just so happens that I've often worked in environments with rigid "always deploy to a non-production environment of some kind first, then promote to production" policies, leading towards the approach taken here and resulting discussion.

I totally agree with this approach and prefer it! I can think of two ways to make this work without specifically going for the preview path:

  1. Use a production workflow but deploy to a test domain (e.g. test.continuwuity.org instead of continuwuity.org), to avoid using a materially different authorization path.
  2. Use the production domain but do not switch A/AAAA records (only add TXT records). If you use the --server option then git-pages-cli will happily deploy a site to a domain which isn't pointing at Grebedoc.

(I am aware that you are aware of some or all of the information above; I am only writing it down here for posterity and so that others can cross-reference it.)

@julian45 wrote in https://forgejo.ellis.link/continuwuation/continuwuity/pulls/2574#issuecomment-41146: > It just so happens that I've often worked in environments with rigid "always deploy to a non-production environment of some kind first, _then_ promote to production" policies, leading towards the approach taken here and resulting discussion. I totally agree with this approach and prefer it! I can think of two ways to make this work without specifically going for the preview path: 1. Use a production workflow but deploy to a test domain (e.g. `test.continuwuity.org` instead of `continuwuity.org`), to avoid using a materially different authorization path. 2. Use the production domain but do not switch A/AAAA records (only add TXT records). If you use the `--server` option then git-pages-cli will happily deploy a site to a domain which isn't pointing at Grebedoc. (I am aware that you are aware of some or all of the information above; I am only writing it down here for posterity and so that others can cross-reference it.)
Owner

We do have other options for domains too. c10y.cc is currently just a namespace domain, but we could totally use it for something like preview deployments and whatnot. Assuming this is relevant (I haven't really been following along with this thread)

We do have other options for domains too. `c10y.cc` is currently just a namespace domain, but we could totally use it for something like preview deployments and whatnot. Assuming this is relevant (I haven't really been following along with this thread)
ci(docs): Leverage new git-pages preview feature from whitequark
Some checks failed
Checks / Prek / Check changed files (pull_request) Successful in 4s
Checks / Prek / Clippy and Cargo Tests (pull_request) Has been skipped
Checks / Changelog / Check changelog is added (pull_request_target) Successful in 11s
Documentation / Build and Deploy Documentation (pull_request) Failing after 1m42s
Checks / Prek / Pre-commit & Formatting (pull_request) Successful in 2m0s
913737ae3c
@ -80,0 +77,4 @@
--server grebedoc.dev \
--token "${{ forgejo.token }}" \
--upload-dir doc_build \
--path "@${{ forgejo.event.number }}" \
First-time contributor

This should be a part of the URL itself, like https://preview.continuwuity.org/@${{ forgejo.event.number }}. Every deployment should be an independent site. In contrast, --path partially updates an existing site.

This should be a part of the URL itself, like `https://preview.continuwuity.org/@${{ forgejo.event.number }}`. Every deployment should be an independent site. In contrast, `--path` partially updates an existing site.
Author
Member

Good timing!

Noted, will do.

Good timing! Noted, will do.
julian45 marked this conversation as resolved
julian45 force-pushed julian/docs/grebedoc-2 from 913737ae3c
Some checks failed
Checks / Prek / Check changed files (pull_request) Successful in 4s
Checks / Prek / Clippy and Cargo Tests (pull_request) Has been skipped
Checks / Changelog / Check changelog is added (pull_request_target) Successful in 11s
Documentation / Build and Deploy Documentation (pull_request) Failing after 1m42s
Checks / Prek / Pre-commit & Formatting (pull_request) Successful in 2m0s
to 848117905d
Some checks failed
Checks / Prek / Check changed files (pull_request) Successful in 4s
Checks / Prek / Clippy and Cargo Tests (pull_request) Has been skipped
Checks / Changelog / Check changelog is added (pull_request_target) Successful in 7s
Checks / Prek / Pre-commit & Formatting (pull_request) Successful in 2m50s
Documentation / Build and Deploy Documentation (pull_request) Has been cancelled
2026-11-24 19:22:42 +00:00
Compare
julian45 force-pushed julian/docs/grebedoc-2 from 848117905d
Some checks failed
Checks / Prek / Check changed files (pull_request) Successful in 4s
Checks / Prek / Clippy and Cargo Tests (pull_request) Has been skipped
Checks / Changelog / Check changelog is added (pull_request_target) Successful in 7s
Checks / Prek / Pre-commit & Formatting (pull_request) Successful in 2m50s
Documentation / Build and Deploy Documentation (pull_request) Has been cancelled
to dc020aa40c
Some checks failed
Checks / Prek / Check changed files (pull_request) Successful in 7s
Checks / Prek / Clippy and Cargo Tests (pull_request) Has been skipped
Checks / Changelog / Check changelog is added (pull_request_target) Successful in 19s
Documentation / Build and Deploy Documentation (pull_request) Has been cancelled
Checks / Prek / Pre-commit & Formatting (pull_request) Has been cancelled
2026-11-24 19:25:47 +00:00
Compare
julian45 force-pushed julian/docs/grebedoc-2 from dc020aa40c
Some checks failed
Checks / Prek / Check changed files (pull_request) Successful in 7s
Checks / Prek / Clippy and Cargo Tests (pull_request) Has been skipped
Checks / Changelog / Check changelog is added (pull_request_target) Successful in 19s
Documentation / Build and Deploy Documentation (pull_request) Has been cancelled
Checks / Prek / Pre-commit & Formatting (pull_request) Has been cancelled
to aad30824bf
All checks were successful
Checks / Prek / Check changed files (pull_request) Successful in 4s
Checks / Prek / Clippy and Cargo Tests (pull_request) Has been skipped
Checks / Changelog / Check changelog is added (pull_request_target) Successful in 6s
Checks / Prek / Pre-commit & Formatting (pull_request) Successful in 3m51s
Documentation / Build and Deploy Documentation (pull_request) Successful in 1m4s
2026-11-24 19:26:48 +00:00
Compare
First-time contributor

I see the error you're hitting. Let me remove the site via administrative tools

I see the error you're hitting. Let me remove the site via administrative tools
First-time contributor

Ok, preview.continuwuity.org/@2574 is gone

Ok, `preview.continuwuity.org/@2574` is gone
Member

wow we're getting VIP treatment here, thank you so much for all the help!

wow we're getting VIP treatment here, thank you so much for all the help!
First-time contributor

I think watching end users struggle with your software is a great way to make it more usable!

I think watching end users struggle with your software is a great way to make it more usable!
First-time contributor

Congrats!

Congrats!
First-time contributor

Need to fix the generator: <link href="/@${{ forgejo.event.number }}/static/css/styles.7abb0dc586.css" rel="stylesheet"> has unexpanded substitutions.

Need to fix the generator: `<link href="/@${{ forgejo.event.number }}/static/css/styles.7abb0dc586.css" rel="stylesheet">` has unexpanded substitutions.
julian45 force-pushed julian/docs/grebedoc-2 from aad30824bf
All checks were successful
Checks / Prek / Check changed files (pull_request) Successful in 4s
Checks / Prek / Clippy and Cargo Tests (pull_request) Has been skipped
Checks / Changelog / Check changelog is added (pull_request_target) Successful in 6s
Checks / Prek / Pre-commit & Formatting (pull_request) Successful in 3m51s
Documentation / Build and Deploy Documentation (pull_request) Successful in 1m4s
to 2f0e673a3b
Some checks failed
Documentation / Build and Deploy Documentation (pull_request) Failing after 1s
Checks / Prek / Check changed files (pull_request) Successful in 6s
Checks / Prek / Clippy and Cargo Tests (pull_request) Has been skipped
Checks / Changelog / Check changelog is added (pull_request_target) Successful in 9s
Checks / Prek / Pre-commit & Formatting (pull_request) Successful in 1m39s
2026-11-24 19:56:47 +00:00
Compare
julian45 force-pushed julian/docs/grebedoc-2 from 2f0e673a3b
Some checks failed
Documentation / Build and Deploy Documentation (pull_request) Failing after 1s
Checks / Prek / Check changed files (pull_request) Successful in 6s
Checks / Prek / Clippy and Cargo Tests (pull_request) Has been skipped
Checks / Changelog / Check changelog is added (pull_request_target) Successful in 9s
Checks / Prek / Pre-commit & Formatting (pull_request) Successful in 1m39s
to a8d6aea816
All checks were successful
Checks / Prek / Check changed files (pull_request) Successful in 6s
Checks / Changelog / Check changelog is added (pull_request_target) Successful in 6s
Checks / Prek / Clippy and Cargo Tests (pull_request) Has been skipped
Documentation / Build and Deploy Documentation (pull_request) Successful in 1m5s
Checks / Prek / Pre-commit & Formatting (pull_request) Successful in 1m11s
2026-11-24 20:00:54 +00:00
Compare
First-time contributor

🎉

🎉
Author
Member

THANK YOU!!!!

Actual legend for not only putting together a wonderful tool & service, but also developing a new feature for it and helping me through getting things working while I do the digital equivalent of the Sideshow Bob rake bit from The Simpsons 😅

Now to make the workflow code nicer: caching the Go bits in addition to the Node.js bits, adding notifications in PR comments (for which I see there is prior art, and eventually getting production deployed too... but that work is solely on our end, I hope! :)

THANK YOU!!!! Actual *legend* for not only putting together a wonderful tool & service, but also developing a new feature for it *and* helping me through getting things working while I do the digital equivalent of [the Sideshow Bob rake bit from The Simpsons](https://frinkiac.com/bettergif/S05E02/924424/929637) 😅 Now to make the workflow code nicer: caching the Go bits in addition to the Node.js bits, adding notifications in PR comments (for which I see there is [prior art](https://codeberg.org/git-pages/action#with-a-wildcard-domain-matching-pull-request), and eventually getting production deployed too... but that work is solely on our end, I hope! :)
First-time contributor

Yep, you should be all set git-pages-wise!

Yep, you should be all set git-pages-wise!
julian45 force-pushed julian/docs/grebedoc-2 from a8d6aea816
All checks were successful
Checks / Prek / Check changed files (pull_request) Successful in 6s
Checks / Changelog / Check changelog is added (pull_request_target) Successful in 6s
Checks / Prek / Clippy and Cargo Tests (pull_request) Has been skipped
Documentation / Build and Deploy Documentation (pull_request) Successful in 1m5s
Checks / Prek / Pre-commit & Formatting (pull_request) Successful in 1m11s
to 003293bc24
All checks were successful
Checks / Changelog / Check changelog is added (pull_request_target) Successful in 8s
Checks / Prek / Check changed files (pull_request) Successful in 6s
Checks / Prek / Clippy and Cargo Tests (pull_request) Has been skipped
Checks / Prek / Pre-commit & Formatting (pull_request) Successful in 1m22s
Documentation / Build and Deploy Documentation (pull_request) Successful in 1m24s
2026-11-24 21:43:23 +00:00
Compare
The bottom of the info page now has a bit about Grebedoc, and the
theming now respects user preferences too.
ci(docs): Deploy production docs to Grebedoc
All checks were successful
Checks / Prek / Check changed files (pull_request) Successful in 6s
Checks / Changelog / Check changelog is added (pull_request_target) Successful in 9s
Checks / Prek / Clippy and Cargo Tests (pull_request) Has been skipped
Checks / Prek / Pre-commit & Formatting (pull_request) Successful in 1m22s
Documentation / Build and Deploy Documentation (pull_request) Successful in 1m28s
6e56630122
@ -32,1 +30,4 @@
- name: Setup Go
if: steps.runner-env.outputs.go_minor == '' || steps.runner-env.outputs.go_minor < '27'
uses: https://github.com/actions/setup-go@d8cbb8045d7f43706b9177cceb36c1f91a6644d5 # v7
Member

this one is pretty sure we use forgejo mirrors of actions when possible: https://code.forgejo.org/actions/setup-go

this one is pretty sure we use forgejo mirrors of actions when possible: https://code.forgejo.org/actions/setup-go
julian45 marked this conversation as resolved
julian45 force-pushed julian/docs/grebedoc-2 from 6e56630122
All checks were successful
Checks / Prek / Check changed files (pull_request) Successful in 6s
Checks / Changelog / Check changelog is added (pull_request_target) Successful in 9s
Checks / Prek / Clippy and Cargo Tests (pull_request) Has been skipped
Checks / Prek / Pre-commit & Formatting (pull_request) Successful in 1m22s
Documentation / Build and Deploy Documentation (pull_request) Successful in 1m28s
to 76366cbf5f
All checks were successful
Checks / Prek / Check changed files (pull_request) Successful in 5s
Checks / Changelog / Check changelog is added (pull_request_target) Successful in 6s
Checks / Prek / Clippy and Cargo Tests (pull_request) Has been skipped
Documentation / Build and Deploy Documentation (pull_request) Successful in 1m8s
Checks / Prek / Pre-commit & Formatting (pull_request) Successful in 1m10s
2026-11-24 23:42:14 +00:00
Compare
julian45 changed title from ci(docs): Fix documentation workflow run conditions to ci(docs): Fix docs workflow, finish moving docs to Grebedoc 2026-11-24 23:43:39 +00:00
julian45 force-pushed julian/docs/grebedoc-2 from 76366cbf5f
All checks were successful
Checks / Prek / Check changed files (pull_request) Successful in 5s
Checks / Changelog / Check changelog is added (pull_request_target) Successful in 6s
Checks / Prek / Clippy and Cargo Tests (pull_request) Has been skipped
Documentation / Build and Deploy Documentation (pull_request) Successful in 1m8s
Checks / Prek / Pre-commit & Formatting (pull_request) Successful in 1m10s
to d6d361bad4
All checks were successful
Checks / Prek / Check changed files (pull_request) Successful in 6s
Checks / Changelog / Check changelog is added (pull_request_target) Successful in 7s
Checks / Prek / Clippy and Cargo Tests (pull_request) Has been skipped
Checks / Prek / Pre-commit & Formatting (pull_request) Successful in 30s
Documentation / Build and Deploy Documentation (pull_request) Successful in 1m7s
2026-11-24 23:48:41 +00:00
Compare
silversys approved these changes 2026-11-24 23:50:10 +00:00
Jade approved these changes 2026-11-24 23:52:58 +00:00
All checks were successful
Checks / Prek / Check changed files (pull_request) Successful in 6s
Required
Details
Checks / Changelog / Check changelog is added (pull_request_target) Successful in 7s
Required
Details
Checks / Prek / Clippy and Cargo Tests (pull_request) Has been skipped
Required
Details
Checks / Prek / Pre-commit & Formatting (pull_request) Successful in 30s
Required
Details
Documentation / Build and Deploy Documentation (pull_request) Successful in 1m7s
This pull request can be merged automatically.
You are not authorized to merge this pull request.
View command line instructions

Checkout

From your project repository, check out a new branch and test the changes.
git fetch -u 'julian/docs/grebedoc-2:julian45-julian/docs/grebedoc-2'
git switch 'julian45-julian/docs/grebedoc-2'
Sign in to join this conversation.
No reviewers
No milestone
No assignees
6 participants
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
continuwuation/continuwuity!2574
No description provided.