OSTree.SysrootUpgrader¶
- Subclasses:
None
Methods¶
- Inherited:
- Structs:
class |
|
class |
|
class |
|
class |
|
|
|
|
|
|
|
|
|
|
|
|
Virtual Methods¶
- Inherited:
Properties¶
Name |
Type |
Flags |
Short Description |
|---|---|---|---|
r/w/co |
|||
r/w/co |
|||
r/w/co |
Signals¶
- Inherited:
Fields¶
- Inherited:
Class Details¶
- class OSTree.SysrootUpgrader(**kwargs)¶
- Bases:
- Abstract:
No
- classmethod check_timestamps(repo, from_rev, to_rev)¶
- Parameters:
repo (
OSTree.Repo) – Repofrom_rev (
str) – From revisionto_rev (
str) – To revision
- Raises:
- Return type:
Check that the timestamp on to_rev is equal to or newer than from_rev. This protects systems against man-in-the-middle attackers which provide a client with an older commit.
- classmethod new(sysroot, cancellable)¶
- Parameters:
sysroot (
OSTree.Sysroot) – AnOSTree.Sysrootcancellable (
Gio.CancellableorNone) – Cancellable
- Raises:
- Returns:
An upgrader
- Return type:
- classmethod new_for_os(sysroot, osname, cancellable)¶
- Parameters:
sysroot (
OSTree.Sysroot) – AnOSTree.Sysrootcancellable (
Gio.CancellableorNone) – Cancellable
- Raises:
- Returns:
An upgrader
- Return type:
- classmethod new_for_os_with_flags(sysroot, osname, flags, cancellable)¶
- Parameters:
sysroot (
OSTree.Sysroot) – AnOSTree.Sysrootflags (
OSTree.SysrootUpgraderFlags) – Flagscancellable (
Gio.CancellableorNone) – Cancellable
- Raises:
- Returns:
An upgrader
- Return type:
- deploy(cancellable)¶
- Parameters:
cancellable (
Gio.CancellableorNone) – Cancellable- Raises:
- Return type:
Write the new deployment to disk, perform a configuration merge with /etc, and update the bootloader configuration.
- dup_origin()¶
- Returns:
A copy of the origin file, or
Noneif unknown.- Return type:
GLib.KeyFileorNone
- get_origin()¶
- Returns:
The origin file, or
Noneif unknown.- Return type:
GLib.KeyFileorNone
- get_origin_description()¶
- pull(flags, upgrader_flags, progress, cancellable)¶
- Parameters:
flags (
OSTree.RepoPullFlags) – Flags controlling pull behaviorupgrader_flags (
OSTree.SysrootUpgraderPullFlags) – Flags controlling upgrader behaviorprogress (
OSTree.AsyncProgressorNone) – Progresscancellable (
Gio.CancellableorNone) – Cancellable
- Raises:
- Returns:
- out_changed:
Whether or not the origin changed
- Return type:
Perform a pull from the origin. First check if the ref has changed, if so download the linked objects, and store the updated ref locally. Then out_changed will be
True.If the origin remote is unchanged, out_changed will be set to
False.
- pull_one_dir(dir_to_pull, flags, upgrader_flags, progress, cancellable)¶
- Parameters:
dir_to_pull (
str) – Subdirectory path (should include a leading /)flags (
OSTree.RepoPullFlags) – Flags controlling pull behaviorupgrader_flags (
OSTree.SysrootUpgraderPullFlags) – Flags controlling upgrader behaviorprogress (
OSTree.AsyncProgressorNone) – Progresscancellable (
Gio.CancellableorNone) – Cancellable
- Raises:
- Returns:
- out_changed:
Whether or not the origin changed
- Return type:
Like
OSTree.SysrootUpgrader.pull(), but allows retrieving just a subpath of the tree. This can be used to download metadata files from inside the tree such as package databases.
- set_origin(origin, cancellable)¶
- Parameters:
origin (
GLib.KeyFileorNone) – The new origincancellable (
Gio.CancellableorNone) – Cancellable
- Raises:
- Return type:
Replace the origin with origin.
Property Details¶
- OSTree.SysrootUpgrader.props.flags¶
- Name:
flags- Type:
- Default Value:
0- Flags:
- OSTree.SysrootUpgrader.props.osname¶
- Name:
osname- Type:
- Default Value:
- Flags:
- OSTree.SysrootUpgrader.props.sysroot¶
- Name:
sysroot- Type:
- Default Value:
- Flags: