No description
- JavaScript 100%
| Filename | Latest commit message | Latest commit date |
|---|---|---|
| dist | ||
| .gitignore | ||
| .nvmrc | ||
| action.yml | ||
| index.js | ||
| LICENSE | ||
| package-lock.json | ||
| package.json | ||
| README.md | ||
trigger-update
Sends a JWT-authenticated request to AuthenticatedGlue, which will then trigger Watchtower to pull your newly pushed container images and restart your containers.
There are two flows to this setup, the OIDC flow (recommended) and the JWT flow (legacy).
OIDC flow
For the OIDC flow, configure a Forgejo Actions OIDC issuer in AuthenticatedGlue. trigger-update will acquire a JWT from Forgejo Actions and send it to AuthenticatedGlue.
Inputs
All inputs are required.
| Key | Description |
|---|---|
| flow | Must be jwt |
| glueUrl | The full URL where AuthenticatedGlue is accessible from. |
| images | A comma-separated list of images to update. |
| audience | The aud claim for the JWT |
Outputs
None
Example
- name: Trigger update
id: trigger-update
uses: https://git.foxite.dev/Foxite/trigger-update@feature/use-oidc
with:
flow: oidc
images: "testimage,testimage2"
glueUrl: https://authenticatedglue.myhomelab.net # Consider putting this in a secret.
audience: https://authenticatedglue.myhomelab.net
JWT flow
For the JWT flow, generate a PEM-encoded key pair and configure the public key into AuthenticatedGlue, and use the private key to sign a JWT.
Inputs
All inputs are required.
| Key | Description |
|---|---|
| flow | Must be jwt |
| glueUrl | The full URL where AuthenticatedGlue is accessible from. |
| images | A comma-separated list of images to update. |
| privateKey | PEM encoded private key for signing JWTs. |
| keyId | The JWT kid value. |
| algorithm | JWT signing algorithm. /(RS|PS|ES|HS)(256|384|512)/ |
To generate a signing key you could use a tool such as https://github.com/bspk/json-web-key-generator
Outputs
None
Example
- name: Trigger update
uses: Foxite/trigger-update@v1.0
with:
keyId: sig-123456789
algorithm: ES512
images: ghcr.io/foxite/fridgebot
glueUrl: https://authenticatedglue.myhomelab.net # Consider putting this in a secret.
privateKey: ${{ secrets.GLUE_KEY }} # Should be a a value starting with -----BEGIN PRIVATE KEY-----