I wanted to try out Container Linux on a baremetal machine, with the intention of having it run a single-node
OpenShift Kubernetes (kubeadm) install for homelab experiments. However, I was pretty let down by the documentation on how to install from an ISO.
Most of the documentation is either for installing on a cloud provider or by running an install script on an already running Linux box. This is apparently because, by their own admission in the "Known Limitations" of booting from an ISO: "There is no straightforward way to provide an Ignition config." The Ignition config is the JSON-output of a YAML file called the "Container Linux Config" that has been run through their Config Transpiler
Rather than going through the hassle of getting the Config Transpiler set up on the ISO after booting, the steps below just use a still valid (although deprecated) method called cloud-config to provide a YAML file that the install script can actually interpret.
- Download the ISO from here
- Make a bootable USB with Rufus
- Boot your baremetal device to the USB
- Verify the storage device you want to install CoreOS on using GParted
sudo partedto get into the application
print allto see all devices/partitions
- On your local machine (not the CoreOS box), get your SSH public key
- Save that output to a file on your computer named something like "ssh.txt" and serve it up over HTTP
- My preferred way to set up a super simple HTTP server is to use a built-in module of Python3.
cdto the directory where you saved your ssh.txt file and run
python3 -m http.server
- If you're on Windows, you may need to run
py -3 -m http.serverinstead.
- Retrieve the SSH key on your CoreOS box
- Replace the IP address to whatever the IP is of your local machine.
- Port 8000 is the default port that the http.server Python module listens on
- Edit the file with
sudo vim ssh.txt
- Change it to look like:
#cloud-config ssh_authorized_keys: - <insert your SSH key here>
- It must include the "#cloud-config" part at the top
- Save it with
- Rename the file
mv ssh.txt config.yaml
- Install CoreOS with:
sudo coreos-install -d /dev/sda -C stable -c ~/config.yaml
/dev/sdawith the path of another device if you decided in step 4 that you want to install it somewhere else.
-C stablespecifies that you want the Stable channel for updates. Other options include Alpha and Beta
- Reboot the computer
sshto your new install from the machine whose SSH public key you provided
- You're all done!
- The default user is
coreand by default has sudo access to everything on the machine without having to type in a password
- The default SELinux status is Permissive
- CoreOS has no package manager and will send updates "Over-the-Air"
- By default, Container Linux uses
networkdfor networking. You can configure static networking by following the instructions here
- UEFI boot is not supported, so you must boot the system in BIOS compatibility mode.