mirror of
https://github.com/go-gitea/gitea.git
synced 2026-07-15 20:40:52 +09:00
38a5824753
The nightly snap build fails with `snapcraft remote-build`'s `BadRequest()`: it force-pushes Gitea's full history to a fresh Launchpad repo each run and creates the recipe before Launchpad has indexed the `main` ref. The race is unwinnable at Gitea's repo size, and Canonical does not support `remote-build` in CI. Build locally on native amd64 + arm64 runners with `snapcore/action-build` + `snapcore/action-publish` instead — no Launchpad, no race. Drops the `LAUNCHPAD_CREDENTIALS` secret (publishing keeps `SNAPCRAFT_STORE_CREDENTIALS`); the `snap/` recipe is unchanged, so the same snaps ship to `latest/edge`. Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com>
36 lines
885 B
YAML
36 lines
885 B
YAML
name: release-nightly-snapcraft
|
|
|
|
on:
|
|
push:
|
|
branches:
|
|
- main
|
|
workflow_dispatch:
|
|
|
|
concurrency:
|
|
group: ${{ github.workflow }}-${{ github.ref }}
|
|
cancel-in-progress: true
|
|
|
|
permissions:
|
|
contents: read
|
|
|
|
jobs:
|
|
build-and-publish:
|
|
strategy:
|
|
fail-fast: false
|
|
matrix:
|
|
runner: [ubuntu-24.04, ubuntu-24.04-arm]
|
|
runs-on: ${{ matrix.runner }}
|
|
|
|
steps:
|
|
- uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7
|
|
with:
|
|
fetch-depth: 0
|
|
- uses: snapcore/action-build@3bdaa03e1ba6bf59a65f84a751d943d549a54e79 # v1.3.0
|
|
id: build
|
|
- uses: snapcore/action-publish@214b86e5ca036ead1668c79afb81e550e6c54d40 # v1.2.0
|
|
env:
|
|
SNAPCRAFT_STORE_CREDENTIALS: ${{ secrets.SNAPCRAFT_STORE_CREDENTIALS }}
|
|
with:
|
|
snap: ${{ steps.build.outputs.snap }}
|
|
release: latest/edge
|