]> git.apps.os.sepia.ceph.com Git - ceph-ci.git/commit
cephadm/build: Add Debian package support for bundled dependencies
authorKefu Chai <k.chai@proxmox.com>
Tue, 14 Oct 2025 13:04:42 +0000 (21:04 +0800)
committerKefu Chai <k.chai@proxmox.com>
Tue, 4 Nov 2025 08:43:26 +0000 (16:43 +0800)
commitedec2ed028e81f71f2ed468f20a57e7b4d9bd751
tree2451778ee73d3085fd23d210192227967195e743
parent518f24a044495bf13f38d224ac94c8071a2df228
cephadm/build: Add Debian package support for bundled dependencies

Extends the cephadm build script to support bundling dependencies from
Debian packages in addition to pip and RPM packages. This allows building
cephadm on Debian-based distributions using system packages.

Key changes:
- Add 'deb' to DependencyMode enum to enable Debian package mode
- Implement _setup_deb() to configure Debian dependency requirements
- Add _install_deb_deps() to orchestrate Debian package installation
- Add _gather_deb_package_dirs() to parse Debian package file listings
  and locate Python package directories (handles both site-packages and
  dist-packages directories used by Debian)
- Add _deps_from_deb() to extract Python dependencies from installed
  Debian packages using dpkg/apt-cache tools
- Fix variable reference bug in _install_deps() (deps.mode -> config.deps_mode)

The Debian implementation follows a similar pattern to the existing RPM
support, using dpkg-query and dpkg -L to locate installed packages and
their files, with special handling for Debian naming conventions
(e.g., PyYAML -> python3-yaml).

Signed-off-by: Kefu Chai <k.chai@proxmox.com>
src/cephadm/build.py