Skip to content

fix bug various bug and release 0.4.5 with new node version MAIN 4.2 … #152

fix bug various bug and release 0.4.5 with new node version MAIN 4.2 …

fix bug various bug and release 0.4.5 with new node version MAIN 4.2 … #152

Workflow file for this run

name: Build
on:
push:
workflow_call:
inputs:
tag_name:
type: string
jobs:
build:
name: build
# The build job has a matrix strategy, which means it will run multiple times with different combinations of the os, arch, and target variables.
strategy:
# When fail-fast is set to false, GitHub Actions will continue running the remaining jobs in the matrix
# even if one of the jobs fails. This is useful when you want to see all possible failures across
# different platforms/architectures rather than stopping at the first failure.
fail-fast: false
matrix:
include:
# The first combination is Ubuntu running on an AMD64 processor, building for Windows.
- os: ubuntu-24.04
arch: amd64
target: windows
ext: .exe
# The second combination is Ubuntu running on an AMD64 processor, building for Linux.
- os: ubuntu-24.04
arch: amd64
target: linux
# The third combination is macOS running on an AMD64 processor, building for Darwin (macOS).
- os: macos-15
arch: amd64
target: darwin
# The fourth combination is macOS running on an ARM64 processor, building for Darwin (macOS).
- os: macos-15
arch: arm64
target: darwin
# The build job runs on the specified operating system.
runs-on: ${{ matrix.os }}
env:
TARGET_NAME: node-manager-plugin_${{ matrix.target }}-${{ matrix.arch }}
permissions:
contents: write
id-token: write
steps:
- uses: actions/checkout@v3
- uses: ./.github/actions/install
with:
repo-token: ${{ secrets.GITHUB_TOKEN }}
- name: Build Plugin
shell: bash
run: task build
env:
OS: ${{ matrix.target }}
ARCH: ${{ matrix.arch }}
VERSION: ${{ inputs.tag_name }}
- name: Sign Macos binary
uses: massalabs/massa/.github/actions/sign-macos@a7f27829f755d30fc9f29f6c0425536cc96be4c4
if: ${{ runner.os == 'macOS' }}
with:
paths: "build/node-manager-plugin"
certificate-p12-base64: ${{ secrets.APPLE_CERTIFICATE_P12_BASE64 }}
certificate-password: ${{ secrets.APPLE_CERTIFICATE_P12_PASSWORD }}
signing-identity: ${{ vars.APPLE_DEVELOPER_ID_APPLICATION }}
entitlements: "entitlements.plist"
- name: Rename Plugin artifact
run:
mv build/node-manager-plugin${{ matrix.ext }} ${{ env.TARGET_NAME }}${{ matrix.ext }}
- name: Upload artifacts
uses: actions/upload-artifact@v4
with:
name: ${{ env.TARGET_NAME }}
path: |
${{ env.TARGET_NAME }}${{ matrix.ext }}
sign-windows-binary:
name: Sign Windows binary
needs: build
runs-on: windows-latest
permissions:
contents: write
id-token: write
env:
TARGET_NAME: node-manager-plugin_windows-amd64
steps:
- name: Download Windows artifacts
uses: actions/download-artifact@v4
with:
name: ${{ env.TARGET_NAME }}
path: .
- name: Sign Windows binary
uses: massalabs/station/.github/actions/sign-file-digicert@413d4c0bbd042d5e797fbb66bcd2c96be5c3e71a
with:
files: ${{ env.TARGET_NAME }}.exe
SM_API_KEY: ${{ secrets.SM_API_KEY }}
SM_CLIENT_CERT_FILE_B64: ${{ secrets.SM_CLIENT_CERT_FILE_B64 }}
SM_CLIENT_CERT_PASSWORD: ${{ secrets.SM_CLIENT_CERT_PASSWORD }}
SM_CERT_FINGERPRINT: ${{ secrets.SM_CERT_FINGERPRINT }}
SM_HOST: ${{ secrets.SM_HOST }}
- name: Upload signed Windows zip (overwrite original)
uses: actions/upload-artifact@v4
with:
name: ${{ env.TARGET_NAME }}
path: ./${{ env.TARGET_NAME }}.exe
overwrite: true