Skip to content

Commit

Permalink
ci: add release action for firefox version
Browse files Browse the repository at this point in the history
By that, we replace the error-prone manual signing process of the
Firefox extension with API calls.

Signed-off-by: Felix Moessbauer <[email protected]>
  • Loading branch information
fmoessbauer committed Jul 2, 2024
1 parent 7d6f6b0 commit 240fb2c
Showing 1 changed file with 59 additions and 0 deletions.
59 changes: 59 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,59 @@
# SPDX-FileCopyrightText: Copyright 2024 Siemens AG
#
# SPDX-License-Identifier: MPL-2.0

name: release browser extension

on:
push:
tags:
- 'v*.*.*'

# Sets permissions of the GITHUB_TOKEN to checkout the repository
permissions:
contents: read

env:
WEB_EXT_VERS: 8.2.0

jobs:
release-xpi:
runs-on: ubuntu-latest
steps:
- name: checkout repository
uses: actions/checkout@v4

- name: install dependencies
run: |
sudo apt update && sudo apt install -y make git zip
- run: make package

- name: sign Firefox extension by Mozilla
run: |
npx web-ext@${{ env.WEB_EXT_VERS }} sign \
--channel unlisted \
--approval-timeout 900000 \
--api-key ${{ secrets.AMO_API_KEY }} \
--api-secret ${{ secrets.AMO_API_SECRET }} \
--source-dir build/firefox
--artifacts-dir build
- uses: actions/upload-artifact@v4
with:
name: firefox-signed-xpi
path: |
build/linux_entra_sso-*.xpi
- name: create release
uses: softprops/action-gh-release@v2
with:
files: |
build/linux_entra_sso-*.xpi
token: ${{ secrets.GITHUB_TOKEN }}
release_name: ${{ github.ref_name }}
body: |
Release of version ${{ github.ref_name }}
tag: ${{ github.ref_name }}
draft: false
prerelease: true

0 comments on commit 240fb2c

Please sign in to comment.