Skip to content

auto-recipe-update #459

auto-recipe-update

auto-recipe-update #459

name: auto-recipe-update
on:
schedule:
- cron: '0 1 * * 2-5'
workflow_dispatch:
permissions:
contents: write
pull-requests: write
jobs:
update:
name: Recipe Update
runs-on: ubuntu-22.04
steps:
- name: Setup Yocto Dependencies
run: |
sudo apt install gawk wget git diffstat unzip texinfo gcc \
build-essential chrpath socat cpio python3 python3-pip \
python3-pexpect xz-utils debianutils iputils-ping python3-git \
python3-jinja2 xterm python3-subunit zstd liblz4-tool
git config --global user.name aws-iot-embedded-linux-ci
git config --global user.email aws-iot-embedded-linux-ci@users.noreply.github.com
- name: Clone BitBake
run: git clone https://git.openembedded.org/bitbake
- name: Clone Our Layer
uses: actions/checkout@v4
with:
ref: ${{ github.ref_name }}-next
path: meta-aws
fetch-depth: 0
- name: Clone CI Tools Repo
uses: actions/checkout@v4
with:
path: ci
repository: 'aws4embeddedlinux/meta-aws-ci'
ref: master
- name: Install Helper Tool
run: pip install ci/auto-upgrader
- name: Initialize Build Environment
continue-on-error: true
run: |
bitbake/bin/bitbake-setup --setting default top-dir-prefix /home/runner \
init --non-interactive \
${{ github.workspace }}/meta-aws/.github/workflows/poky-without-meta-aws.conf.json \
poky distro/poky machine/qemux86-64
- name: Debug bblayers.conf
run: |
echo "=== bblayers.conf content ==="
cat /home/runner/bitbake-builds/poky-without-meta-aws-poky-distro_poky-machine_qemux86-64/build/conf/bblayers.conf
echo "=== Check if meta-aws path exists ==="
ls -la ${{ github.workspace }}/meta-aws/ || echo "meta-aws directory not found"
echo "=== Check workspace structure ==="
ls -la ${{ github.workspace }}/
- name: free disk space
run: |
sudo swapoff -a
sudo rm -f /swapfile
sudo apt clean
df -h
- name: Run Update
run: |
source /home/runner/bitbake-builds/poky-without-meta-aws-poky-distro_poky-machine_qemux86-64/build/init-build-env
upgrader update --layer-path ${{ github.workspace }}/meta-aws --target-branch=${{ github.ref_name }}-next
- name: Push Result
working-directory: ${{ github.workspace }}/meta-aws
run: cat /home/runner/bitbake-builds/poky-without-meta-aws-poky-distro_poky-machine_qemux86-64/build/branches.txt | xargs -n1 git push origin
- name: Create Pulls
working-directory: ${{ github.workspace }}/meta-aws
env:
GITHUB_TOKEN: ${{ secrets.BOT_CREDENTIAL }}
run: upgrader create-pulls --branch-file=/home/runner/bitbake-builds/poky-without-meta-aws-poky-distro_poky-machine_qemux86-64/build/branches.txt --repo=${{ github.repository }} --target-branch=${{ github.ref_name }}-next
- name: Publish Artifacts
uses: actions/upload-artifact@v4
with:
name: updated-recipes
path: |
/home/runner/bitbake-builds/poky-without-meta-aws-poky-distro_poky-machine_qemux86-64/build/result.json
/home/runner/bitbake-builds/poky-without-meta-aws-poky-distro_poky-machine_qemux86-64/build/upgrader.log
/home/runner/bitbake-builds/poky-without-meta-aws-poky-distro_poky-machine_qemux86-64/build/branches.txt