ryo_iso package¶
Subpackages¶
Submodules¶
ryo_iso.config module¶
-
class
ryo_iso.config.
Config
(config=PosixPath('/home/docs/checkouts/readthedocs.org/user_builds/ryo-iso/checkouts/latest/doc/iso.yml'))[source]¶ Bases:
object
Configuration State
This class stores configuration information and provides methods for validation and network updates
-
__init__
(config='~/.config/ryo-iso/config.yml')[source]¶ Loads
config
file and perform initialization
-
*distro*_init()
Performs distribution specific initialization
-
build_dir
= PosixPath('/home/docs/checkouts/readthedocs.org/user_builds/ryo-iso/checkouts/latest/doc')¶
-
data
= {'app': PosixPath('/home/docs/.config/ryo-iso/config.yml'), 'base': PosixPath('/home/docs/.config/ryo-iso/iso_base.yml'), 'iso': PosixPath('/home/docs/checkouts/readthedocs.org/user_builds/ryo-iso/checkouts/latest/doc/iso.yml')}¶
-
static
deep_merge
(overlay, base)[source]¶ Deep merge dictionaries
This method recursivly merges dictionaries, where
base
provides defaults for the dictionaryoverlay
. Sub-lists and dictionaries inside lists are replaced and not merged.Parameters: - overlay (dict) – This dictionary is modified in place to contain the merged results.
- base (dict) – Provides default values not found in the overlay.
-
classmethod
install
(force=False)[source]¶ Install user config files.
This function installs the application and project config files.
Parameters: force (bool) – Overwrite existing config files
-
ubuntu_base_image_check
()[source]¶ Ubuntu - Verify the SHA256SUM of the upstream ISO image
This function runs
sha256sum -c
onself.build_dir/'base_image.iso'
-
ubuntu_hash_cache
()[source]¶ Ubuntu - SHA256 checksum download
This function downloads the hashes and the associated gpg signature file.
['SHA256SUMS', 'SHA256SUMS.gpg']
-
ubuntu_hash_check
()[source]¶ Ubuntu - Verify GPG signature of SHA256 checksum download
This function verifies the GPG signature of
SHA256SUMS
from the local keyring.
-
ubuntu_hash_version
()[source]¶ Ubuntu - Parse and extract version information from hash file
Parses version information from configuration and extracts the full version
yy.mm.patch
fromSHA256SUMS
from the local keyring.The function can extend the configured version from
yy.mm
intoyy.mm.patch
for easier upstream tracking. It can also convert from codenames (ex.xenial
) toyy.mm.patch
(ex.16.04.6
).Finally this function constructs the url of the Ubuntu release from the version and variant configuration.
-
ryo_iso.utils module¶
-
ryo_iso.utils.
cleanup_data
()[source]¶ Clean up build artifacts
Removes [‘./squashfs-root’,’./image’,’./build’]
Warning
Do not manually
rm -rf squashfs-root
if the chrooted devices are mounted
-
ryo_iso.utils.
profile_start
()[source]¶ Start pydoit profiler
This python-action returns a dictionary with the profiler start time, which is made available to other actions in the same Task instance
Returns: ‘start’: start time of the profiler Return type: dict
-
ryo_iso.utils.
profile_stop
(task, **kwargs)[source]¶ Stop pydoit profiler
This python-action accesses the start time from the
profile_start()
actionParameters: - task (dict) – Access to start time via pydoit Task instance
- **kwargs (dict) – Keyword argument access to start time
Returns: ‘duration’: profiler duration
Return type: dict