Experimental: This is currently just a test ground for an action like this, and won't be maintained. Action which simplifies access to enable-openid-connect: true OIDC JWTs in Forgejo Actions
  • Rust 41.1%
  • Shell 35.8%
  • Nix 23.1%
Find a file
Repository files (latest commit first)
Filename Latest commit message Latest commit date
2026-12-01 08:08:00 +01:00
.forgejo chore(deps): update forgejo.kainnef.com/mfenniak/debian-latest-forgejo-runner docker digest to 7aa2688 (#71) 2026-11-28 15:27:59 +01:00
src Update Rust crate ureq to v3 (#22) 2026-06-20 15:59:18 +02:00
.envrc swap from shell scripts to Rust binary 2026-06-19 19:18:17 -06:00
.gitignore swap from shell scripts to Rust binary 2026-06-19 19:18:17 -06:00
action.yml chore(release): prepare for v0.0.6 2026-06-20 14:53:31 +00:00
Cargo.lock chore(deps): lock file maintenance (#72) 2026-12-01 08:08:00 +01:00
Cargo.toml chore(deps): update rust crate serde_json to v1.0.154 (#61) 2026-10-14 18:06:39 +02:00
CHANGELOG.md chore(release): prepare for v0.0.6 2026-06-20 14:53:31 +00:00
flake.lock chore(deps): lock file maintenance (#72) 2026-12-01 08:08:00 +01:00
flake.nix ci: remove echo text, can't pipe to jq 2026-06-19 20:27:44 -06:00
README.md chore: add initial README 2026-05-28 19:14:41 -06:00
renovate.json5 chore: switch renovate -> default 2026-05-28 19:21:29 -06:00

oidc-jwt

This Forgejo Action allows you to easily retrieve a JWT from Forgejo Action's OpenID Connect capability, which can then be used to authenticate to other services.

Example:

- id: my-jwt
  uses: https://codeberg.org/mfenniak/oidc-jwt@v1
  with:
    # Audience for the JWT, which becomes the `aud` claim:
    audience: 'required-value'
- run: echo "Your JWT is now available at ${{ steps.my-jwt.outputs.jwt }}"

This Action replaces a pretty simple operation: making an HTTP request to $ACTIONS_ID_TOKEN_REQUEST_URL&audience=$OIDC_AUD, retrieving a JSON document, and extracting a JWT from it.

The job container that you run must have some tool which can be used to make an HTTP request. At least one of these supported tools must be available:

  • curl + jq
  • node
  • python3