From 3cb88b0ca8bed0c4008411b68b0b754dba1a7e7d Mon Sep 17 00:00:00 2001 From: Jacob Moody Date: Tue, 4 Apr 2023 16:00:53 -0600 Subject: [PATCH] images/9front: Add genimg and build.yml --- images/9front/build.yml | 18 ++++++++++++++++++ images/9front/genimg | 38 ++++++++++++++++++++++++++++++++++++++ images/9front/latest | 1 + 3 files changed, 57 insertions(+) create mode 100644 images/9front/build.yml create mode 100755 images/9front/genimg create mode 100644 images/9front/latest diff --git a/images/9front/build.yml b/images/9front/build.yml new file mode 100644 index 0000000..dbe2a10 --- /dev/null +++ b/images/9front/build.yml @@ -0,0 +1,18 @@ +image: 9front +sources: + - https://git.sr.ht/~sircmpwn/builds.sr.ht +environment: + arch: x86_64 + release: "27a63ae22975171efbee5549d100f416ccb4066a" + slaves: +# - deploy@cirno1.sr.ht + - deploy@cirno2.sr.ht +secrets: + - fa00a8d3-7b63-42d5-8060-3bb31c3e3018 +triggers: + - action: email + condition: failure + to: Drew DeVault +tasks: + - genimg: | + ./builds.sr.ht/images/9front/genimg diff --git a/images/9front/genimg b/images/9front/genimg new file mode 100755 index 0000000..5f93f88 --- /dev/null +++ b/images/9front/genimg @@ -0,0 +1,38 @@ +#!/bin/rc +rfork en +latest=`{cat builds.sr.ht/images/9front/latest} +hget http://git.9front.org/git/plan9front/plan9front/^$latest^/snap.tar.gz > 9front.tgz +gunzip 9front.tgz +tar xf 9front.tar +mv 9front-* 9front +cd 9front +. ./sys/lib/rootstub +. ./sys/lib/rootbind +cd /sys/src/ +mk install +cd /sys/src/9/pc64 +mk install +cd /sys/lib/dist +bind $home/9front/$cputype /$cputype +bind $home/9front/rc /rc +bind -b /rc/bin /bin +bind -b /$cputype/bin /bin +bind $home/9front /n/src9/ +#inherit configuration +bind /lib/ndb/local /n/src9/lib/ndb/local +bind /usr/glenda/lib/profile usr/glenda/lib/profile +sed 's,echo ''bootfile.*,cat /n/9fat/plan9.ini >/env/plan9.ini,g' mkfile >mkfile.2 +mv mkfile.2 mkfile +bind -a '#S' /dev +9fs 9fat +mk new.amd64.qcow2 +nvram=/dev/*/nvram +@{rfork n + disk/qcowfs new.amd64.qcow2 + disk/partfs /mnt/qcow/data + disk/fdisk -p /dev/sdXX/data >> /dev/sdXX/ctl + disk/prep -p /dev/sdXX/plan9 >> /dev/sdXX/ctl + cp $nvram /dev/sdXX/nvram +} +unmount /n/9fat +rm /srv/dos diff --git a/images/9front/latest b/images/9front/latest new file mode 100644 index 0000000..e526ab1 --- /dev/null +++ b/images/9front/latest @@ -0,0 +1 @@ +27a63ae22975171efbee5549d100f416ccb4066a -- 2.38.5