fix: authenticate Woodpecker CI clone step when Forgejo requires sign-in (#353)

Forgejo with REQUIRE_SIGN_IN blocks anonymous git clones (exit code 128).
Add WOODPECKER_ENVIRONMENT to inject FORGE_TOKEN into all pipeline steps,
and override the default clone step in ci.yml to use an authenticated URL
built from FORGE_TOKEN — bypassing the expired stored OAuth token.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
Claude 2026-04-07 14:05:45 +00:00
parent 9a0b205f34
commit 93e4648124
2 changed files with 14 additions and 0 deletions

View file

@ -79,6 +79,7 @@ services:
WOODPECKER_AGENT_SECRET: ${WOODPECKER_AGENT_SECRET:-}
WOODPECKER_DATABASE_DRIVER: sqlite3
WOODPECKER_DATABASE_DATASOURCE: /var/lib/woodpecker/woodpecker.sqlite
WOODPECKER_ENVIRONMENT: "FORGE_TOKEN:${FORGE_TOKEN}"
depends_on:
- forgejo
networks: