Skip to content

Commit

Permalink
ci/qemu: use a tarball to xfer source code to guest
Browse files Browse the repository at this point in the history
Instead of faking a GitHub Actions runner environment, just create a
source code tarball and transfer it to the guest VM. This is simpler and
does not depend on the continued existence of the action used
previously.

Signed-off-by: Vincent Fu <vincent.fu@samsung.com>
  • Loading branch information
vincentkfu committed Sep 27, 2024
1 parent fef1936 commit cbd2e61
Showing 1 changed file with 9 additions and 4 deletions.
13 changes: 9 additions & 4 deletions .github/workflows/qemu.yml
Original file line number Diff line number Diff line change
Expand Up @@ -57,13 +57,19 @@ jobs:
env:
DISTRO: debian-12
SSHCMD: ssh root@localhost -p 2022
SCPCMD: scp -P 2022
CI_TARGET_BUILD: linux
CI_TARGET_OS: debian

steps:
- name: Check out repository
uses: actions/checkout@v4

- name: Create tarball containing repository
run: |
git archive --format=tar.gz -o fio-src.tar.gz --prefix=fio/ HEAD
git log -1
- name: Create guest VM image
uses: ./.github/actions/create-guest-image
with:
Expand All @@ -83,11 +89,10 @@ jobs:
host_key: true
options: ${{ matrix.device }}

- name: Clone fio on guest
- name: Transfer fio source to guest
run: |
$SSHCMD "apt-get update && apt-get install -qq git"
$SSHCMD "git clone https://github.com/taiki-e/checkout-action --branch v1.3.0"
$SSHCMD "mkdir fio && cd fio && ../checkout-action/main.sh && git log -1"
$SCPCMD fio-src.tar.gz root@localhost:/root/
$SSHCMD "tar xzf fio-src.tar.gz"
- name: Install dependencies on guest
run: $SSHCMD "cd fio && ./ci/actions-install.sh"
Expand Down

0 comments on commit cbd2e61

Please sign in to comment.