diskimage_builder package¶
Subpackages¶
- diskimage_builder.block_device package
- Subpackages
- diskimage_builder.block_device.level0 package
- diskimage_builder.block_device.level1 package
- diskimage_builder.block_device.level2 package
- diskimage_builder.block_device.level3 package
- diskimage_builder.block_device.level4 package
- diskimage_builder.block_device.tests package
- Subpackages
- Submodules
- diskimage_builder.block_device.tests.test_base module
- diskimage_builder.block_device.tests.test_config module
- diskimage_builder.block_device.tests.test_gpt module
- diskimage_builder.block_device.tests.test_lvm module
- diskimage_builder.block_device.tests.test_mbr module
- diskimage_builder.block_device.tests.test_mkfs module
- diskimage_builder.block_device.tests.test_mount_order module
- diskimage_builder.block_device.tests.test_state module
- diskimage_builder.block_device.tests.test_utils module
- Module contents
- Submodules
- diskimage_builder.block_device.blockdevice module
- diskimage_builder.block_device.cmd module
- diskimage_builder.block_device.config module
- diskimage_builder.block_device.exception module
- diskimage_builder.block_device.plugin module
- diskimage_builder.block_device.utils module
- Module contents
- Subpackages
Submodules¶
diskimage_builder.disk_image_create module¶
- diskimage_builder.disk_image_create.main()¶
diskimage_builder.diskimage_builder module¶
- class diskimage_builder.diskimage_builder.Arg(key, description, schema_type=None, arg=None)¶
Bases:
SchemaProperty
Command argument with associated value
- arg = None¶
- arg_name()¶
- to_argument(value=None)¶
- class diskimage_builder.diskimage_builder.ArgDictToString(key, description, arg=None)¶
Bases:
Arg
Dict with string values converted to key=value,key2=value2 argument
- to_argument(value)¶
- to_schema()¶
- type_help()¶
- class diskimage_builder.diskimage_builder.ArgEnum(key, description, schema_type='string', arg=None, enum=None)¶
Bases:
Arg
String argument constrained to a list of allowed values
- enum = None¶
- to_schema()¶
- type_help()¶
- class diskimage_builder.diskimage_builder.ArgEnumList(key, description, arg=None, enum=None)¶
Bases:
ArgList
List of strings constrained to a list of allowed values
- enum = None¶
- to_schema()¶
- type_help()¶
- class diskimage_builder.diskimage_builder.ArgFlag(key, description, arg=None)¶
Bases:
Arg
Boolean value for a flag argument being set or not
- to_argument(value=None)¶
- type_help()¶
- class diskimage_builder.diskimage_builder.ArgFlagRepeating(key, description, arg=None, max_repeat=0)¶
Bases:
ArgEnum
Flag argument which repeats the specified number of times
- to_argument(value)¶
- type_help()¶
- class diskimage_builder.diskimage_builder.ArgInt(key, description, arg=None, minimum=1)¶
Bases:
Arg
Integer argument which a minumum constraint
- minimum = 1¶
- to_argument(value)¶
- to_schema()¶
- type_help()¶
- class diskimage_builder.diskimage_builder.ArgList(key, description, arg=None)¶
Bases:
Arg
List of strings converted to comma delimited argument
- to_argument(value)¶
- to_schema()¶
- type_help()¶
- class diskimage_builder.diskimage_builder.ArgListPositional(key, description)¶
Bases:
ArgList
List of strings converted to positional arguments
- to_argument(value)¶
- type_help()¶
- class diskimage_builder.diskimage_builder.Command(script, properties, entry)¶
Bases:
object
- args = None¶
- command()¶
- environ = None¶
- merged_env()¶
- script = None¶
- class diskimage_builder.diskimage_builder.Env(key, description)¶
Bases:
SchemaProperty
String dict schema for environment variables
- to_schema()¶
- type_help()¶
- class diskimage_builder.diskimage_builder.Flag(key, description)¶
Bases:
Arg
Boolean value which does not contribute to arguments
- to_argument(value=None)¶
- type_help()¶
- class diskimage_builder.diskimage_builder.SchemaProperty(key, description, schema_type=None)¶
Bases:
object
Base class for a basic schema and a help string
- description = None¶
- key = None¶
- schema_type = 'string'¶
- to_help()¶
- to_schema()¶
- type_help()¶
- diskimage_builder.diskimage_builder.build_commands(definition)¶
- diskimage_builder.diskimage_builder.get_args()¶
- diskimage_builder.diskimage_builder.help_properties()¶
- diskimage_builder.diskimage_builder.main()¶
- diskimage_builder.diskimage_builder.merge_entry(merged_entry, entry)¶
diskimage_builder.element_dependencies module¶
- exception diskimage_builder.element_dependencies.AlreadyProvidedException¶
Bases:
Exception
- class diskimage_builder.element_dependencies.Element(name, path)¶
Bases:
object
An element
- exception diskimage_builder.element_dependencies.InvalidElementDir¶
Bases:
Exception
- exception diskimage_builder.element_dependencies.MissingElementException¶
Bases:
Exception
- exception diskimage_builder.element_dependencies.MissingOSException¶
Bases:
Exception
- diskimage_builder.element_dependencies.expand_dependencies(user_elements, element_dirs)¶
Deprecated method for expanding element dependencies.
Warning
DO NOT USE THIS FUNCTION. For compatibility reasons, this function does not provide paths to the returned elements. This means the caller must process override rules if two elements with the same name appear in element_dirs
- Parameters:
user_elements – iterable enumerating the elements a user requested
element_dirs – The ELEMENTS_PATH to process
- Returns:
a set containing user_elements and all dependent elements including any transitive dependencies.
- diskimage_builder.element_dependencies.get_elements(elements, paths=None)¶
Return the canonical list of elements with their dependencies
Note
You probably do not want to use this! Elements that require access to the list of all other elements should generally use the environment variables exported by disk-image-create below.
- Parameters:
elements – user specified elements
paths – Alternative ELEMENTS_PATH; default is to use from env
- Returns:
A de-duplicated list of tuples [(element, path), (element, path) …] with all elements and their dependents, including any transitive dependencies.
- diskimage_builder.element_dependencies.main()¶
diskimage_builder.logging_config module¶
- class diskimage_builder.logging_config.DibFormatter(*args, **kwargs)¶
Bases:
Formatter
- format(record)¶
Format the specified record as text.
The record’s attribute dictionary is used as the operand to a string formatting operation which yields the returned string. Before formatting the dictionary, a couple of preparatory steps are carried out. The message attribute of the record is computed using LogRecord.getMessage(). If the formatting string uses the time (as determined by a call to usesTime(), formatTime() is called to format the event time. If there is exception information, it is formatted using formatException() and appended to the message.
- diskimage_builder.logging_config.setup()¶
diskimage_builder.paths module¶
Export paths
- diskimage_builder.paths.get_path(var)¶
- diskimage_builder.paths.show_path(var)¶