Last active
June 7, 2018 13:57
-
-
Save janeczku/a44f533d9af80e620db7 to your computer and use it in GitHub Desktop.
RancherOS iPXE boot script and cloud-config. Ramdisk based deployment with persistent storage on disk. Configures private IP on eth1 from EC2 metadata.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#cloud-config | |
hostname: rancher-os | |
ssh_authorized_keys: | |
- ssh-rsa REPLACE_WITH_PUBLIC_SSH_KEY | |
rancher: | |
debug: false | |
cloud_init: | |
datasources: | |
- ec2 | |
state: | |
formatzero: true | |
fstype: auto | |
dev: LABEL=RANCHER_STATE | |
autoformat: | |
- /dev/vda | |
- /dev/sda | |
network: | |
dns: | |
nameservers: | |
- 8.8.8.8 | |
- 8.8.4.4 | |
interfaces: | |
eth0: | |
dhcp: true | |
eth1: | |
address: $private_ipv4/16 | |
mtu: 1450 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!ipxe | |
# Boots RangerOS in Ramdisk with persistent storage on disk /dev/vda | |
# Location of Kernel/Initrd images | |
set base-url http://releases.rancher.com/os/latest | |
kernel ${base-url}/vmlinuz rancher.state.dev=LABEL=RANCHER_STATE rancher.state.formatzero=true rancher.state.autoformat=[/dev/sda,/dev/vda] rancher.cloud_init.datasources=[ec2] | |
initrd ${base-url}/initrd | |
boot |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
I'd suggest
console=tty1 rancher.autologin=tty1
so that the VNC console from the web panel logs in without asking for a none existing password. In case of trouble... 😄