forked from torvalds/linux
-
Notifications
You must be signed in to change notification settings - Fork 6
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
github: Add binary kernel binary build and upload
Signed-off-by: Rob Bradford <rbradford@rivosinc.com>
- Loading branch information
Showing
1 changed file
with
48 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,48 @@ | ||
name: Cloud Hypervisor Linux Release | ||
on: [create, push] | ||
|
||
jobs: | ||
release: | ||
#if: github.event_name == 'create' && github.event.ref_type == 'tag' | ||
name: Release | ||
runs-on: ubuntu-22.04 | ||
steps: | ||
- name: Code checkout | ||
uses: actions/checkout@v4 | ||
with: | ||
fetch-depth: 0 | ||
- name: Install build tools | ||
run: sudo apt install build-essential flex bison libssl-dev libelf-dev bc | ||
- name: Download config | ||
run: curl https://raw.githubusercontent.com/cloud-hypervisor/cloud-hypervisor/main/resources/linux-config-x86_64 -o .config | ||
- name: Build kernel | ||
run: CFLAGS="-Wa,-mx86-used-note=no" make bzImage -j `nproc` | ||
- name: Create release | ||
id: create_release | ||
uses: actions/create-release@v1 | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
with: | ||
tag_name: ${{ github.ref }} | ||
release_name: ${{ github.ref }} | ||
draft: true | ||
# - name: Upload bzImage for x86_64 | ||
# id: upload-release-hypervisor-fw | ||
# uses: actions/upload-release-asset@v1 | ||
# env: | ||
# GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
# with: | ||
# upload_url: ${{ steps.create_release.outputs.upload_url }} | ||
# asset_path: arch/x86/boot/bzImage | ||
# asset_name: bzImage | ||
# asset_content_type: application/octet-stream | ||
# - name: Upload vmlinux for x86_64 | ||
# id: upload-release-hypervisor-fw | ||
# uses: actions/upload-release-asset@v1 | ||
# env: | ||
# GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
# with: | ||
# upload_url: ${{ steps.create_release.outputs.upload_url }} | ||
# asset_path: vmlinux | ||
# asset_name: vmlinux | ||
# asset_content_type: application/octet-stream |