Skip to content

03.system-tweaks: configure automounting #43

03.system-tweaks: configure automounting

03.system-tweaks: configure automounting #43

name: Kuiper2.0
on:
push:
branches:
- staging/kuiper2.0
pull_request:
branches:
- staging/kuiper2.0
jobs:
Build:
runs-on: ${{ matrix.os }}
strategy:
matrix:
arch: [32, 64]
build_type: [basic, full]
include:
- arch: 32
build_type: basic
os: ubuntu-latest
- arch: 64
build_type: basic
os: ubuntu-latest
- arch: 32
build_type: full
os: [self-hosted, kuiper32_full]
- arch: 64
build_type: full
os: ubuntu-latest
fail-fast: false
steps:
- uses: actions/checkout@v3
- name: Set env variabiles
run: |
if [ "${{ github.event_name }}" == "pull_request" ]; then
BRANCH=$GITHUB_BASE_REF
else
BRANCH=$GITHUB_REF_NAME
fi
branch_name=$(echo $BRANCH | tr 'a-z' 'A-Z' | sed 's/[^[:alnum:]]/_/g')
type=$( echo ${{ matrix.build_type }} | tr 'a-z' 'A-Z')
echo ARTIFACT_NAME=kuiper_"${{ matrix.build_type }}"_"${{ matrix.arch }}" >> $GITHUB_ENV
echo BRANCH_NAME="$branch_name"_"$type"_"${{ matrix.arch }}" >> $GITHUB_ENV
- name: Build image
run: |
if [ "${{ matrix.os }}" == "ubuntu-latest" ]; then
sudo apt-get update
sudo apt-get install -y qemu-user-static
fi
ci/modify_config.sh ./config "${{ vars[format('{0}', env.BRANCH_NAME )] }}"
sudo bash build-docker.sh
ls kuiper-volume/*.zip >/dev/null 2>&1 && exit 0 || exit 2
- name: Upload image
if: always()
uses: actions/upload-artifact@v4
with:
name: ${{ env.ARTIFACT_NAME }}
path: ${{ github.workspace }}/kuiper-volume
Trigger_workflow:
needs: Build
runs-on: ubuntu-latest
if: github.event_name == 'push'
steps:
- uses: actions/checkout@v3
- name: Trigger docker build
run: gh workflow run docker-image-build.yml --ref staging/kuiper2.0
env:
GH_TOKEN: ${{ github.token }}