/srv/irclogs.ubuntu.com/2021/08/17/#cloud-init.txt

=== mamercad4 is now known as mamercad
cpaelzerHiho, just stumbled over this when checking for a bug08:31
cpaelzeron the docs at https://cloudinit.readthedocs.io/en/latest/topics/modules.html?highlight=ssh_authorized_keys#authorized-keys08:31
cpaelzerit reads "connect to a a user account on a system"08:31
cpaelzera a <<08:32
cpaelzerseems wrong and a trivial fixup if you think it is worth08:32
cpaelzerfalcojr: ^^ FYI08:32
cpaelzeralso nowadays (impish and later) the dmesg call in https://cloudinit.readthedocs.io/en/latest/topics/bugs.html needs a sudo08:44
cpaelzerreported https://bugs.launchpad.net/cloud-init/+bug/1940236 and https://bugs.launchpad.net/cloud-init/+bug/194023508:47
ubottuLaunchpad bug 1940236 in cloud-init "requesting Minor doc fixes" [Undecided, New]08:47
ubottuLaunchpad bug 1940235 in cloud-init "cloud-init collect-logs fails in impish" [Undecided, New]08:47
cpaelzerwhile I actually wanted to report https://bugs.launchpad.net/cloud-init/+bug/194023308:47
ubottuLaunchpad bug 1940233 in cloud-init "cloud-init   in impish makes /home/ubuntu/.ssh root.root" [Undecided, New]08:47
cpaelzerhattrick :-/08:47
andyfHi all. I've been adding support for the illumos (née OpenSolaris) family of OSs to cloud-init.11:52
andyfIs this something you'd be interesting in my committing back?11:53
andyfIt's generally been a pleasant experience, and there are abstractions in place for most things to make it easy11:53
andyfbut I do have a couple of places where I don't know the right approach to take11:54
andyfand I've had to de-linuxify some of the modules - those would probably be best as separate commits11:54
akutzandyf: There is a place in netinfo.py where the logic splits between Linux and FreeBSD, so having additional logic for OpenSolaris seems to be in line with what is already happening elsewhere. Then again, it's been quite a while since I SPARCd up a conversation about Solaris :) Perhaps the differences are too large? Not sure.12:37
andyfYes, having the *bsd support in there definitely made this job easier since there is already work there to remove some assumptions about the system. Adding illumos will further improve that I think.12:39
andyfWe're definitely going to ship this in our OmniOS distribution, it's just a question of whether it can go upstream (which would be my preference!)12:39
andyfSome people in the illumos community are writing a cloud-init clone in Rust - so coming at it from the other angle12:40
andyfI would prefer to use the real thing since it's the industry standard12:40
falcojrcpaelzer: Thanks! Those are both really helpful13:34
falcojrandyf: yes, we would welcome those submissions upstream...just not the rust fork :P13:34
andyffalcojr: great! I'll start with a couple of small PRs to generalise a couple of the modules that make assumptions at the moment13:45
andyfthey're small and it will give me a feel for the process etc.13:45
cpaelzerglad to hear that falcojr13:48
* cpaelzer does not want to be the late-cycle killjoy13:48
falcojrcpaelzer: waaaaaaaaay better than post-release killjoy13:48
rharperandyf: totally interested in the rust fork;  primarily in 1) size and speed improvements 2) scope of features  included 3) how are the various modules cc_XX being handled (ported or kept in python) 14:18
andyfrharper: they are just doing something that works purely for illumos - a metadata client in rust that can use various datasources.14:21
andyfhttps://github.com/illumos/metadata-agent/14:21
andyfI think extending cloud-init is a better approach14:23
rharpernice, thanks for the link14:23
minimalrharper: there are various cloud-init "clones" around but they tend to have limited functionality and limited DS support14:29
minimalI've seen shell, C, and Golang "clones"14:29
rharperright; it's always a subset 14:29
minimalexactly, that's why I sorted out the cloud-init package for Alpine, the breadth of DS support is important14:30
rharperI'm generally interested in improving the core but I'd like to retain (without porting) all of the module support;  14:30
andyfOpened my first PR anyway :) I just need to sign the agreement (my browser is slow and keeps saying I got the captcha wrong, I'll try later from home)14:30
rharperyeah and Datasource support as well; 14:30
minimalas Alpine is a "minimal" Linux distro that's why I'm keen to reduce cloud-init's dependancies were possible.14:32
akutzWait, is there an actual Rust fork of cloud-init? Interesting.14:32
akutzYou have to have muscl memory when using Alpine :)14:32
minimalakutz: I'm all for keeping it minimal :-)14:33
akutzI also wonder if there's been any chatter in splitting cloud-init somewhat where the early bootstages have minimal deps and use as portable a language as possible, but by the time any user or vendor data is processed, a more featureful framework/language is present. 14:34
akutzReally I just want to use something more powerful than shell scripting for ds-identify :)14:35
akutz(and I am the person who wrote a 5,176 line, POSIX-compliant shell script for bootstrapping Kubernetes :) https://github.com/vmware-archive/simple-k8s-test-env/blob/master/sk8.sh14:36
minimalakutz: I'm keen to ensure that any shell scripts in cloud-init only rely on /bin/sh - I don't have bash on any of my Alpine boxes. Also that where possible that Busybox lightweight versions of common tools can be used (I'm currently working on a cloud-init PR to support Busybox's blkid so I can remove the dependancy on the "full" version of blkid)14:37
falcojrakutz: At one point Odd_Bloke was toying with a ds_identify clone in rust, but I don't think he got very far14:38
akutzminimal: Rely only on /bin/sh or be POSIX compliant? Because, as I've learned, there are differences. The use of "local" all over the place, for example. That's not technically allowed by POSIX-compliance standards, but I was told all shells support it, so....14:39
minimalakutz: relevant point, I'm the person who has written a 6,000+ line (and growing) shell script for creating cloud-init enabled Alpine VM/Cloud/physical machine disk images :-) https://github.com/dermotbradley/create-alpine-disk-image14:39
akutzI bring 5,176 and minimal comes back with 6,000+ :) 14:40
akutzAlso, nice!14:40
andyfksh93 does not support 'local' unless specifically compiled with support for it as a bash-compat thing14:41
minimalakutz: yeah POSIX-related is a bit of a gray area. Alpine's using ash by default which is a dash-equivalent shell. Agree with the support for "local", have noticed the same. I tend to run all my shell stuff through "shellcheck".14:42
akutzI've done a little work with Gardenlinux (https://github.com/gardenlinux/gardenlinux) and other projects that build VM disk images from scratch using a mounted FS in a container. It's always really cool, but I wish there was a way to make it more portable. 14:42
akutzI use shellcheck as well, and that is when I was told that shellcheck is too aggressive and local is okay. Still, I prefer to stick with standards, even when I disagree, for the sake of consistency.14:43
minimalakutz: look at my script, its using chroot with a static-compiled version of the Alpine "apk" package manager, plus binfmt/user-mode QEMU for creating images for a different arch. Its somewhat portable as the script should run on most Linux distros14:44
akutzYeah, that's why I made the comment. I realized right away what you were doing :)14:45

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