/srv/irclogs.ubuntu.com/2017/11/12/#cloud-init.txt

kszarlejhey guys. is it possible to run cloud init network configuration on every boot>00:01
kszarlejso after I add another IP to NoCloud config drive for an existing KVM VM cloud-init after reboot will00:02
kszarlejset this interface up?00:02
kszarlejHey guys. I am using cloud-init NoCloud on my KVM VMS to setup networking using network-config. On first boot cloud-init sets up networking interfaces correctly. After first boot modifying network settings (adding another IP address to interface) doesnt work - the address is not added after reboot. Is it by design (so cloud-init reads networking info only on first boot?)19:22
kszarlejIf yes then is there any possible way to "rerun" network configuration on every boot using cloud-init?19:22
kszarlejbesides rebooting I was also trying 'systemctl stop cloud-init-local.service  && systemctl start cloud-init-local.service'19:50
kszarlejbut it also doesnt add the new IP address. I am sure that new network-config is in the ISO /dev/sr019:51
blkaddercloud-init is designed to run once.20:35
kszarlejblkadder: but it has 'per-always' 'per-instance' etc20:37
kszarlejI would like to set that interfaces are being setup 'per-always'20:37
blkadderThere is a way to run something on subsequent boots, I was looking it up....20:37
kszarlejbut I cannot find which "module" is setting up networking20:38
kszarlejnone of the /etc/cloud/cloud.cfg surely20:39
kszarlejof the listed in*20:39
kszarlejthere isnt any 'network' module20:39
kszarlejit looks like it is done my cloud-init-local20:45
blkadderI think (not positive someone smarter here may know) that this is what you'd use some sort of config management tool for. Cloud-init provides initial config then you hand off to config management for things you need to do repeatedly.20:48
blkadderThat's my understanding anyways...20:48
kszarlejYe but then I duplicate networking configuration between two tools20:53
kszarlejcloud-init and ie. ansible20:53
kszarlejit would be much better if cloud-init could do that20:54
blkadderSo don't have cloud-init handle the network config and just use ansible?20:57
kszarlejHow will I access an host using ansible+ssh when it has network not configured on start? :)21:02
kszarlejI dont want to log to every KVM VM and set manually IP address21:03
kszarlejits 21th century :)21:04
blkadderkszarlej, Distribute your network config playbook as part of the initial cloud-init config and run it.23:12

Generated by irclog2html.py 2.7 by Marius Gedminas - find it at mg.pov.lt!