k8s:linux_vm:set_up_flatcar-linux
Differences
This shows you the differences between two versions of the page.
| Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
| k8s:linux_vm:set_up_flatcar-linux [2023/10/19 15:00] – admin | k8s:linux_vm:set_up_flatcar-linux [2023/11/14 22:43] (current) – admin | ||
|---|---|---|---|
| Line 22: | Line 22: | ||
| Upload a version of flatcar_production_vmware_ova_image.vmdk to one of the VM hosts. Instead of [current](https:// | Upload a version of flatcar_production_vmware_ova_image.vmdk to one of the VM hosts. Instead of [current](https:// | ||
| - | a [previous stable release](https:// | + | a [previous stable release](https:// |
| Remove any disks. Add the `flatcar_production_vmware_ova_image.vmdk` as the first disk (system, sda) and add a second thin provisionen 230 GB disk (container ephemeral, sdb). | Remove any disks. Add the `flatcar_production_vmware_ova_image.vmdk` as the first disk (system, sda) and add a second thin provisionen 230 GB disk (container ephemeral, sdb). | ||
| Line 42: | Line 42: | ||
| ```yaml | ```yaml | ||
| variant: flatcar | variant: flatcar | ||
| - | version: 1.1.0 | + | version: 1.0.0 |
| - | ignition: | + | passwd: |
| - | | + | users: |
| - | | + | - name: core |
| - | - name: core | + | ssh_authorized_keys: |
| - | ssh_authorized_keys: | + | - ecdsa-sha2-nistp256 AAAAE2VjZHNhLXNoYTItbmlzdHAyNTYAAAAIbmlzdHAyNTYAAABBBFBjtMTXcKtVlorGkFwpCs1XmHakFwk3ggShgmHZyJaAhjR81bAFFZVGURBIXUnmi4DpcAV1GaNDNdw0DJvPqRo= Omar Yubikey 5 nano |
| - | - ecdsa-sha2-nistp256 AAAAE2VjZHNhLXNoYTItbmlzdHAyNTYAAAAIbmlzdHAyNTYAAABBBFBjtMTXcKtVlorGkFwpCs1XmHakFwk3ggShgmHZyJaAhjR81bAFFZVGURBIXUnmi4DpcAV1GaNDNdw0DJvPqRo= Omar Yubikey 5 nano | + | - ecdsa-sha2-nistp256 AAAAE2VjZHNhLXNoYTItbmlzdHAyNTYAAAAIbmlzdHAyNTYAAABBBAe26li9Rzcf+iBRftzE3WDddlDI8+HpCm+GFdep5tcWC6Q2Hzbi1GSqFTBSvpKAJRbyq49OkA3gd16ugmzImDU= Omar Yubikey 5 NFC |
| - | - ecdsa-sha2-nistp256 AAAAE2VjZHNhLXNoYTItbmlzdHAyNTYAAAAIbmlzdHAyNTYAAABBBAe26li9Rzcf+iBRftzE3WDddlDI8+HpCm+GFdep5tcWC6Q2Hzbi1GSqFTBSvpKAJRbyq49OkA3gd16ugmzImDU= Omar Yubikey 5 NFC | + | kernel_arguments: |
| - | kernel_arguments: | + | should_not_exist: |
| - | should_not_exist: | + | - flatcar.autologin |
| - | - flatcar.autologin | + | storage: |
| - | storage: | + | filesystems: |
| - | filesystems: | + | - device: /dev/sdb |
| - | - name: oem | + | format: xfs |
| - | mount: | + | wipe_filesystem: |
| - | | + | label: cont-ephemer |
| - | format: btrfs | + | files: |
| - | label: OEM | + | - path: / |
| - | | + | mode: 0644 |
| - | mount: | + | contents: |
| - | device: /dev/sdb | + | inline: acdh-clusterx |
| - | | + | |
| - | | + | |
| - | | + | - path: / |
| - | files: | + | contents: |
| - | - path: /grub.cfg | + | inline: | |
| - | filesystem: oem | + | [Match] |
| - | mode: 0644 | + | MACAddress=< |
| - | contents: | + | |
| - | inline: | | + | [Network] |
| - | set oem_id=" | + | Address=10.3.6.xx/ |
| - | set linux_append="" | + | Gateway=10.3.6.1 |
| - | | + | DNS=192.168.1.1 |
| - | | + | Domains=servants.priv |
| - | | + | # |
| - | contents: | + | - path: / |
| - | | + | contents: |
| - | | + | inline: | |
| - | - path: / | + | [Match] |
| - | contents: | + | MACAddress=MAC address from vCenter kubernetes_internal> |
| - | inline: | | + | |
| - | [Match] | + | [Network] |
| - | MACAddress=< | + | Address=10.6.16.xx/ |
| - | + | - path: / | |
| - | [Network] | + | |
| - | Address=10.3.6.xx/ | + | inline: | |
| - | Gateway=10.3.6.1 | + | REBOOT_STRATEGY=" |
| - | DNS=192.168.1.250 | + | LOCKSMITHD_REBOOT_WINDOW_START=" |
| - | Domains=servants.priv | + | LOCKSMITHD_REBOOT_WINDOW_LENGTH=" |
| - | NTP=192.168.1.250 | + | |
| - | - path: / | + | systemd: |
| - | contents: | + | units: |
| - | inline: | | + | - name: update-engine.service |
| - | [Match] | + | |
| - | MACAddress=MAC address from vCenter kubernetes_internal> | + | - name: locksmithd.service |
| - | + | | |
| - | [Network] | + | - name: systemd-timesyncd.service |
| - | Address=10.6.16.xx/ | + | |
| - | - path: / | + | - name: var-lib-rancher.mount |
| - | | + | |
| - | inline: | | + | contents: | |
| - | REBOOT_STRATEGY=" | + | [Unit] |
| - | LOCKSMITHD_REBOOT_WINDOW_START=" | + | Description=Mount ephemeral to / |
| - | LOCKSMITHD_REBOOT_WINDOW_LENGTH=" | + | Before=local-fs.target |
| - | systemd: | + | [Mount] |
| - | units: | + | What=/ |
| - | # Ensure docker starts automatically instead of being socket-activated | + | Where=/ |
| - | - name: docker.socket | + | Type=xfs |
| - | enable: false | + | [Install] |
| - | | + | WantedBy=local-fs.target |
| - | | + | |
| - | - name: locksmithd.service | + | |
| - | | + | |
| - | - name: systemd-timesyncd.service | + | |
| - | | + | |
| - | # Mount a separate disk for all docker data | + | |
| - | | + | |
| - | | + | |
| - | - name: var-lib-rancher.mount | + | |
| - | enable: true | + | |
| - | contents: | | + | |
| - | [Unit] | + | |
| - | Description=Mount ephemeral to / | + | |
| - | Before=local-fs.target | + | |
| - | [Mount] | + | |
| - | What=/ | + | |
| - | Where=/ | + | |
| - | Type=xfs | + | |
| - | [Install] | + | |
| - | WantedBy=local-fs.target | + | |
| - | - name: docker.service | + | |
| - | enable: false | + | |
| ``` | ``` | ||
| Line 167: | Line 145: | ||
| qemu-img create -f qcow2 -F qcow2 -b flatcar_production_qemu_image.img flatcar-linux1.qcow2 | qemu-img create -f qcow2 -F qcow2 -b flatcar_production_qemu_image.img flatcar-linux1.qcow2 | ||
| chown libvirt-qemu: | chown libvirt-qemu: | ||
| + | ``` | ||
| + | Create the configuration (use the YAML from above) | ||
| + | ```bash | ||
| + | cat acdh-clusterx.yaml | podman run --rm -i quay.io/ | ||
| + | sudo chown libvirt-qemu: | ||
| + | ``` | ||
| + | Create the virutal machine, 2 disks, the qcow2 and a rancher partition of about 20GB | ||
| + | At the end add the following XML | ||
| + | ```xml | ||
| + | < | ||
| + | < | ||
| + | < | ||
| + | </ | ||
| ``` | ``` | ||
k8s/linux_vm/set_up_flatcar-linux.1697720432.txt.gz · Last modified: by admin