~xenrox/builds

3bc677f1040a42d32c8337df01815edde0298ab0 — Thorben Günther 7 months ago 4253bf9
Remove alpine
1 files changed, 0 insertions(+), 48 deletions(-)

D alpine/build.yml
D alpine/build.yml => alpine/build.yml +0 -48
@@ 1,48 0,0 @@
image: alpine/edge
packages:
  - e2fsprogs
  - qemu-img
  - qemu-system-x86_64
  - rsync
  - sfdisk
sources:
  - https://git.sr.ht/~sircmpwn/builds.sr.ht
environment:
  arch: x86_64
  release: edge
  slaves:
    - deploy@xenrox.net
secrets:
  - fbb95ce7-421f-4c32-bc8b-5b0337500708
triggers:
  - action: email
    condition: failure
    to: Thorben Günther <admin@xenrox.net>
tasks:
  - genimg: |
      cd builds.sr.ht/images/alpine/$release
      sudo ./genimg $arch
  - kvm: |
      if grep -i amd /proc/cpuinfo
      then
          sudo modprobe kvm_amd
      else
          sudo modprobe kvm_intel
      fi
      sleep 1
      sudo chown build:build /dev/kvm
  - sanity-check: |
      cd builds.sr.ht
      MEMORY=1024 ./images/control alpine/$release sanity-check
  - deploy: |
      cd builds.sr.ht/images/alpine/$release
      echo "StrictHostKeyChecking=no" >> ~/.ssh/config
      for server in "${slaves[@]}"
      do
        ssh $server mkdir -p /var/lib/images/alpine/$release/$arch
        rsync -rzzP $arch/root.img.qcow2 \
          ${server}:/var/lib/images/alpine/$release/$arch/new_root.img.qcow2
        ssh $server \
          mv /var/lib/images/alpine/$release/$arch/new_root.img.qcow2 \
             /var/lib/images/alpine/$release/$arch/root.img.qcow2
      done