Add SBOM Generation in auto_release.yml (#524)

This commit is contained in:
Xin Lin 2022-07-28 10:35:29 -07:00 committed by GitHub
parent 349e803314
commit c22f40d9a5
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 28 additions and 4 deletions

View File

@ -13,7 +13,7 @@ on:
default: '10.4.4'
main_br_version:
description: "Version String for task.h on main branch (leave empty to leave as-is)."
require: false
required: false
default: ''
jobs:
@ -44,14 +44,34 @@ jobs:
path: local_kernel
fetch-depth: 0
- name: Release
- name: Configure git identity
run: |
# Configure repo for push
git config --global user.name ${{ github.actor }}
git config --global user.email ${{ github.actor }}@users.noreply.github.com
- name: create a new branch that references commit id
working-directory: ./local_kernel
run: git checkout -b ${{ github.event.inputs.version_number }} ${{ github.event.inputs.commit_id }}
- name: Generate SBOM
uses: FreeRTOS/CI-CD-Github-Actions/sbom-generator@main
with:
repo_path: ./local_kernel
source_path: ./
- name: commit SBOM file
working-directory: ./local_kernel
run: |
git add .
git commit -m 'Update SBOM'
git push -u origin ${{ github.event.inputs.version_number }}
echo "COMMIT_SHA=$(git rev-parse HEAD)" >> $GITHUB_ENV
- name: Release
run: |
# Install deps and run
pip install -r ./tools/.github/scripts/release-requirements.txt
./tools/.github/scripts/release.py FreeRTOS --kernel-repo-path=local_kernel --kernel-commit=${{ github.event.inputs.commit_id }} --new-kernel-version=${{ github.event.inputs.version_number }} --new-kernel-main-br-version=${{ github.event.inputs.main_br_version }}
./tools/.github/scripts/release.py FreeRTOS --kernel-repo-path=local_kernel --kernel-commit=${{ env.COMMIT_SHA }} --new-kernel-version=${{ github.event.inputs.version_number }} --new-kernel-main-br-version=${{ github.event.inputs.main_br_version }}
exit $?
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

4
manifest.yml Normal file
View File

@ -0,0 +1,4 @@
name : "FreeRTOS-Kernel"
version: "v10.4.6"
description: "FreeRTOS Kernel."
license: "MIT"