Created
December 2, 2014 23:52
-
-
Save marineam/e87509ddfc682ca6864a to your computer and use it in GitHub Desktop.
Two stage cloudinit
This file contains hidden or 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
#!/bin/bash | |
set -e | |
mkdir -p /etc/systemd/network | |
cat > /etc/systemd/network/00-eth.network <<EOF | |
[Match] | |
Name=eth* | |
[Network] | |
DHCP=v4 | |
[Route] | |
Gateway=169.254.169.254 | |
EOF | |
cat > /tmp/real-cloud-config <<EOF | |
#cloud-config | |
coreos: | |
whatever.... | |
EOF | |
exec coreos-cloudinit -from-file=/tmp/real-cloud-config |
Workaround for this is GatewayOnLink=yes
.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
(sadly the route+dhcp bit does not work, but it would be cool if it did...)