Generate bzImage #7
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
name: Generate bzImage | |
# This rule triggers when the workflow will run | |
on: | |
# run the workflow manually from Actions tab | |
workflow_dispatch: | |
# jobs can run in sequence or parallel in a workflow | |
jobs: | |
# This single job is called "build" | |
build: | |
# Specify the operating system for the runner job | |
runs-on: ubuntu-latest | |
# Steps represent a sequence of tasks that will be executed as part of the job | |
steps: | |
# the job gets runned into $GITHUB_WORKSPACE, that is the environment variable for the repo | |
- name: Access current repository | |
uses: actions/checkout@v4 | |
with: | |
ref: ${{ github.ref }} | |
- name: Build docker image | |
run: | | |
docker run -d -p 5000:5000 --name registry registry:latest | |
docker compose -f ./compose.yml --progress=plain build kernel | |
docker push localhost:5000/linux_build:latest | |
- name: Retrieve artifact from docker image | |
run: | | |
docker run -it --name kernel -d localhost:5000/linux_build:latest | |
docker cp kernel:/app/artifacts/bzImage ${{ github.workspace }}/artifacts/ | |
- name: Archive the build artifact | |
uses: actions/upload-artifact@v3 | |
with: | |
# 12.80MB artifact | |
name: kernel | |
path: ${{ github.workspace }}/artifacts/bzImage | |