Reusable Forgejo Actions workflows for shared CI and multi-runner pipelines.
|
|
||
|---|---|---|
| .forgejo/workflows | ||
| AGENTS.md | ||
| README.md | ||
Forgejo Workflows
Reusable Forgejo Actions workflows for shared CI and multi-runner pipelines.
Workflows
Build: Release
Required Inputs & Secrets
For secrets, navigate to Repository → Settings → Actions → Secrets
| Type | Name | Required | Description |
|---|---|---|---|
| Input | platforms |
❌ | Comma-separated Docker platforms to build for. Defaults to linux/amd64. |
| Secret | REGISTRY |
✔️ | Container registry hostname or URL. |
| Secret | REGISTRY_USERNAME |
✔️ | Username used to authenticate with the registry. |
| Secret | REGISTRY_TOKEN |
✔️ | Token or password used to authenticate with the registry. |
Example
name: build-release
on:
push:
tags:
- "*.*.*"
jobs:
setup-build-release:
name: "Setup Build: Release"
uses: forgejo/workflows/.forgejo/workflows/build-release.yaml@main
with:
platforms: linux/amd64,linux/arm64
secrets:
REGISTRY: ${{ secrets.REGISTRY }}
REGISTRY_USERNAME: ${{ secrets.REGISTRY_USERNAME }}
REGISTRY_TOKEN: ${{ secrets.REGISTRY_TOKEN }}
Create: Release
Required Inputs & Secrets
For secrets, navigate to Repository → Settings → Actions → Secrets
| Type | Name | Required | Description |
|---|---|---|---|
| File | CHANGELOG.md |
✔️ | Keep a Changelog file containing a released Semantic Versioning section, such as ## [1.0.0] - YYYY-MM-DD. |
Example
name: create-release
on:
push:
tags:
- "*.*.*"
jobs:
setup-create-release:
name: "Setup Create: Release"
uses: forgejo/workflows/.forgejo/workflows/create-release.yaml@main
Build: Edge
Required Inputs & Secrets
For secrets, navigate to Repository → Settings → Actions → Secrets
| Type | Name | Required | Description |
|---|---|---|---|
| Input | platforms |
❌ | Comma-separated Docker platforms to build for. Defaults to linux/amd64. |
| Secret | REGISTRY |
✔️ | Container registry hostname or URL. |
| Secret | REGISTRY_USERNAME |
✔️ | Username used to authenticate with the registry. |
| Secret | REGISTRY_TOKEN |
✔️ | Token or password used to authenticate with the registry. |
Example
name: build-edge
on:
push:
branches:
- main
workflow_dispatch:
jobs:
setup-build-edge:
name: "Setup Build: Edge"
uses: forgejo/workflows/.forgejo/workflows/build-edge.yaml@main
with:
platforms: linux/amd64,linux/arm64
secrets:
REGISTRY: ${{ secrets.REGISTRY }}
REGISTRY_USERNAME: ${{ secrets.REGISTRY_USERNAME }}
REGISTRY_TOKEN: ${{ secrets.REGISTRY_TOKEN }}
Deploy
Required Inputs & Secrets
For secrets, navigate to Repository → Settings → Actions → Secrets
| Type | Name | Required | Description |
|---|---|---|---|
| Input | SSH_HOST |
✔️ | SSH host or server address used for deployment. |
| Input | SSH_PORT |
✔️ | SSH port used to connect to the deployment server. |
| Input | SSH_USER |
✔️ | SSH username used to authenticate with the deployment server. |
| Secret | SSH_KEY |
✔️ | Private SSH key used to authenticate with the deployment server. |
| Input | SSH_DEPLOY_PATH |
✔️ | Remote directory path where the application is deployed. |
Example
name: deploy
on:
workflow_dispatch:
jobs:
setup-deploy:
name: Setup Deploy
uses: forgejo/workflows/.forgejo/workflows/deploy.yaml@main
secrets:
SSH_HOST: ${{ secrets.SSH_HOST }}
SSH_PORT: ${{ secrets.SSH_PORT }}
SSH_USER: ${{ secrets.SSH_USER }}
SSH_KEY: ${{ secrets.SSH_KEY }}
SSH_DEPLOY_PATH: /docker/projects/example/app