Remove CloudInit from Ubuntu Server

Christian Ehrhardt christian.ehrhardt at canonical.com
Tue Nov 30 07:04:50 UTC 2021


On Mon, Nov 29, 2021 at 10:24 PM Jeffrey Walton <noloader at gmail.com> wrote:
>
> Hi Everyone,
>
> I'm testing Ubuntu Server in a VM. I noticed the server edition
> includes CloudInit by default. I don't need a VM inside a VM so I
> would like to remove it.

There might be a misunderstanding. The CloudInit installed in your
current VM (level 1) isn't responsible for a potential VM (level 2)
further inside it.

It is responsible to allow customization of your current VM (level 1).
And depending on where/how you run/host your current VM (level 1) it
might already be used to do customization when you have spawned it.

> The CloudInit docs don't say if it is Ok to remove
> (https://help.ubuntu.com/community/CloudInit).
>
> Is it Ok to remove CloudInit?

We generally consider the ability to customize a system a core feature
of a server image, therefore ubuntu-server-minimal depends on
cloud-init and removing it will thereby wreak havoc as it would
(auto)remove plenty of other things then.
Even when not using CloudInit, it isn't much of a burden - it is small
and designed to quickly check if there is no datasource and then does
nothing.
If even that is too much you can completely disable its start, for
that check out [1]

[1]: https://cloudinit.readthedocs.io/en/latest/topics/boot.html#generator

> Thanks in advance.
>
> --
> Ubuntu-devel-discuss mailing list
> Ubuntu-devel-discuss at lists.ubuntu.com
> Modify settings or unsubscribe at: https://lists.ubuntu.com/mailman/listinfo/ubuntu-devel-discuss



-- 
Christian Ehrhardt
Staff Engineer, Ubuntu Server
Canonical Ltd



More information about the Ubuntu-devel-discuss mailing list