Gitea release: a secret name Gitea accepts, and its server task limit

Gitea refuses secret names that start with GITEA_ or GITHUB_, so the
GITEA_RELEASE_TOKEN secret the release workflow read could never be
created and every tag's draft release failed after the builds. The
secret is RELEASE_TOKEN now; the script still receives it as
GITEA_RELEASE_TOKEN.

The Gitea server stops any task older than [actions] ENDLESS_TASK_TIMEOUT
(3h by default) whatever the runner's timeout says, which would end the
eight-hour release job: docs/ci.md says to raise it.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01FEpqsPES27Eacue91u3d2Q
This commit is contained in:
Claude committed 2026-10-04 16:37:42 +00:00
1 parent 264f12ca9c
commit 6c8196991e
3 files changed
+21 -8

No files matched your search

+2 -1
View File
@@ -106,5 +106,6 @@ jobs:
- name: Draft Gitea release - name: Draft Gitea release
if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags/v') if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags/v')
env: env:
GITEA_RELEASE_TOKEN: ${{ secrets.GITEA_RELEASE_TOKEN }} # Gitea refuses secret names starting with GITEA_ or GITHUB_.
GITEA_RELEASE_TOKEN: ${{ secrets.RELEASE_TOKEN }}
run: scripts/gitea-release.sh dist/release run: scripts/gitea-release.sh dist/release
+15 -5
View File
@@ -68,7 +68,10 @@ the separate `release.yml` workflow below.
Newer `gitea-runner` (2.0+) supports the workflow-level timeout. Check Newer `gitea-runner` (2.0+) supports the workflow-level timeout. Check
the installed runner's configuration rather than assuming the YAML the installed runner's configuration rather than assuming the YAML
timeout is enforced. timeout is enforced. The Gitea server also stops any task running
longer than `ENDLESS_TASK_TIMEOUT` (default `3h`, `[actions]` in
`app.ini`), whatever the runner or the workflow say; raise it above the
longest job (see the release runner below).
The workflow shares the repository's local system-dependencies action with The workflow shares the repository's local system-dependencies action with
GitHub CI and bootstraps rustup if absent, then installs the toolchain and GitHub CI and bootstraps rustup if absent, then installs the toolchain and
@@ -134,10 +137,17 @@ runner:
``` ```
The workflow requests eight hours; older act_runner ignores job-level The workflow requests eight hours; older act_runner ignores job-level
timeouts, so the runner limit is required. Keep sufficient RAM/swap and timeouts, so the runner limit is required. The server's own limit must
free disk for all package builds and their Docker caches. Builds run allow it too, or Gitea stops the release after three hours:
sequentially and limit Cargo to one job. The workflow never prunes shared
Docker state or creates host swap. The token and optional Android signing ```ini
[actions]
ENDLESS_TASK_TIMEOUT = 9h
```
Keep sufficient RAM/swap and free disk for all package builds and their
Docker caches. Builds run sequentially and limit Cargo to one job. The
workflow never prunes shared Docker state or creates host swap. The token and optional Android signing
secrets are documented in [Gitea releases](release.md#gitea-releases). secrets are documented in [Gitea releases](release.md#gitea-releases).
Gitea packages pass the shared Linux checks but do not gain native Windows, Gitea packages pass the shared Linux checks but do not gain native Windows,
+4 -2
View File
@@ -26,8 +26,10 @@ checks in GitHub or separately before accepting a release.
combined `SHA256SUMS` are attached to a **draft** Gitea release. Review, combined `SHA256SUMS` are attached to a **draft** Gitea release. Review,
sign checksums and publish manually, just as on GitHub. sign checksums and publish manually, just as on GitHub.
Set the repository secret `GITEA_RELEASE_TOKEN` to a Gitea personal access Set the repository secret `RELEASE_TOKEN` to a Gitea personal access
token with `write:repository`, limited to this repository where supported. token with `write:repository`, limited to this repository where supported
(Gitea refuses secret names that start with `GITEA_` or `GITHUB_`; the
workflow hands it to the script as `GITEA_RELEASE_TOKEN`).
The token's account must be able to write releases. The publishing script The token's account must be able to write releases. The publishing script
uses the runner's `GITHUB_SERVER_URL` and `GITHUB_REPOSITORY`; it requires uses the runner's `GITHUB_SERVER_URL` and `GITHUB_REPOSITORY`; it requires
HTTPS and never uses GitHub's release API. On this instance the server URL HTTPS and never uses GitHub's release API. On this instance the server URL