diff --git a/.github/workflows/reusable-markdown-link-check.yml b/.github/workflows/reusable-markdown-link-check.yml index 23c28caed2bc..7c2f372df4e8 100644 --- a/.github/workflows/reusable-markdown-link-check.yml +++ b/.github/workflows/reusable-markdown-link-check.yml @@ -14,14 +14,7 @@ jobs: - uses: lycheeverse/lychee-action@82202e5e9c2f4ef1a55a3d02563e1cb6041e5332 # v2.4.1 with: - # excluding links to pull requests and issues is done for performance - # stackexchange link fails with 403 when accessed by lychee args: > - --include-fragments - --exclude "^https://github.com/open-telemetry/opentelemetry-java-instrumentation/(issues|pull)/\\d+$" - --exclude "^http://code.google.com/p/concurrentlinkedhashmap$" - --exclude "^https://softwareengineering.stackexchange.com/questions/29727" - --max-retries 6 - --max-concurrency 4 + --config ./lychee.toml --github-token ${{ github.token }} . diff --git a/.gitignore b/.gitignore index 42e4e27f7515..308ea9e1651f 100644 --- a/.gitignore +++ b/.gitignore @@ -58,6 +58,7 @@ hs_err_pid* replay_pid* .attach_pid* .telemetry* +.lycheecache !java-agent/benchmark/releases/*.jar diff --git a/lychee.toml b/lychee.toml new file mode 100644 index 000000000000..698a061990de --- /dev/null +++ b/lychee.toml @@ -0,0 +1,19 @@ +max_retries = 6 +max_concurrency = 4 + +# Stealth +user_agent = "Mozilla/5.0 (Macintosh; Intel Mac OS X 10.15; rv:128.0) Gecko/20100101 Firefox/128.0" + +# Check fragments in links +include_fragments = true + +# excluding links to pull requests and issues is done for performance +# stackexchange link fails with 403 when accessed by lychee +exclude = [ + '^https://github.com/open-telemetry/opentelemetry-java-instrumentation/(issues|pull)/\d+$', + '^http://code.google.com/p/concurrentlinkedhashmap$', + '^https://softwareengineering.stackexchange.com/questions/29727.*', + '^https://central.sonatype.com/service/rest/repository/browse/maven-snapshots/io/opentelemetry/$', +] + +