/srv/irclogs.ubuntu.com/2022/09/03/#cloud-init.txt

jbghow can i disable network configuration in cloud-init entirely?08:49
jbgthe documentation tells me to add "network:\n  config: disabled" to /etc/cloud/cloud.cfg08:49
jbgi have done that and also added "disable_network_activation: true"08:49
jbgyet cloud-init still tries to run dhclient before fetching user-data08:50
waldiwhich data source? several of them require working network, so they do the minimal thing they can08:51
waldiand it's going to be overriden by the real network setup anyway shortly after08:51
jbgwaldi: i've moved cloud-init to run after the network comes up, since i am only using it to write a handful of files and nothing else08:52
jbgthere seems to be some bug with the ephemeral DHCP handling which only manifests on Vultr and not on other clouds we use, but it's a bit annoying having to debug something that i would rather not even have08:53
waldijbg: so you don't use the init-local instance?08:53
jbgnope, but whenever it tries to load user-data it seems to run the dhcp code regardless?08:53
jbgi might just put the files in user-data with mime multipart or something and parse them out with a script08:54
waldiwhich data source do you use?08:56
jbgsame image is deployed in many different environments, and they all (or maybe just most, i haven't looked rigorously) seem to do an extra DHCP roundtrip, but the DHCP breakage is happening specifically with vultr08:57
jbgin that it actually fails to do its "ephemeral" DHCP thing and thus fails to load the user data, even though it actually has network connectivity08:58
waldiwell. the vultr data source is coded this way08:58
jbgi can ssh in and curl the userdata just fine, but it doesn't try because the DHCP part fails08:58
jbgi don't really understand the motivation for that; the provider supports DHCP and the distro supports DHCP, why does it need to do DHCP again instead of just running slightly later?08:59
waldibecause you need an address to access the meta data service, but the meta data service is going to tell you how to setup the network08:59
jbgbut the most common case is "just do DHCP"09:00
jbganyway, i don't think it's necessary to go over this, i think i see the issue in the data source code09:01
jbgand i think cloud-init has a much larger scope than we need09:02
waldinow the question is: is this a overall brokeness in the vultr platform or just in your usecase?09:03
jbgi think there is certainly some bug in the vultr data source; systemd-networkd does DHCP fine but vultr's datasource claims to fail (though doesn't log any error)09:05
jbgin terms of our usecase, it does seem a bit difficult in general to make cloud-init "just take three files from user data and write them and promise to do nothing else at all"09:06
jbgthere are a lot of individual things that have to be turned off which will otherwise bite you, sometimes only on some cloud providers (e.g. vendor data)09:06
=== jmcgnh_ is now known as jmcgnh

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