On 22 April 2013 11:39, Charles Plessy <[email protected]> wrote: > Le Mon, Apr 22, 2013 at 11:13:51AM +0200, Anders Ingemann a écrit : > > Sure, it's pretty easy to add it yourself though. > > The main plugin file is simply: > > insert_task_after $TASK_APT_SOURCES $ > > plugindir/add-stable-packports/add-apt-source > > And add-apt-source would be: > > cat > $imagedir/etc/apt/sources.list.d/stable-backports <<EOF > > deb http://http.debian.net/debian stable-backports main > > deb-src http://http.debian.net/debian stable-backports main > > EOF > > Sorry I was too vague: > > I think that once we will have a cloud-init backport, it will be tempting > to > build stable images with cloud-init pre-installed. I am not sure if the > current build-debian-cloud is able to create an image of Stable with the > latest > backport of cloud-init, even if sources.list is modified as you indicated. > However, I think that it would be a very helpful feature. > > To complicate things, cloud-init may be a special case as it will not be in > Wheezy, but otherwise if a package is both in stable and stable-backports, > the backport will not be selected by default and I do not think that > debootstrap > is able to understand syntaxes such as "cloud-init/squeeze-backports". > > Cheers, > > -- > Charles Plessy > Tsurumi, Kanagawa, Japan > > > -- > To UNSUBSCRIBE, email to [email protected] > with a subject of "unsubscribe". Trouble? Contact > [email protected] > Archive: http://lists.debian.org/[email protected] > > Oh! I see. Well, you don't need to worry about that :-). We can install things with apt-get if need be. The bootstrapper actually used to do that until I moved all of that into the debootstrap parameters. We simply place the installation task after the apt-upgrade task<https://github.com/andsens/build-debian-cloud/blob/master/tasks/22-apt-upgrade> . So to add to the code I previously posted we would just need: insert_task_after $TASK_APT_UPGRADE $plugindir/cloud-init/install-cloud-init And install-cloud-init would be: apt-get install -t squeeze-backports cloud-init | spin # Avoid spamming stdout with spin
Anders
