Sven Dowideit b4584a616a update to new kexec, and fix building with 17.06.1 7 年之前
..
conf e486b7e218 ros install 9 年之前
kexec b4584a616a update to new kexec, and fix building with 17.06.1 7 年之前
BaseDockerfile.amd64 fdc16672d5 ros os upgrade --kexec ... works again 7 年之前
Dockerfile.amd64 8e5eba0ac5 add --debug logging option to installer, and a dummy set-disk-partitions 7 年之前
Dockerfile.arm64 a4cf5b47b2 Changes needed to get the arm and arm64 builds working 8 年之前
README.md abf1203499 readme from os-installer 9 年之前
lay-down-os 2a575837b2 Installing 0.7.1, and then rebooting, and doing a ros upgrade to a faked up latest works \o/ 7 年之前
seed-data c42d1b5716 Avoid hardcoded reference to /scripts 9 年之前
set-disk-partitions 69d1077169 gpt disk in BIOS boot mode 8 年之前

README.md

rancher/os installer container

The container can be used directly, but there is a wrapper in RancherOS CLI, ros install, that handles calling things in the right order.

##Basics

When booting from the ISO file RancherOS runs completely from memory. In order to run more containers, and save state between reboots, you need to persist and run from disk.

When booting, RancherOS looks for a device labeled "RANCHER_STATE". If it finds a volume with that labeled the OS will mount the device and use it to store state.

The scripts in this container will create a device labeled RANCHER_STATE and make it bootable. The two supported methods, are generic and amazon-ebs. The approach can be translated to suit different needs.

The generic install type follows these steps:

  1. ) partition device with a single partition the size of the disk.
  2. ) format ext4 and label partition as RANCHER_STATE
  3. ) Install grub2 on device
  4. ) Place kernel/initrd and grub.cfg inside /boot on the device.
  5. ) Seeds the cloud-init data so that a ssh key or other RancherOS configuration can be set.

The amazon-ebs approach follows these steps:

  1. ) format the device (Ext4) and label RANCHER_STATE
  2. ) Add PV-GRUB configuration (menu.lst)
  3. ) Add Kernel and Initrd
  4. ) Sets Rancher to look for EC2 cloud-init data.

Usage

Warning: Using this container directly can be like running with scissors...

 # Partition disk without prompting of any sort:
 docker run --privileged -it --entrypoint=/scripts/set-disk-partitions rancher/os:<version> <device>


 # install 
 docker run --privileged -it -v /home:/home -v /opt:/opt \
        rancher/os:<version> -d <device> -t <install_type> -c <cloud-config file> \
        -i /custom/dist/dir \
        -f </src/path1:/dst/path1,/src/path2:/dst/path2,/src/path3:/dst/path3>

The installation process requires a cloud config file. It needs to be placed in either /home/rancher/ or /opt/. The installer make use of the user-volumes to facilitate files being available between system containers. -i and -f options are, well, optional.

By providing -i (or DIST env var) you specify the path to your custom vmlinuz and initrd.

-f allows you to copy arbitrary files to the target root filesystem.

Contact

For bugs, questions, comments, corrections, suggestions, etc., open an issue in rancher/os with a title starting with [os-installer].

Or just click here to create a new issue.