Browse Source

Move sr.ht yaml files from ops-hb to capsul-images

j3s/guix
j3s 6 months ago
parent
commit
85caaef017
  1. 35
      alpine/build.yaml
  2. 38
      archlinux/build.yaml
  3. 33
      debian/build.yaml
  4. 32
      guix/build.yaml
  5. 36
      openbsd/build.yaml
  6. 35
      rockylinux/build.yaml
  7. 33
      ubuntu/build.yaml

35
alpine/build.yaml

@ -0,0 +1,35 @@
image: alpine/edge
packages:
- e2fsprogs
- qemu-img
- qemu-system-x86_64
- rsync
environment:
version: 3.15
spokes:
- deploy@baikal.cyberia.club
sources:
- https://git.cyberia.club/cyberia/capsul-images
secrets:
# deploy@baikal.cyberia.club
- 923d47c9-0f27-4569-b70f-b8ee97cf7017
triggers:
- action: email
condition: failure
to: ops <ops@cyberia.club>
tasks:
- genimg: |
cd capsul-images/alpine
sudo ./build $version
- deploy: |
cd capsul-images/alpine
echo "StrictHostKeyChecking=no" >> ~/.ssh/config
for server in "${spokes[@]}"
do
ssh $server mkdir -p /tank/img/alpine/$version
rsync -rzP output/root.img.qcow2 \
${server}:/tank/img/alpine/$version/new_root.img.qcow2
ssh $server \
mv /tank/img/alpine/$version/new_root.img.qcow2 \
/tank/img/alpine/$version/root.img.qcow2
done

38
archlinux/build.yaml

@ -0,0 +1,38 @@
image: archlinux
packages:
- arch-install-scripts
- qemu-headless
- procps-ng
- rsync
- reflector
- syslinux
- pacman-contrib
environment:
spokes:
- deploy@baikal.cyberia.club
sources:
- https://git.cyberia.club/cyberia/capsul-images
secrets:
# deploy@baikal.cyberia.club
- 923d47c9-0f27-4569-b70f-b8ee97cf7017
triggers:
- action: email
condition: failure
to: ops <ops@cyberia.club>
tasks:
- genimg: |
cd capsul-images/archlinux
sudo sed -e 's/IgnorePkg.*/#IgnorePkg/' -i /etc/pacman.conf
sudo ./build
- deploy: |
echo "StrictHostKeyChecking=no" >> ~/.ssh/config
cd capsul-images/archlinux
for server in "${spokes[@]}"
do
rsync -rzP x86_64/root.img.qcow2 \
${server}:/tank/img/archlinux/new_root.img.qcow2
ssh $server \
mv /tank/img/archlinux/new_root.img.qcow2 \
/tank/img/archlinux/root.img.qcow2
done

33
debian/build.yaml vendored

@ -0,0 +1,33 @@
# this builds the capsul debian 10 template img
image: alpine/edge
packages:
- rsync
environment:
version: 10
slaves:
- deploy@baikal.cyberia.club
sources:
- https://git.cyberia.club/services/capsul-images
secrets:
# deploy@baikal.cyberia.club
- aac6b8d1-65c1-4d7f-862f-094716b800e3
triggers:
- action: email
condition: failure
to: ops <ops@cyberia.club>
tasks:
- genimg: |
cd capsul-images/debian
sudo ./build $version
- deploy: |
cd capsul-images/debian
echo "StrictHostKeyChecking=no" >> ~/.ssh/config
for server in "${slaves[@]}"
do
ssh $server mkdir -p /tank/img/debian/$version
rsync -rzP $version/root.img.qcow2 \
${server}:/tank/img/debian/$version/new_root.img.qcow2
ssh $server \
mv /tank/img/debian/$version/new_root.img.qcow2 \
/tank/img/debian/$version/root.img.qcow2
done

32
guix/build.yaml

@ -0,0 +1,32 @@
image: guix
packages:
- qemu-minimal
- rsync
environment:
spokes:
- deploy@baikal.cyberia.club
sources:
- https://git.cyberia.club/cyberia/capsul-images
secrets:
# deploy@baikal.cyberia.club
- 923d47c9-0f27-4569-b70f-b8ee97cf7017
# triggers:
# - action: email
# condition: failure
# to: ops <ops@cyberia.club>
tasks:
- genimg: |
cd capsul-images/guix
sudo ./build $version
- deploy: |
cd capsul-images/guix
echo "StrictHostKeyChecking=no" >> ~/.ssh/config
for server in "${spokes[@]}"
do
ssh $server mkdir -p /tank/img/guixsystem/$version
rsync -rzP output/root.img.qcow2 \
${server}:/tank/img/alpine/$version/new_root.img.qcow2
ssh $server \
mv /tank/img/alpine/$version/new_root.img.qcow2 \
/tank/img/alpine/$version/root.img.qcow2
done

36
openbsd/build.yaml

@ -0,0 +1,36 @@
# this builds the capsul openbsd 10 template img
image: alpine/edge
packages:
- qemu-img
- qemu-system-x86_64
- rsync
- packer
environment:
version: 6.8
slaves:
- deploy@baikal.cyberia.club
secrets:
# deploy@baikal.cyberia.club
- aac6b8d1-65c1-4d7f-862f-094716b800e3
sources:
- https://git.cyberia.club/services/capsul-images
triggers:
- action: email
condition: failure
to: ops <ops@cyberia.club>
tasks:
- genimg: |
cd capsul-images/openbsd
sudo ./build $version
- deploy: |
cd capsul-images/openbsd
echo "StrictHostKeyChecking=no" >> ~/.ssh/config
for server in "${slaves[@]}"
do
ssh $server mkdir -p /tank/img/openbsd/$version
rsync -rzP $version/output-qemu/root.img.qcow2 \
${server}:/tank/img/openbsd/$version/new_root.img.qcow2
ssh $server \
mv /tank/img/openbsd/$version/new_root.img.qcow2 \
/tank/img/openbsd/$version/root.img.qcow2
done

35
rockylinux/build.yaml

@ -0,0 +1,35 @@
image: rockylinux/latest
packages:
- e2fsprogs
- qemu-kvm
- qemu-img
- rsync
environment:
version: 8
spokes:
- deploy@baikal.cyberia.club
sources:
- https://git.cyberia.club/cyberia/capsul-images
secrets:
# deploy@baikal.cyberia.club
- 923d47c9-0f27-4569-b70f-b8ee97cf7017
# triggers:
# - action: email
# condition: failure
# to: ops <ops@cyberia.club>
tasks:
- genimg: |
cd capsul-images/rockylinux
sudo ./build $version
- deploy: |
cd capsul-images/rockylinux
echo "StrictHostKeyChecking=no" >> ~/.ssh/config
for server in "${spokes[@]}"
do
ssh $server mkdir -p /tank/img/rockylinux/$version
rsync -rzP output/root.img.qcow2 \
${server}:/tank/img/rockylinux/$version/new_root.img.qcow2
ssh $server \
mv /tank/img/rockylinux/$version/new_root.img.qcow2 \
/tank/img/rockylinux/$version/root.img.qcow2
done

33
ubuntu/build.yaml

@ -0,0 +1,33 @@
# this builds the capsul ubuntu 10 template img
image: alpine/edge
packages:
- rsync
environment:
version: 20.04
slaves:
- deploy@baikal.cyberia.club
sources:
- https://git.cyberia.club/services/capsul-images
secrets:
# deploy@baikal.cyberia.club
- aac6b8d1-65c1-4d7f-862f-094716b800e3
triggers:
- action: email
condition: failure
to: ops <ops@cyberia.club>
tasks:
- genimg: |
cd capsul-images/ubuntu
sudo ./build $version
- deploy: |
cd capsul-images/ubuntu
echo "StrictHostKeyChecking=no" >> ~/.ssh/config
for server in "${slaves[@]}"
do
ssh $server mkdir -p /tank/img/ubuntu/$version
rsync -rzP $version/root.img.qcow2 \
${server}:/tank/img/ubuntu/$version/new_root.img.qcow2
ssh $server \
mv /tank/img/ubuntu/$version/new_root.img.qcow2 \
/tank/img/ubuntu/$version/root.img.qcow2
done
Loading…
Cancel
Save