Skip to content

Added link checker#3153

Draft
mnocon wants to merge 8 commits into
5.0from
link-checker
Draft

Added link checker#3153
mnocon wants to merge 8 commits into
5.0from
link-checker

Conversation

@mnocon
Copy link
Copy Markdown
Contributor

@mnocon mnocon commented Apr 21, 2026

This PR makes it possible to check links in the documentation

Problem, constraints, and assumptions:

  • Broken links in the doc = bad
  • we only care about checking the external links: MkDocs is doing a great job of checking all internal links within a project, including fragments
  • doc.ibexa.co is protected by Cloudflare, which blocks all requests coming from IPs related to GitHub Actions
    • this means that it's not possible to verify links to doc.ibexa.co on CI environment

Tool used

Lychee is used: https://lychee.cli.rs/

  1. It's fast
  2. Has a lot of configuration options (including ignoring certain links, remapping URLS (crucial), redirections, checking fragments and text fragments)
  3. Has good CI integration
  4. Full run locally takes about ~10 minutes

How it works

  1. Ignoring files

.lycheeignore is used for URLs that cannot be checked easily

  1. Because links to doc.ibexa.co cannot be checked on CI (crawlers are blocked), and checking them is the main point, another solution is used: link remapping.

Links leading to doc.ibexa.co are remapped to local instances of the doc:

  • dev doc 5.0 (by default uses 5.0 branch)
  • dev doc 4.6 (by default uses 4.6 branch)
  • user doc 5.0 (by default uses 5.0 branch)
  • user doc 4.6 (by default uses 4.6 branch)
  • connect main (by default uses main branch)

I've checked links to lower versions of the doc (which cannot be checked on CI) manually, fixed them, and then added to the .lycheeignore file.

  1. The branches can be overwritten when triggering the job from CI

The idea is that we can use the release_4.6.x branches, to make sure all the links are correct before the release

Fixing the links

The rest of the PR fixes existing links:

  • redirects are updated to use the new location
  • broken links are fixed or removed, if removing is not possible

This PR is split into 2 commits:

The job with broken links is here:
https://github.com/ibexa/documentation-developer/actions/runs/26101343148/job/76752887924

404 - external link broken
30x - redirects
Cannot find file: File not found - documentation link broken

@github-actions
Copy link
Copy Markdown

github-actions Bot commented Apr 21, 2026

Preview of modified files

Preview of modified Markdown:

@mnocon mnocon force-pushed the link-checker branch 3 times, most recently from 0772f58 to 21146e4 Compare May 19, 2026 13:26
provider: remote
options:
url_pattern: 'https://placekitten.com/%%width%%/%%height%%'
url_pattern: 'https://picsum.photos/%%width%%/%%height%%'
Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fastly is behind this solution (https://github.com/DMarby/picsum-photos/blob/60d20d8f20bafbe727bbd37f03d2cb22dc7d4309/README.md?plain=1#L9), so should be safe to use this one.

- Rewrite custom web front end to use the new Platform/Symfony stack, see [Beginner Tutorial](beginner_tutorial.md)
- Rewrite custom admin modules to use the new Platform/Symfony stack
- And if you do this while on 5.x, you can use several of the [available legacy migration features](https://doc.ez.no/display/EZP/Legacy+code+and+features) to make the new code appear in legacy admin
- And if you do this while on 5.x, you can use several of the [available legacy migration features](https://web.archive.org/web/20140911035812/https://doc.ez.no/display/EZP/Legacy+code+and+features) to make the new code appear in legacy admin
Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

These pages are no longer online, I feel linking to their archived versions is the right thing to do - in case someone is stuck on a legacy version


Also, you can now apply new filters that are intended to help you declutter the calendar view.

For more information, see [Calendar widget](https://doc.ibexa.co/projects/userguide/en/latest/publishing/advanced_publishing_options/#calendar-widget).
Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This page is broken, no sense of ressurecting it right now

@sonarqubecloud
Copy link
Copy Markdown

Quality Gate Failed Quality Gate failed

Failed conditions
1 Security Hotspot

See analysis details on SonarQube Cloud

@github-actions
Copy link
Copy Markdown

code_samples/ change report

Before (on target branch)After (in current PR)

code_samples/back_office/images/config/packages/images_remote.yaml

docs/content_management/images/images.md@179:```yaml
docs/content_management/images/images.md@180:[[= include_file('code_samples/back_office/images/config/packages/images_remote.yaml') =]]
docs/content_management/images/images.md@181:```

001⫶ibexa:
002⫶ image_placeholder:
003⫶ default:
004⫶ provider: remote
005⫶ options:

code_samples/back_office/images/config/packages/images_remote.yaml

docs/content_management/images/images.md@179:```yaml
docs/content_management/images/images.md@180:[[= include_file('code_samples/back_office/images/config/packages/images_remote.yaml') =]]
docs/content_management/images/images.md@181:```

001⫶ibexa:
002⫶ image_placeholder:
003⫶ default:
004⫶ provider: remote
005⫶ options:
006⫶                url_pattern: 'https://placekitten.com/%%width%%/%%height%%'
006⫶                url_pattern: 'https://picsum.photos/%%width%%/%%height%%'


Download colorized diff

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant