Commit 0a45607
fix(site): point site.url at the real publish location (doc.owncloud.com) (#98)
`site.yml` still declared the prototype's personal-fork address as the site URL:
url: https://deepdiver1975.github.io/owncloud-docs-monorepo
while the site is live on GitHub Pages at the custom domain doc.owncloud.com,
served at the domain ROOT (certificate approved, HTTPS enforced, deployed from
main). The comment right above the key already said it "must match the real
publish location" -- it did not, and because Antora derives canonical URLs, the
sitemap and the navbar link from it, the mismatch was visible in production:
* every page declared a canonical URL on the personal fork, telling search
engines that a fork is the authority for ownCloud's official docs:
<link rel="canonical" href="https://deepdiver1975.github.io/owncloud-docs-monorepo/server/11.0/index.html">
* sitemap.xml served from doc.owncloud.com advertised only off-domain
deepdiver1975.github.io URLs, which crawlers discard
* the navbar logo linked users off doc.owncloud.com to the fork
Search was broken for the same reason. `header-content.hbs` hardcoded the
Pagefind bundle path with the old project-site subpath:
bundle-path="/owncloud-docs-monorepo/pagefind/" -> HTTP 404
/pagefind/pagefind.js -> HTTP 200
The bundle path must stay absolute (the components dynamic-import pagefind.js
relative to their own URL), but on a root-served custom domain the correct
absolute path has no repo prefix. `/pagefind/` is also where the index sits
under `npm run serve`, so the old value was wrong for local preview too.
Verified against a real build (`npm run build`): canonical, sitemap and logo
href now all read https://doc.owncloud.com, the emitted bundle-path is
/pagefind/ and resolves to public/pagefind/pagefind.js, and no reference to the
old address survives anywhere in public/. Full suite is 17/17 with public/
built -- the four tests that need generated output no longer skip.
`site.url` is still overridden for local preview by `npm run antora-local`
(--url http://localhost:8080), so previews are unaffected. The comments in both
files, which documented the now-retired project-site-under-a-subpath layout,
are corrected to describe the custom-domain setup.
Not touched: the `/owncloud-docs-monorepo/...` prefixes in
test/go-redirect.test.js. resolveGoPhp is deliberately prefix-agnostic -- it only
rewrites the /server/<version>/ segment -- so those are arbitrary fixtures that
still pass, and keeping a prefixed case documents that property.
Signed-off-by: Thomas Müller <1005065+DeepDiver1975@users.noreply.github.com>
Co-authored-by: Claude Opus 5 <noreply@anthropic.com>1 parent 3a7b0e1 commit 0a45607
3 files changed
Lines changed: 13 additions & 8 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | 2 | | |
3 | | - | |
4 | | - | |
5 | | - | |
6 | | - | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
7 | 10 | | |
8 | 11 | | |
9 | 12 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
113 | 113 | | |
114 | 114 | | |
115 | 115 | | |
116 | | - | |
| 116 | + | |
117 | 117 | | |
118 | 118 | | |
119 | 119 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
10 | 10 | | |
11 | 11 | | |
12 | 12 | | |
13 | | - | |
14 | | - | |
15 | | - | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
16 | 18 | | |
17 | 19 | | |
18 | 20 | | |
| |||
0 commit comments