From c6b2394585618461ca2d8da99e8b27433f0cbeb3 Mon Sep 17 00:00:00 2001 From: Copilot <198982749+Copilot@users.noreply.github.com> Date: Sun, 28 Jun 2026 15:36:28 -0700 Subject: [PATCH] fix(actions): authenticate snapcraft before nightly remote build (#38252) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The `release-nightly-snapcraft` workflow’s `build-and-publish` job was failing because `snapcraft remote-build` fell back to interactive Launchpad authorization in CI. This change makes authentication explicit and non-interactive before the remote build step. - **Workflow change** - Add an `Authenticate snapcraft` step before `Remote build`. - Run `snapcraft login --with` using the existing `SNAPCRAFT_STORE_CREDENTIALS` secret. - Pin that step to `shell: bash` to support process substitution. - **Why this fixes the failure** - Prevents CI from entering browser-based Launchpad auth flow. - Ensures `remote-build` runs with preloaded credentials. ```yaml - name: Authenticate snapcraft shell: bash env: SNAPCRAFT_STORE_CREDENTIALS: ${{ secrets.SNAPCRAFT_STORE_CREDENTIALS }} run: snapcraft login --with <(printf '%s' "$SNAPCRAFT_STORE_CREDENTIALS") ``` --------- Signed-off-by: Lunny Xiao Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com> Co-authored-by: Lunny Xiao Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com> --- .github/workflows/release-nightly-snapcraft.yml | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/.github/workflows/release-nightly-snapcraft.yml b/.github/workflows/release-nightly-snapcraft.yml index 7afca350c2e..f89654e40ba 100644 --- a/.github/workflows/release-nightly-snapcraft.yml +++ b/.github/workflows/release-nightly-snapcraft.yml @@ -22,6 +22,10 @@ jobs: - name: Install snapcraft run: sudo snap install snapcraft --classic + - name: Authenticate snapcraft + shell: bash + run: snapcraft login --with <(printf '%s' "$SNAPCRAFT_STORE_CREDENTIALS") + - name: Remote build run: | snapcraft remote-build \