ExIncus. Snapshots
(ex_incus v1.0.0)
Copy Markdown
Manage instance snapshots.
{:ok, _} = ExIncus.Snapshots.create(client, "web1", "before-upgrade")
{:ok, _} = ExIncus.Snapshots.restore(client, "web1", "before-upgrade")
{:ok, _} = ExIncus.Snapshots.delete(client, "web1", "before-upgrade")
Summary
Functions
Creates a snapshot.
Deletes a snapshot.
Fetches a single snapshot.
Lists snapshots of an instance (full objects by default).
Renames a snapshot.
Restores the instance to a snapshot.
Updates a snapshot (currently only "expires_at").
Types
@type result() :: {:ok, term()} | {:error, ExIncus.Error.t()}
Functions
@spec create(ExIncus.Client.t(), String.t(), String.t(), keyword()) :: result()
Creates a snapshot.
Options: :stateful (include runtime state), :expires_at (ISO8601
string), plus the usual :wait / :timeout / :project.
@spec delete(ExIncus.Client.t(), String.t(), String.t(), keyword()) :: result()
Deletes a snapshot.
@spec get(ExIncus.Client.t(), String.t(), String.t(), keyword()) :: result()
Fetches a single snapshot.
@spec list(ExIncus.Client.t(), String.t(), keyword()) :: result()
Lists snapshots of an instance (full objects by default).
Renames a snapshot.
@spec restore(ExIncus.Client.t(), String.t(), String.t(), keyword()) :: result()
Restores the instance to a snapshot.
Updates a snapshot (currently only "expires_at").