[01:58] I discovered that installing cloud-init on an Raspberry Pi running Raspbian (RPi Debian) has a fatal flaw. It trows stuff into `/etc/apt/sources.list` this is inappropriate for this architecture. Where does the problem lie? I don't know who to report the bug to. [02:11] brunobronosky: how did you install it? [02:11] apt-get [02:12] brunobronosky: there's a cloud-init package in raspbian? Or was this a third-party repository? [02:12] 0.7.9 is in Raspbian. [02:12] I don't think anyone has ever used it, but it comes straight from debian. [02:13] If the raspbian package is installed the wrong things in sources.list, I would call that a raspbian bug. [02:13] Raspbian bug reporting info: https://www.raspbian.org/RaspbianBugs [02:16] yeah, I found that, but it's the "Before You File a Bug" part that has me second guessing. [02:17] I'm eventually going to ask them to have cloud-init installed by default. I'm trying not to be an annoyance to the maintainer. [02:19] What are you doing with cloud-init on the Pi? [02:24] larsks https://www.raspberrypi.org/forums/viewtopic.php?f=66&t=206034&sid=e154adc1892a1a0d3c32fda0a94f640c [02:25] actually, I guess my followup to the thread is more to the point. https://www.raspberrypi.org/forums/viewtopic.php?p=1276583#p1276583 [02:25] * larsks continues to read... [02:27] That's an interesting application. [02:27] I thought so. [02:27] What was the particular feature that was undocumented until 17.2? [02:28] but, now I'm doubting my decision to use a Standardâ„¢ vs. just roll my own systemd oneshot service. [02:29] using `datasource: NoCloud: seedfrom: /path/` [02:30] Everything I was hearing was insisting that you had to use a volume labeled `cidata`. [02:31] Huh. Pretture sure even earlier versions documented how to preconfigure a filesystem with metadata. [02:31] But re: using cloud-init vs rolling your own: I guess it depends on what you're trying to do. I mean, cloud-init already has a bunch of modules to handle common system configuration tasks, which is maybe useful. [02:32] Even on this IRC channel at first I said "I need to have {user,meta}-data read from the partition mounted at /boot" and I was being told to change the label to cidata. [02:32] On the other hand, if you have access to the sdcard to install cloud-init metadata, you also are able to make most of your configuration changes at that point. Using something like qemu-user, you can even run Pi binaries and install packages, etc. [02:33] O_o "and then tell the kernel to boot from the cidata volume instead of the boot volume? Eh. No." [02:34] But using qemu is WAY beyond your average Windows using school teacher. [02:35] E,g, here are the docs for 0.7.9 that describe pre-seeding: https://git.launchpad.net/cloud-init/tree/doc/examples/seed/README?id=0.7.9 [02:36] (editing anything other than /boot is virtually impossible for Mac and Windows users) [02:40] That's a good point. [02:40] Even that example you posted would have helped me. But sadly... http://cloudinit.readthedocs.io/en/latest/search.html?q=nocloud-net&check_keywords=yes&area=default [02:44] Have you (or are you going to) put together a demo image with cloud-init installed? [02:49] Going to. Just as soon as I can get cloud-init to stop destroying apt. [02:54] I'm going to add cloud-init to my fork of https://github.com/RPi-Distro/pi-gen/blob/dev/stage2/01-sys-tweaks/00-packages and publish a cloud-init userdata file that can be used to compile the Raspbian image on an EC2 instance. (Since it is virtually impossible to build on Mac or Windows) How meta is that? [02:54] brunobronosky: what sort of problems are you seeing? Just install cloud-init on rasbpian stretch, it doesn't appear to have added anything erroneous to /etc/apt. [02:55] Hmmm. For me it overwrites /etc/apt/sources.list [02:56] Upon installation? Or execution? I just installed the package (apt install cloud-init) and my sources.list is unmodified. [02:56] do `sudo cloud-init init --local` [02:56] So that would be "upon execution" :). Let me give it a try. [02:58] Keep this handy ;-) https://github.com/RPi-Distro/pi-gen/blob/dev/stage0/00-configure-apt/files/sources.list [02:58] Still unmodified. [02:58] /var/log/cloud-init.log looks like http://termbin.com/mgcs [02:59] Really! Hmm. Let me grab a fresh image. I've installed 17.2 from source on this one. (You probably just saved me from embarrassing myself (elsewhere)) [03:00] brunobronosky: note that this is 0.7.9! [03:00] It's entirely possible 17.2 is doing something different. [03:01] I'd rather look like a fool here than on Raspbian. I'm not trying to get any PRs accepted to cloud-init. [03:01] (0.7.9 understood) [03:16] larsks do you have apt-configure in your /etc/cloud/cloud.cfg [03:17] brunobronosky: looks like it...but it's in cloud_config_modules, so 'cloud-init init --local' wouldn't run it. [03:19] once you reboot, it will fill your sources.list with "## Note, this file is written by cloud-init on first boot of an instance"... [03:22] Let me drop a seed file in place and see what happens. [03:22] I'd love some help coming up with a sane minimal /etc/cloud/cloud.cfg for this. [03:27] I see what you mean. It looks like the comments there tell you what to do to make it configure sources.list appropriately. [03:27] ("if you wish to make changes you can...") [03:32] brunobronosky: I have to take off for the night. Good luck! [03:34] thanks! [03:35] I just don't like that the cloud.cfg by default is full of all kinds of things I don't understand and don't need.