Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

hooks: remove dhcpcd-base #186

Merged

Conversation

Meulengracht
Copy link
Member

@Meulengracht Meulengracht commented Feb 20, 2024

Cloud-init now pulls in dhcpcd-base, which we are not interested in (currently). After speaking with the Server team this is due to the fact that isc-dhcp-client is becoming deprecated, and replaced by dhcpcd. However cloud-init supports multiple dhcp clients and does not in fact need dhcpcd-base currently.

Copy link
Member

@alfonsosanchezbeato alfonsosanchezbeato left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM but please look at comment

# multiple dhcp clients. This change occurred recently (from time of commit)
# since isc-dhcp-client will be deprecated and is currently in the process
# of being demoted from packages in main universe.
dpkg --purge --force-depends dhcpcd-base

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nitpick: maybe a bug should be opened against cloud-init so they improve the packaging to make this optional, and then add the reference to the bug here.

@Meulengracht Meulengracht merged commit 7f30d5c into snapcore:main Feb 22, 2024
2 of 3 checks passed
@Meulengracht
Copy link
Member Author

Tested that should anyone need dhcdpcd, they can include it in their snap and run dhcpcd as root. The user created by the package is not required for operating.

@holmanb
Copy link

holmanb commented Mar 25, 2024

However cloud-init supports multiple dhcp clients and does not in fact need dhcpcd-base currently.

@Meulengracht true, but cloud-init still requires a working dhcp client to be installed

nitpick: maybe a bug should be opened against cloud-init so they improve the packaging to make this optional, and then add the reference to the bug here.

@alfonsosanchezbeato Good point, but this was already considered. The Ubuntu deb packaging requires only dhcpcd-base because dhcpcd-base is expected to be the only client in main[1] on Noble that meets the needs of cloud-init. Since isc-dhcp-client isn't expected to remain in main in 24.04, there is no point as including it as an optional dependency.

Using the isc-dhcp-client is only expected on Ubuntu in the following cases 1) Ubuntu on series older than Noble and 2) Noble+ if the user manually installs isc-dhcp-client and then forces cloud-init to use it via a configuration setting. Since dhcpcd-base is included in the initramfs, ubuntu-minimal, etc[2], it is expected that on Noble and later, dhcpcd-base will always be available.

[1] 2 if you include busybox, but that is currently not fully supported yet

[2] various projects that made this transition off of isc-dhcp-client

$ apt rdepends dhcpcd-base
dhcpcd-base
Reverse Depends:
  Depends: cloud-init
 |Recommends: madwimax
 |Depends: libguestfs0
  Depends: dhcpcd
  Depends: ubuntu-minimal
  Depends: initramfs-tools-core

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants