This message was deleted.
# elemental
a
This message was deleted.
👍 1
a
So, I got to the bottom of this, feel free to read the thread in #C01GKHKAG0K linked above, but the TL;DR is this: Harvester puts both
user-data
&
meta-data
files containing cloud-init config into the cloud-init drive that gets attached to VMIs (line 587-588 of cloud-init.go).
user-data
contains the cloud config that users specify when creating VMs, and
meta-data
contains instance data generated by Harvester (this is invisible to the user) such as the instance ID and machine name, which is exactly what I’m looking for in this use case. In my testing this meta-data cloud-init “data source” gets consumed correctly by other OSes such as the Tumbleweed cloud image, setting it’s hostname to whatever the VM name is in Harvester, so I thought I could simply point an Elemental derived OS at this config and be fine, except looking at the cd-rom provider in the elemental-toolkit this is hard coded to only look at files called “`user-data`” or “`config`”. I can therefore point to the cloud-init drive attached to the VM, but not the specific file within. @sticky-tailor-45974 Would there be appetite for adding “meta-data” to this list of strings given this seems to be a standard file name for cloud-init systems, or providing a mechanism for also specifying a path with the cd-rom provider? Happy to raise a PR for the former or an issue for the latter if so
👏 3
👀 1
s
Hi @acoustic-country-10006 great analysis! Thanks for all the details. Improving compatibility and support with Harvester is definitely an interesting improvement and something to encourage. Contributions to the code are appreciated and welcome. @many-tiger-3407 was kind enough to point me where this "meta-data" could be added, that is the datasource provider of yip which is, in turn, a dependency of elemental-toolkit. So this piece of code is likely to be hidden across this lines https://github.com/rancher/elemental-toolkit/blob/d5eab7e7f8e088dda82eb225612f1e45[…]github.com/rancher-sandbox/linuxkit/providers/provider_cdrom.go
m
Well, Robert himself pointed me/us there actually in the harvester thread 😄
a
You're welcome! I'm back at work for the next few days but can put a contribution together soon. Feel like I'm really starting to get over any hurdles I had towards using elemental/Harvester/rancher so it's nice to iron these things out and make it a great experience
💚 1