Skip to content
This repository was archived by the owner on Jun 29, 2022. It is now read-only.

Commit e5f0458

Browse files
committed
baremetal: use ignition.config.url kernel parameter
The Ignition configuration got written out only once to the OEM partition and any updates to it in the matchbox store were not propagated to the node's Ignition environment when Ignition is forced to run again. Use the Ignition kernel parameter to point the node's Ignition environment directly to matchbox where the userdata lies.
1 parent 6c7809c commit e5f0458

File tree

2 files changed

+4
-6
lines changed

2 files changed

+4
-6
lines changed

assets/terraform-modules/matchbox-flatcar/templates/install.yaml.tmpl

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,6 @@ storage:
4949
wipefs -f -a "$${disk}" || echo "error: failed to wipe $${disk}"
5050
done
5151
%{~ endif ~}
52-
curl --retry 10 "${ignition_endpoint}?mac=${mac_address}&os=installed" -o ignition.json
5352
flatcar-install \
5453
%{~ if install_to_smallest_disk ~}
5554
-s \
@@ -59,14 +58,13 @@ storage:
5958
-C ${os_channel} \
6059
-V ${os_version} \
6160
-o "${container_linux_oem}" \
62-
${baseurl_flag} \
63-
-i ignition.json
61+
${baseurl_flag}
6462
udevadm settle
6563
OEM_DEV="$(blkid -t "LABEL=OEM" -o device)"
6664
mkdir -p /tmp/oemfs
6765
mount "$${OEM_DEV}" /tmp/oemfs
6866
# append to file on newly created partition, do not remove the defaults
69-
echo 'set linux_append="${kernel_args}"' >> /tmp/oemfs/grub.cfg
67+
echo 'set linux_append="${kernel_args} ignition.config.url=${ignition_endpoint}?mac=${mac_address}&os=installed"' >> /tmp/oemfs/grub.cfg
7068
echo 'set linux_console="${kernel_console}"' >> /tmp/oemfs/grub.cfg
7169
umount /tmp/oemfs
7270
systemctl reboot

pkg/assets/generated_assets.go

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)