Skip to content

Commit

Permalink
wip
Browse files Browse the repository at this point in the history
  • Loading branch information
psaavedra committed Jan 12, 2025
1 parent 51fbf45 commit 7edf78a
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 101 deletions.
25 changes: 4 additions & 21 deletions .github/actions/podman-robot/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,6 @@ inputs:
default: 'core-image-weston-wpe'
bitbake_source:
default: 'source'
github_token:
required: true
repo_release:
default: 'scarthgap'
runs:
Expand All @@ -37,44 +35,29 @@ runs:
id: timestamp
shell: bash
run: |
TIMESTAMP=$(cat timestamp.txt)
TIMESTAMP=202501111802
echo "timestamp=${TIMESTAMP}" >> $GITHUB_OUTPUT
- name: Prepare the Robot-Framework related PODs in background
shell: bash
run: |
pushd .ci
podman rm ci_webserver_1 ci_robot_1 -f
./podman-compose.sh up --force-recreate --always-recreate-deps --build -d
popd
- name: Flash
shell: bash
run: |
TIMESTAMP=${{ steps.timestamp.outputs.timestamp }}
s3cmd get -F s3://yocto/${TIMESTAMP}-${{ inputs.bitbake_buildname }}/${{ inputs.bitbake_target }}-${{ inputs.bitbake_machine }}.wic.bmap
s3cmd get -F s3://yocto/${TIMESTAMP}-${{ inputs.bitbake_buildname }}/${{ inputs.bitbake_target }}-${{ inputs.bitbake_machine }}.wic.bz2
sudo flash ${{ inputs.bitbake_target }} ${{ inputs.bitbake_machine }}
- name: Test
- name: Test
shell: bash
run: |
cd .ci
IP=$(sudo manage-devices -c /etc/manage-devices.yml ip ${{ inputs.bitbake_machine }})
echo "#!/bin/sh" > setup-env-local.sh
echo "export TEST_BOARD_IP=${IP}" >> setup-env-local.sh
echo "test_warning_detected=false" >> $GITHUB_ENV
./run-tests.sh || {
false || {
MESSAGE="Failures were detected in the test results in ${{ inputs.bitbake_buildname }} for ${{ inputs.bitbake_target }} with ${{ inputs.bitbake_machine }}"
echo "::warning file=.ci/run-tests.sh,title=Robot Framework tests::${MESSAGE}"
echo "test_warning_detected=true" >> $GITHUB_ENV
echo "${MESSAGE}" > warning.txt
}
TIMESTAMP=${{ steps.timestamp.outputs.timestamp }}
s3cmd put -r -F tests_results/robot s3://yocto/${TIMESTAMP}-${{ inputs.bitbake_buildname }}/
- name: Comment on the pull request if there is a warning
if: env.test_warning_detected == 'true'
uses: mshick/add-pr-comment@v2
with:
message-path: |
warning.txt
- name: Clean
if: always()
shell: bash
run: |
Expand Down
81 changes: 1 addition & 80 deletions .github/workflows/test-build.yml
Original file line number Diff line number Diff line change
@@ -1,44 +1,8 @@
name: Build tests
on: [pull_request]
jobs:
scarthgap-repo:
runs-on: [self-hosted, builder]
if: "!contains(github.event.head_commit.message, 'ci skip') && github.event_name == 'pull_request'"
steps:
- uses: actions/checkout@v3
- uses: ./.github/actions/s3-configure
env:
S3_ACCESS_KEY: ${{ secrets.S3_ACCESS_KEY }}
S3_SECRET_KEY: ${{ secrets.S3_SECRET_KEY }}
S3_HOST_BASE: ${{ secrets.S3_HOST_BASE }}
with:
access_key: ${S3_ACCESS_KEY}
secret_key: ${S3_SECRET_KEY}
host_base: ${S3_HOST_BASE}
- uses: ./.github/actions/bitbake-repo
with:
repo_release: 'scarthgap'

build-raspberrypi-stable:
strategy:
fail-fast: false
matrix:
machine: ['raspberrypi3-mesa', 'raspberrypi4-64-mesa', 'raspberrypi5']
wpe_vers: ['2_46']
yocto_rel: ['scarthgap']
runs-on: [self-hosted, builder]
if: "!contains(github.event.head_commit.message, 'ci skip') && github.event_name == 'pull_request'"
needs: scarthgap-repo
steps:
- uses: actions/checkout@v3
- uses: ./.github/actions/bitbake-build
with:
bitbake_buildname: wpe-${{ matrix.wpe_vers }}-${{ matrix.machine }}
bitbake_machine: ${{ matrix.machine }}
bitbake_source: 'poky-wayland layers.raspberrypi conf.wpe-${{ matrix.wpe_vers }} --update-config'
repo_release: ${{ matrix.yocto_rel }}

test-raspberrypi-stable:
if: "!contains(github.event.head_commit.message, 'ci skip') && github.event_name == 'pull_request'"
strategy:
fail-fast: false
matrix:
Expand All @@ -48,7 +12,6 @@ jobs:
runs-on: [self-hosted, podman]
permissions:
pull-requests: write
needs: build-raspberrypi-stable
steps:
- uses: actions/checkout@v3
- uses: ./.github/actions/s3-configure
Expand All @@ -61,50 +24,8 @@ jobs:
secret_key: ${S3_SECRET_KEY}
host_base: ${S3_HOST_BASE}
- uses: ./.github/actions/podman-robot
env:
GITHUB_TOKEN: ${{ secrets.github_token }}
with:
bitbake_buildname: wpe-${{ matrix.wpe_vers }}-${{ matrix.machine }}
bitbake_machine: ${{ matrix.machine }}
github_token: ${GITHUB_TOKEN}

build-raspberrypi-nightly:
strategy:
fail-fast: false
matrix:
machine: ['raspberrypi3-mesa', 'raspberrypi4-64-mesa', 'raspberrypi5']
wpe_vers: ['nightly']
yocto_rel: ['scarthgap']
continue-on-error: true
runs-on: [self-hosted, builder]
if: "!contains(github.event.head_commit.message, 'ci skip') && github.event_name == 'pull_request' && !github.event.pull_request.draft"
needs: scarthgap-repo
steps:
- uses: actions/checkout@v3
- uses: ./.github/actions/bitbake-build
with:
bitbake_buildname: wpe-${{ matrix.wpe_vers }}-${{ matrix.machine }}
bitbake_machine: ${{ matrix.machine }}
bitbake_source: 'poky-wayland layers.raspberrypi conf.wpe-${{ matrix.wpe_vers }} --update-config'
repo_release: ${{ matrix.yocto_rel }}

build-freescale:
strategy:
fail-fast: false
matrix:
machine: ['wandboard-mesa']
wpe_vers: ['2_46', 'nightly']
yocto_rel: ['scarthgap']
continue-on-error: true
runs-on: [self-hosted, builder]
if: "!contains(github.event.head_commit.message, 'ci skip') && github.event_name == 'pull_request' && !github.event.pull_request.draft"
needs: scarthgap-repo
steps:
- uses: actions/checkout@v3
- uses: ./.github/actions/bitbake-build
with:
bitbake_buildname: wpe-${{ matrix.wpe_vers }}-${{ matrix.machine }}
bitbake_machine: ${{ matrix.machine }}
bitbake_source: 'poky-wayland layers.freescale conf.wpe-${{ matrix.wpe_vers }} --update-config'
repo_release: ${{ matrix.yocto_rel }}

0 comments on commit 7edf78a

Please sign in to comment.