diff options
| author | Raúl Benencia <id@rbenencia.name> | 2026-06-05 18:04:23 -0300 |
|---|---|---|
| committer | Raul Benencia <46945030+raul-te@users.noreply.github.com> | 2026-06-05 21:19:48 -0300 |
| commit | bd19522778257e41d23ac15a5adfc35455f9e310 (patch) | |
| tree | a7c57be18645f27754939df27dd693081cbd9935 | |
| parent | f8e69cddb3a2a18100d3093f27c709c4361c1692 (diff) | |
Update example templates to modern distros
Replace CoreOS (EOL) with Flatcar Linux using Ignition v3.
Replace CentOS (EOL) with AlmaLinux using a kickstart template.
Update Ubuntu templates to jammy with current archive mirror paths.
Update Debian template to bookworm.
Drop CoreOS cloud-config; add Flatcar Ignition example.
Update mappings.yaml, test configs, fixtures, and smoke test accordingly.
29 files changed, 158 insertions, 219 deletions
diff --git a/configs/data-dir/cloud-config/cloud-config-release.slc b/configs/data-dir/cloud-config/cloud-config-release.slc deleted file mode 100644 index 0f3de35..0000000 --- a/configs/data-dir/cloud-config/cloud-config-release.slc +++ /dev/null @@ -1,13 +0,0 @@ -{{define "cloudconfig-coreos" -}} -#cloud-config -{{template "cloudconfig-coreos-users"}} - -hostname:{{.hostname}} -coreos: - update: - reboot-strategy: off - units: - - name: update-engine.service - enable: true - command: start -{{end}} diff --git a/configs/data-dir/cloud-config/users.slc b/configs/data-dir/cloud-config/users.slc deleted file mode 100644 index 6ebdd3f..0000000 --- a/configs/data-dir/cloud-config/users.slc +++ /dev/null @@ -1,11 +0,0 @@ -{{define "cloudconfig-coreos-users"}} -users: - - name: "shoelaces" - groups: - - "sudo" - - "docker" - ssh-authorized-keys: - - "ssh-rsa fake-key shoelaces@example.com" -ssh_authorized_keys: - - "ssh-rsa fake-key shoelaces@example.com" -{{end}} diff --git a/configs/data-dir/ignition/flatcar.ign.slc b/configs/data-dir/ignition/flatcar.ign.slc new file mode 100644 index 0000000..0620f27 --- /dev/null +++ b/configs/data-dir/ignition/flatcar.ign.slc @@ -0,0 +1,22 @@ +{{define "ignition/flatcar" -}} +{ + "ignition": { "version": "3.4.0" }, + "passwd": { + "users": [ + { + "name": "core", + "sshAuthorizedKeys": ["ssh-rsa AAAA... user@example.com"] + } + ] + }, + "storage": { + "files": [ + { + "path": "/etc/hostname", + "contents": { "source": "data:,{{.hostname}}" }, + "mode": 420 + } + ] + } +} +{{end}} diff --git a/configs/data-dir/ipxe/almalinux.ipxe.slc b/configs/data-dir/ipxe/almalinux.ipxe.slc new file mode 100644 index 0000000..9dbfd57 --- /dev/null +++ b/configs/data-dir/ipxe/almalinux.ipxe.slc @@ -0,0 +1,14 @@ +{{define "almalinux.ipxe" -}} +#!ipxe +set hostname {{.hostname}} +set release {{.release}} +set base https://repo.almalinux.org/almalinux/${release}/BaseOS/x86_64/os + +echo This automatically overwrites data! +echo AlmaLinux ${release} +echo Installing ${hostname} + +kernel ${base}/images/pxeboot/vmlinuz initrd=initrd.img repo=${base} inst.ks=http://{{.baseURL}}/configs/kickstart/almalinux?hostname=${hostname}&release=${release} console=tty0 console=ttyS0,115200n8 +initrd ${base}/images/pxeboot/initrd.img +boot +{{end}} diff --git a/configs/data-dir/ipxe/centos.ipxe.slc b/configs/data-dir/ipxe/centos.ipxe.slc deleted file mode 100644 index 88b3fc2..0000000 --- a/configs/data-dir/ipxe/centos.ipxe.slc +++ /dev/null @@ -1,14 +0,0 @@ -{{define "centos.ipxe" -}} -#!ipxe -set hostname {{.hostname}} -set release {{.release}} -set base http://mirror.centos.org/centos/${release}/os/x86_64 - -echo This automatically overwrites data! -echo CentOS ${release} -echo Installing ${hostname} - -kernel ${base}/images/pxeboot/vmlinuz initrd=initrd.img repo=${base} ks=http://{{.baseURL}}/configs/centos.ks?hostname=${hostname}&release=${release} -initrd ${base}/images/pxeboot/initrd.img -boot -{{end}} diff --git a/configs/data-dir/ipxe/coreos.ipxe.slc b/configs/data-dir/ipxe/coreos.ipxe.slc deleted file mode 100644 index 64685ff..0000000 --- a/configs/data-dir/ipxe/coreos.ipxe.slc +++ /dev/null @@ -1,16 +0,0 @@ -{{define "coreos.ipxe" -}} -#!ipxe - -set coreos-url http://stable.release.core-os.net/amd64-usr/current - -echo This will currently autologin into tty1 on the console. -echo From there you can su to root and install CoreOS to disk using: -echo coreos-install -d /dev/sda -C {{.release}} -echo You will probably need to chroot into /dev/sda9 to configure accounts. -echo More info @ http://coreos.com/docs/running-coreos/bare-metal/installing-to-disk/ - -kernel ${coreos-url}/coreos_production_pxe.vmlinuz cloud-config-url=http://{{.baseURL}}/configs/cloudconfig-coreos?release={{.release}}&hostname={{.hostname}} console=tty1 coreos.autologin=tty1 -initrd ${coreos-url}/coreos_production_pxe_image.cpio.gz - -boot -{{end}}
\ No newline at end of file diff --git a/configs/data-dir/ipxe/debian.ipxe.slc b/configs/data-dir/ipxe/debian.ipxe.slc index 6a29bbd..7c78cc2 100644 --- a/configs/data-dir/ipxe/debian.ipxe.slc +++ b/configs/data-dir/ipxe/debian.ipxe.slc @@ -10,7 +10,7 @@ chain http://{{.baseURL}}/configs/linux.cfg?hostname={{.hostname}} imgfree -kernel ${mirror}/linux auto=true priority=critical initrd=initrd.gz keyboard-configuration/xkb-keymap=us preseed/url=http://{{.baseURL}}/configs/preseeds/debian?encrypt_home={{.encrypt_home}} ${linuxargs} +kernel ${mirror}/linux auto=true priority=critical initrd=initrd.gz keyboard-configuration/xkb-keymap=us preseed/url=http://{{.baseURL}}/configs/preseeds/debian?hostname={{.hostname}} ${linuxargs} initrd ${mirror}/initrd.gz boot {{end}} diff --git a/configs/data-dir/ipxe/flatcar.ipxe.slc b/configs/data-dir/ipxe/flatcar.ipxe.slc new file mode 100644 index 0000000..8ecfdda --- /dev/null +++ b/configs/data-dir/ipxe/flatcar.ipxe.slc @@ -0,0 +1,10 @@ +{{define "flatcar.ipxe" -}} +#!ipxe + +set flatcar-url https://stable.release.flatcar-linux.net/amd64-usr/{{.version}} + +kernel ${flatcar-url}/flatcar_production_pxe.vmlinuz initrd=flatcar_production_pxe_image.cpio.gz flatcar.first_boot=1 ignition.config.url=http://{{.baseURL}}/configs/ignition/flatcar?hostname={{.hostname}} +initrd ${flatcar-url}/flatcar_production_pxe_image.cpio.gz + +boot +{{end}} diff --git a/configs/data-dir/ipxe/storage.ipxe.slc b/configs/data-dir/ipxe/storage.ipxe.slc index 174949d..64d410b 100644 --- a/configs/data-dir/ipxe/storage.ipxe.slc +++ b/configs/data-dir/ipxe/storage.ipxe.slc @@ -2,9 +2,9 @@ #!ipxe echo This automatically overwrites data! -echo Ubuntu {{.release}} amd64 storage +echo Ubuntu {{.release}} storage (RAID) -set mirror http://mirror.rackspace.com/ubuntu/dists/{{.release}}/main/installer-amd64/current/images/netboot/ubuntu-installer/amd64 +set mirror http://archive.ubuntu.com/ubuntu/dists/{{.release}}/main/installer-amd64/current/legacy-images/netboot/ubuntu-installer/amd64 chain --autofree http://{{.baseURL}}/configs/linux.cfg?hostname={{.hostname}} @@ -13,4 +13,4 @@ imgfree kernel ${mirror}/linux auto=true priority=critical initrd=initrd.gz preseed/url=http://{{.baseURL}}/configs/preseeds/storage ${linuxargs} initrd ${mirror}/initrd.gz boot -{{end}}
\ No newline at end of file +{{end}} diff --git a/configs/data-dir/ipxe/ubuntu-minimal.ipxe.slc b/configs/data-dir/ipxe/ubuntu-minimal.ipxe.slc deleted file mode 100644 index ef4e61e..0000000 --- a/configs/data-dir/ipxe/ubuntu-minimal.ipxe.slc +++ /dev/null @@ -1,16 +0,0 @@ -{{define "ubuntu-minimal.ipxe" -}} -#!ipxe - -echo This automatically overwrites data! -echo Ubuntu {{.release}} minimal - -set mirror http://mirror.rackspace.com/ubuntu/dists/{{.release}}/main/installer-amd64/current/images/netboot/ubuntu-installer/amd64 - -chain http://{{.baseURL}}/configs/linux.cfg?hostname={{.hostname}} - -imgfree - -kernel ${mirror}/linux auto=true priority=critical initrd=initrd.gz preseed/url=http://{{.baseURL}}/configs/preseeds/ubuntu-minimal ${linuxargs} -initrd ${mirror}/initrd.gz -boot -{{end}} diff --git a/configs/data-dir/ipxe/ubuntu.ipxe.slc b/configs/data-dir/ipxe/ubuntu.ipxe.slc new file mode 100644 index 0000000..521b5a9 --- /dev/null +++ b/configs/data-dir/ipxe/ubuntu.ipxe.slc @@ -0,0 +1,16 @@ +{{define "ubuntu.ipxe" -}} +#!ipxe + +echo This automatically overwrites data! +echo Ubuntu {{.release}} + +set mirror http://archive.ubuntu.com/ubuntu/dists/{{.release}}/main/installer-amd64/current/legacy-images/netboot/ubuntu-installer/amd64 + +chain http://{{.baseURL}}/configs/linux.cfg?hostname={{.hostname}} + +imgfree + +kernel ${mirror}/linux auto=true priority=critical initrd=initrd.gz preseed/url=http://{{.baseURL}}/configs/preseeds/ubuntu?hostname={{.hostname}} ${linuxargs} +initrd ${mirror}/initrd.gz +boot +{{end}} diff --git a/configs/data-dir/kickstart/almalinux.ks.slc b/configs/data-dir/kickstart/almalinux.ks.slc new file mode 100644 index 0000000..1ebcdcf --- /dev/null +++ b/configs/data-dir/kickstart/almalinux.ks.slc @@ -0,0 +1,33 @@ +{{define "kickstart/almalinux" -}} +text +reboot + +url --url="https://repo.almalinux.org/almalinux/{{.release}}/BaseOS/x86_64/os" + +network --bootproto=dhcp --hostname={{.hostname}} + +rootpw --plaintext changeme +authselect select minimal + +keyboard --vckeymap=us --xlayouts=us +lang en_US.UTF-8 +timezone UTC --utc + +zerombr +clearpart --all --drives=sda --initlabel +bootloader --append="console=tty0 console=ttyS0,115200n8" --location=mbr +part biosboot --fstype=biosboot --size=1 +part /boot --fstype=ext4 --size=1024 +part pv.01 --size=1 --grow +volgroup vg0 pv.01 +logvol swap --vgname=vg0 --size=2048 --name=lv_swap +logvol / --fstype=xfs --vgname=vg0 --size=1 --grow --name=lv_root + +%packages +@^minimal-environment +%end + +%post +hostnamectl set-hostname {{.hostname}} +%end +{{end}} diff --git a/configs/data-dir/kickstart/centos.ks.slc b/configs/data-dir/kickstart/centos.ks.slc deleted file mode 100644 index 04d5455..0000000 --- a/configs/data-dir/kickstart/centos.ks.slc +++ /dev/null @@ -1,36 +0,0 @@ -{{define "centos.ks" -}} -logging --level=info -cmdline - -url --url="http://mirror.netcologne.de/centos/{{.release}}/os/x86_64" - -network --bootproto dhcp --hostname {{.hostname}} - -rootpw root -auth --useshadow --passalgo=sha512 --enablefingerprint - -keyboard --vckeymap=de --xlayouts='de (nodeadkeys)' -lang en_US.UTF-8 -timezone Europe/Berlin --isUtc -zerombr -clearpart --drives=sda --all --disklabel=gpt -bootloader --append="crashkernel=auto panic=60" --location=mbr -part biosboot --fstype=biosboot --size=1 -part /boot --fstype="ext4" --ondisk=sda --size=500 --label=/boot -part swap --fstype="swap" --ondisk=sda --size=8000 -part pv.01 --size=1000 --grow --ondisk=sda -volgroup vg0 pv.01 -logvol / --fstype="ext4" --vgname=vg0 --size=10000 --name=lv_root --grow - -%packages -@core -%end - -%post -#!/bin/bash -hostnamectl set-hostname {{.hostname}} -echo -e "\n#######################\n # Finished Post Tasks\n#######################\n" -sleep 5 -%end -reboot -{{end}}
\ No newline at end of file diff --git a/configs/data-dir/mappings.yaml b/configs/data-dir/mappings.yaml index dfcb8c9..a0f11c1 100644 --- a/configs/data-dir/mappings.yaml +++ b/configs/data-dir/mappings.yaml @@ -1,17 +1,17 @@ networkMaps: - network: 192.168.0.0/24 script: - name: ubuntu-minimal.ipxe + name: ubuntu.ipxe params: - release: xenial + release: jammy - network: 10.0.10.0/24 script: - name: coreos.ipxe + name: flatcar.ipxe params: - release: stable + version: stable hostnameMaps: - hostname: msc1.example.com script: - name: ubuntu-minimal.ipxe + name: debian.ipxe params: - release: trusty + release: bookworm diff --git a/configs/data-dir/preseed/debian.preseed.slc b/configs/data-dir/preseed/debian.preseed.slc index ab37afc..a8a2878 100644 --- a/configs/data-dir/preseed/debian.preseed.slc +++ b/configs/data-dir/preseed/debian.preseed.slc @@ -15,12 +15,10 @@ d-i partman/choose_partition select finish d-i partman/confirm boolean true d-i partman/confirm_nooverwrite boolean true -d-i user-setup/encrypt-home boolean {{.encrypt_home}} - d-i base-installer/install-recommends boolean true d-i clock-setup/utc boolean true -d-i time/zone string America/Los_Angeles +d-i time/zone string UTC d-i clock-setup/ntp boolean true diff --git a/configs/data-dir/preseed/ubuntu-minimal.preseed.slc b/configs/data-dir/preseed/ubuntu.preseed.slc index 08013ff..128622c 100644 --- a/configs/data-dir/preseed/ubuntu-minimal.preseed.slc +++ b/configs/data-dir/preseed/ubuntu.preseed.slc @@ -1,4 +1,4 @@ -{{define "preseeds/ubuntu-minimal" -}} +{{define "preseeds/ubuntu" -}} {{template "preseeds/common"}} d-i partman-auto/method string regular @@ -7,7 +7,6 @@ d-i partman-md/device_remove_md boolean true d-i partman-lvm/confirm boolean true d-i partman-lvm/confirm_nooverwrite boolean true -# atomic: Just one partition d-i partman-auto/choose_recipe select atomic d-i partman-partitioning/confirm_write_new_label boolean true @@ -15,18 +14,13 @@ d-i partman/choose_partition select finish d-i partman/confirm boolean true d-i partman/confirm_nooverwrite boolean true -d-i user-setup/encrypt-home boolean false - d-i base-installer/install-recommends boolean true d-i clock-setup/utc boolean true -d-i time/zone string America/Los_Angeles +d-i time/zone string UTC d-i clock-setup/ntp boolean true -d-i debian-installer/quiet boolean false -d-i debian-installer/splash boolean false - d-i pkgsel/update-policy select unattended-upgrades d-i grub-installer/timeout string 5 diff --git a/test/integ-test/expected-results/ipxemenu.txt b/test/integ-test/expected-results/ipxemenu.txt index 412ea6f..a10a4f9 100644 --- a/test/integ-test/expected-results/ipxemenu.txt +++ b/test/integ-test/expected-results/ipxemenu.txt @@ -1,7 +1,7 @@ #!ipxe menu Choose target to boot -item /configs/coreos.ipxe coreos.ipxe -item /env/production/configs/coreos.ipxe coreos.ipxe [production] +item /configs/flatcar.ipxe flatcar.ipxe +item /env/production/configs/flatcar.ipxe flatcar.ipxe [production] choose target echo -n Enter hostname or none: diff --git a/test/integ-test/expected-results/poll-k8s1-1.txt b/test/integ-test/expected-results/poll-k8s1-1.txt index 46043fd..9a2fa77 100644 --- a/test/integ-test/expected-results/poll-k8s1-1.txt +++ b/test/integ-test/expected-results/poll-k8s1-1.txt @@ -1,14 +1,8 @@ #!ipxe -set coreos-url http://stable.release.core-os.net/amd64-usr/1122.3.0 +set flatcar-url https://stable.release.flatcar-linux.net/amd64-usr/1122.3.0 -echo This will currently autologin into tty1 on the console. -echo From there you can su to root and install CoreOS to disk using: -echo coreos-install -d /dev/sda -C stable -echo You will probably need to chroot into /dev/sda9 to configure accounts. -echo More info @ http://coreos.com/docs/running-coreos/bare-metal/installing-to-disk/ - -kernel ${coreos-url}/coreos_production_pxe.vmlinuz cloud-config-url=http://localhost:18888/configs/coreos-baremetal.yaml?release=stable console=tty1 coreos.autologin=tty1 -initrd ${coreos-url}/coreos_production_pxe_image.cpio.gz +kernel ${flatcar-url}/flatcar_production_pxe.vmlinuz initrd=flatcar_production_pxe_image.cpio.gz flatcar.first_boot=1 ignition.config.url=http://localhost:18888/configs/ignition/baremetal +initrd ${flatcar-url}/flatcar_production_pxe_image.cpio.gz boot diff --git a/test/integ-test/expected-results/poll-k8s1-2.txt b/test/integ-test/expected-results/poll-k8s1-2.txt index 46043fd..9a2fa77 100644 --- a/test/integ-test/expected-results/poll-k8s1-2.txt +++ b/test/integ-test/expected-results/poll-k8s1-2.txt @@ -1,14 +1,8 @@ #!ipxe -set coreos-url http://stable.release.core-os.net/amd64-usr/1122.3.0 +set flatcar-url https://stable.release.flatcar-linux.net/amd64-usr/1122.3.0 -echo This will currently autologin into tty1 on the console. -echo From there you can su to root and install CoreOS to disk using: -echo coreos-install -d /dev/sda -C stable -echo You will probably need to chroot into /dev/sda9 to configure accounts. -echo More info @ http://coreos.com/docs/running-coreos/bare-metal/installing-to-disk/ - -kernel ${coreos-url}/coreos_production_pxe.vmlinuz cloud-config-url=http://localhost:18888/configs/coreos-baremetal.yaml?release=stable console=tty1 coreos.autologin=tty1 -initrd ${coreos-url}/coreos_production_pxe_image.cpio.gz +kernel ${flatcar-url}/flatcar_production_pxe.vmlinuz initrd=flatcar_production_pxe_image.cpio.gz flatcar.first_boot=1 ignition.config.url=http://localhost:18888/configs/ignition/baremetal +initrd ${flatcar-url}/flatcar_production_pxe_image.cpio.gz boot diff --git a/test/integ-test/expected-results/poll-k8s1-3-stg.txt b/test/integ-test/expected-results/poll-k8s1-3-stg.txt index 46043fd..9a2fa77 100644 --- a/test/integ-test/expected-results/poll-k8s1-3-stg.txt +++ b/test/integ-test/expected-results/poll-k8s1-3-stg.txt @@ -1,14 +1,8 @@ #!ipxe -set coreos-url http://stable.release.core-os.net/amd64-usr/1122.3.0 +set flatcar-url https://stable.release.flatcar-linux.net/amd64-usr/1122.3.0 -echo This will currently autologin into tty1 on the console. -echo From there you can su to root and install CoreOS to disk using: -echo coreos-install -d /dev/sda -C stable -echo You will probably need to chroot into /dev/sda9 to configure accounts. -echo More info @ http://coreos.com/docs/running-coreos/bare-metal/installing-to-disk/ - -kernel ${coreos-url}/coreos_production_pxe.vmlinuz cloud-config-url=http://localhost:18888/configs/coreos-baremetal.yaml?release=stable console=tty1 coreos.autologin=tty1 -initrd ${coreos-url}/coreos_production_pxe_image.cpio.gz +kernel ${flatcar-url}/flatcar_production_pxe.vmlinuz initrd=flatcar_production_pxe_image.cpio.gz flatcar.first_boot=1 ignition.config.url=http://localhost:18888/configs/ignition/baremetal +initrd ${flatcar-url}/flatcar_production_pxe_image.cpio.gz boot diff --git a/test/integ-test/expected-results/poll-k8s1-4-stg.txt b/test/integ-test/expected-results/poll-k8s1-4-stg.txt index 6195e9e..cd61e34 100644 --- a/test/integ-test/expected-results/poll-k8s1-4-stg.txt +++ b/test/integ-test/expected-results/poll-k8s1-4-stg.txt @@ -1,14 +1,8 @@ #!ipxe -set coreos-url http://stable.release.core-os.net/amd64-usr/1298.6.0 +set flatcar-url https://stable.release.flatcar-linux.net/amd64-usr/1298.6.0 -echo This will currently autologin into tty1 on the console. -echo From there you can su to root and install CoreOS to disk using: -echo coreos-install -d /dev/sda -C stable -echo You will probably need to chroot into /dev/sda9 to configure accounts. -echo More info @ http://coreos.com/docs/running-coreos/bare-metal/installing-to-disk/ - -kernel ${coreos-url}/coreos_production_pxe.vmlinuz cloud-config-url=http://localhost:18888/env/staging/configs/coreos-baremetal.yaml?release=stable console=tty1 coreos.autologin=tty1 -initrd ${coreos-url}/coreos_production_pxe_image.cpio.gz +kernel ${flatcar-url}/flatcar_production_pxe.vmlinuz initrd=flatcar_production_pxe_image.cpio.gz flatcar.first_boot=1 ignition.config.url=http://localhost:18888/env/staging/configs/ignition/baremetal +initrd ${flatcar-url}/flatcar_production_pxe_image.cpio.gz boot diff --git a/test/integ-test/expected-results/poll-unknown-set-from-ui.txt b/test/integ-test/expected-results/poll-unknown-set-from-ui.txt index 08e161e..9ac72f3 100644 --- a/test/integ-test/expected-results/poll-unknown-set-from-ui.txt +++ b/test/integ-test/expected-results/poll-unknown-set-from-ui.txt @@ -1,14 +1,8 @@ #!ipxe -set coreos-url http://stable.release.core-os.net/amd64-usr/666.0 +set flatcar-url https://stable.release.flatcar-linux.net/amd64-usr/666.0 -echo This will currently autologin into tty1 on the console. -echo From there you can su to root and install CoreOS to disk using: -echo coreos-install -d /dev/sda -C stable -echo You will probably need to chroot into /dev/sda9 to configure accounts. -echo More info @ http://coreos.com/docs/running-coreos/bare-metal/installing-to-disk/ - -kernel ${coreos-url}/coreos_production_pxe.vmlinuz cloud-config-url=http://localhost:18888/configs/coreos-virtual.yaml?release=stable console=tty1 coreos.autologin=tty1 -initrd ${coreos-url}/coreos_production_pxe_image.cpio.gz +kernel ${flatcar-url}/flatcar_production_pxe.vmlinuz initrd=flatcar_production_pxe_image.cpio.gz flatcar.first_boot=1 ignition.config.url=http://localhost:18888/configs/ignition/virtual +initrd ${flatcar-url}/flatcar_production_pxe_image.cpio.gz boot diff --git a/test/integ-test/frontend_smoke.js b/test/integ-test/frontend_smoke.js index e9ac50a..bd7be63 100644 --- a/test/integ-test/frontend_smoke.js +++ b/test/integ-test/frontend_smoke.js @@ -370,7 +370,7 @@ async function run() { const mac = document.getElementById('mac'); const target = document.getElementById('target'); mac.value = '${smokeMac}'; - target.value = 'coreos.ipxe'; + target.value = 'flatcar.ipxe'; target.dispatchEvent(new Event('change', { bubbles: true })); return true; })()`); @@ -424,7 +424,7 @@ async function run() { ); const eventText = await evaluate(cdp, sessionID, 'document.querySelector(".event-log").textContent'); - if (!eventText.includes('A user selected coreos.ipxe')) { + if (!eventText.includes('A user selected flatcar.ipxe')) { throw new Error('Event history did not render user selection: ' + eventText); } diff --git a/test/integ-test/integ-test-configs/env_overrides/production/ipxe/coreos.ipxe.slc b/test/integ-test/integ-test-configs/env_overrides/production/ipxe/coreos.ipxe.slc deleted file mode 100644 index f60b478..0000000 --- a/test/integ-test/integ-test-configs/env_overrides/production/ipxe/coreos.ipxe.slc +++ /dev/null @@ -1,16 +0,0 @@ -{{define "coreos.ipxe" -}} -#!ipxe - -set coreos-url http://stable.release.core-os.net/amd64-usr/{{.version}} - -echo This will currently autologin into tty1 on the console. -echo From there you can su to root and install CoreOS to disk using: -echo coreos-install -d /dev/sda -C stable -echo You will probably need to chroot into /dev/sda9 to configure accounts. -echo More info @ http://coreos.com/docs/running-coreos/bare-metal/installing-to-disk/ - -kernel ${coreos-url}/coreos_production_pxe.vmlinuz cloud-config-url=http://{{.baseURL}}/configs/coreos-{{.cloudconfig}}.yaml?release=stable&hostname={{.hostname}} console=tty1 coreos.autologin=tty1 -initrd ${coreos-url}/coreos_production_pxe_image.cpio.gz - -boot -{{end}} diff --git a/test/integ-test/integ-test-configs/env_overrides/production/ipxe/flatcar.ipxe.slc b/test/integ-test/integ-test-configs/env_overrides/production/ipxe/flatcar.ipxe.slc new file mode 100644 index 0000000..4d6cc93 --- /dev/null +++ b/test/integ-test/integ-test-configs/env_overrides/production/ipxe/flatcar.ipxe.slc @@ -0,0 +1,10 @@ +{{define "flatcar.ipxe" -}} +#!ipxe + +set flatcar-url https://stable.release.flatcar-linux.net/amd64-usr/{{.version}} + +kernel ${flatcar-url}/flatcar_production_pxe.vmlinuz initrd=flatcar_production_pxe_image.cpio.gz flatcar.first_boot=1 ignition.config.url=http://{{.baseURL}}/configs/ignition/{{.cloudconfig}}?hostname={{.hostname}} +initrd ${flatcar-url}/flatcar_production_pxe_image.cpio.gz + +boot +{{end}} diff --git a/test/integ-test/integ-test-configs/ipxe/coreos.ipxe.slc b/test/integ-test/integ-test-configs/ipxe/coreos.ipxe.slc deleted file mode 100644 index 7cb5156..0000000 --- a/test/integ-test/integ-test-configs/ipxe/coreos.ipxe.slc +++ /dev/null @@ -1,16 +0,0 @@ -{{define "coreos.ipxe" -}} -#!ipxe - -set coreos-url http://stable.release.core-os.net/amd64-usr/{{.version}} - -echo This will currently autologin into tty1 on the console. -echo From there you can su to root and install CoreOS to disk using: -echo coreos-install -d /dev/sda -C stable -echo You will probably need to chroot into /dev/sda9 to configure accounts. -echo More info @ http://coreos.com/docs/running-coreos/bare-metal/installing-to-disk/ - -kernel ${coreos-url}/coreos_production_pxe.vmlinuz cloud-config-url=http://{{.baseURL}}/configs/coreos-{{.cloudconfig}}.yaml?release=stable console=tty1 coreos.autologin=tty1 -initrd ${coreos-url}/coreos_production_pxe_image.cpio.gz - -boot -{{end}} diff --git a/test/integ-test/integ-test-configs/ipxe/flatcar.ipxe.slc b/test/integ-test/integ-test-configs/ipxe/flatcar.ipxe.slc new file mode 100644 index 0000000..9fd381b --- /dev/null +++ b/test/integ-test/integ-test-configs/ipxe/flatcar.ipxe.slc @@ -0,0 +1,10 @@ +{{define "flatcar.ipxe" -}} +#!ipxe + +set flatcar-url https://stable.release.flatcar-linux.net/amd64-usr/{{.version}} + +kernel ${flatcar-url}/flatcar_production_pxe.vmlinuz initrd=flatcar_production_pxe_image.cpio.gz flatcar.first_boot=1 ignition.config.url=http://{{.baseURL}}/configs/ignition/{{.cloudconfig}} +initrd ${flatcar-url}/flatcar_production_pxe_image.cpio.gz + +boot +{{end}} diff --git a/test/integ-test/integ-test-configs/mappings.yaml b/test/integ-test/integ-test-configs/mappings.yaml index 534b72f..36976a0 100644 --- a/test/integ-test/integ-test-configs/mappings.yaml +++ b/test/integ-test/integ-test-configs/mappings.yaml @@ -1,39 +1,39 @@ networkMaps: - network: 20.20.20.20/24 script: - name: ubuntu-minimal.ipxe + name: ubuntu.ipxe params: hostname: placeholder hostnameMaps: - hostname: '(etcd|k8s)\d-m\d' script: - name: coreos.ipxe + name: flatcar.ipxe params: version: 1122.3.0 cloudconfig: virtual - hostname: '(etcd|k8s)\d-m\d' script: - name: coreos.ipxe + name: flatcar.ipxe params: version: 1122.3.0 cloudconfig: virtual - hostname: 'k8s1-4' script: - name: coreos.ipxe + name: flatcar.ipxe environment: staging params: version: 1298.6.0 cloudconfig: baremetal - hostname: 'k8s1-\d' script: - name: coreos.ipxe + name: flatcar.ipxe params: version: 1122.3.0 cloudconfig: baremetal - hostname: 'k8s1-\d' script: - name: coreos.ipxe + name: flatcar.ipxe params: version: 1122.3.0 cloudconfig: baremetal diff --git a/test/integ-test/integ_test.py b/test/integ-test/integ_test.py index a821551..f479e29 100755 --- a/test/integ-test/integ_test.py +++ b/test/integ-test/integ_test.py @@ -172,7 +172,7 @@ def test_unknown_server(shoelaces_instance): assert requests.get(poll_url).text == poll.read() # Setting the config for the new host should succeed. requests.post(API_URL + '/update/target', - {"target": "coreos.ipxe", + {"target": "flatcar.ipxe", "mac": "06:66:de:ad:be:ef", "version": "666.0", "cloudconfig": "virtual"}).raise_for_status() @@ -209,7 +209,7 @@ def test_events(shoelaces_instance): 'cloudconfig': 'virtual', 'hostname': '06-66-de-ad-be-ef', 'version': '666.0'}, - 'script': 'coreos.ipxe'}) + 'script': 'flatcar.ipxe'}) POLL_PAIRS = [(None, "poll.txt"), @@ -229,9 +229,9 @@ def test_poll(shoelaces_instance, params, expected): assert poll.read() == req.text -TPL_VARS_PAIRS = [("coreos.ipxe", "", ["cloudconfig", "version"]), - ("coreos.ipxe", "default", ["cloudconfig", "version"]), - ("coreos.ipxe", "production", ["cloudconfig", "version", "hostname"])] +TPL_VARS_PAIRS = [("flatcar.ipxe", "", ["cloudconfig", "version"]), + ("flatcar.ipxe", "default", ["cloudconfig", "version"]), + ("flatcar.ipxe", "production", ["cloudconfig", "version", "hostname"])] @pytest.mark.parametrize(("script", "env", "vars"), TPL_VARS_PAIRS) |
