thoth.package_extract package¶
Submodules¶
thoth.package_extract.cli module¶
Command line interface for thoth-package-extract.
thoth.package_extract.core module¶
Implementation of core routines for thoth-package-extract.
thoth.package_extract.exceptions module¶
Exception hierarchy in thoth-package-extract tool.
- exception thoth.package_extract.exceptions.InvalidImageError[source]¶
Bases:
thoth.package_extract.exceptions.ThothPkgdepsException
Raised on invalid Docker image.
- exception thoth.package_extract.exceptions.NotSupported[source]¶
Bases:
thoth.package_extract.exceptions.ThothPkgdepsException
Raised on requesting an unsupported operation.
- exception thoth.package_extract.exceptions.ThothPkgdepsException[source]¶
Bases:
Exception
A base exception in the thoth-package-extract exception hierarchy.
- exception thoth.package_extract.exceptions.TimeoutExpired[source]¶
Bases:
thoth.package_extract.exceptions.ThothPkgdepsException
Raised on command timeout.
thoth.package_extract.image module¶
Manipulation with an image and image scanning.
- thoth.package_extract.image.construct_rootfs(dir_path: str, rootfs_path: str) list [source]¶
Construct rootfs in a directory by extracting layers.
- thoth.package_extract.image.download_image(image_name: str, dir_path: str, timeout: Optional[int] = None, registry_credentials: Optional[str] = None, tls_verify: bool = True) None [source]¶
Download an image to dir_path.
thoth.package_extract.rpmlib module¶
Functionality copied from kobo.
Even though copying code is not nice at all, this is better to have copied. Assuming naming is mature and stable enough, it should be safe to have them there.
- The original code can be found at:
https://github.com/release-engineering/kobo/blob/master/kobo/rpmlib.py
Note we used code from Koji before, but that looks to be broken in some cases.
- thoth.package_extract.rpmlib.parse_nvr(nvre)[source]¶
Split N-V-R into a dictionary.
@param nvre: N-V-R:E, E:N-V-R or N-E:V-R string @type nvre: str @return: {name, version, release, epoch} @rtype: dict
Module contents¶
Extraction of installed packages for project Thoth.