mirror of
https://github.com/JasonN3/build-container-installer.git
synced 2025-12-25 10:57:55 +01:00
add kickstart
This commit is contained in:
parent
e1a6ef1e52
commit
4d9d37904c
1 changed files with 15 additions and 3 deletions
18
.github/workflows/build-and-test.yml
vendored
18
.github/workflows/build-and-test.yml
vendored
|
|
@ -166,15 +166,27 @@ jobs:
|
||||||
|
|
||||||
- name: Add anaconda.ks to ISO
|
- name: Add anaconda.ks to ISO
|
||||||
run: |
|
run: |
|
||||||
ls
|
sudo mkdir /mnt/iso
|
||||||
|
sudo mount -o loop ${{ env.IMAGE_NAME }}-${{ env.VERSION }}.iso /mnt/iso
|
||||||
|
cp /mnt/iso/boot/grub2/grub.cfg grub.cfg
|
||||||
|
sed -i 's/quiet/console=ttyS0,115200n8/' grub.cfg
|
||||||
cat << EOF > ks.cfg
|
cat << EOF > ks.cfg
|
||||||
|
lang en_US.UTF-8
|
||||||
|
keyboard us
|
||||||
|
timezone Americas/New_York
|
||||||
|
zerombr
|
||||||
|
clearpart --all --initlabel
|
||||||
|
autopart
|
||||||
|
reboot
|
||||||
|
user --name=core --groups=wheel --password=foobar
|
||||||
EOF
|
EOF
|
||||||
xorriso -dialog on << EOF
|
xorriso -dialog on << EOF
|
||||||
-indev ${{ env.IMAGE_NAME }}-${{ env.VERSION }}.iso
|
-indev ${{ env.IMAGE_NAME }}-${{ env.VERSION }}.iso
|
||||||
-outdev test.iso
|
-outdev test.iso
|
||||||
-map ks.cfg ks.cfg
|
-map ks.cfg ks.cfg
|
||||||
-chmod 0444 ks.cfg
|
-chmod 0444 ks.cfg
|
||||||
|
-map grub.cfg boot/grub2/grub.cfg
|
||||||
|
-chmod 0444 boot/grub2/grub.cfg
|
||||||
-end
|
-end
|
||||||
EOF
|
EOF
|
||||||
implantisomd5 test.iso
|
implantisomd5 test.iso
|
||||||
|
|
@ -183,7 +195,7 @@ jobs:
|
||||||
run: |
|
run: |
|
||||||
mkfifo vm.stdout
|
mkfifo vm.stdout
|
||||||
mkfifo vm.stdin
|
mkfifo vm.stdin
|
||||||
qemu-system-x86_64 -name "Anaconda" -boot d -m 4096 -cpu kvm64 -display none -cdrom test.iso -drive file=disk.qcow2 -serial telnet:localhost:4321,server,nowait &
|
qemu-system-x86_64 -name "Anaconda" -boot d -m 4096 -cpu qemu64 -display none -cdrom test.iso -smp 2 -drive file=disk.qcow2 -serial telnet:localhost:4321,server,nowait &
|
||||||
timeout 1m bash -c "while ! (echo > /dev/tcp/127.0.0.1/4321); do sleep 0.1; done"
|
timeout 1m bash -c "while ! (echo > /dev/tcp/127.0.0.1/4321); do sleep 0.1; done"
|
||||||
nc localhost 4321 > vm.stdout < vm.stdin &
|
nc localhost 4321 > vm.stdout < vm.stdin &
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue