Documentation
¶
Index ¶
- Constants
- type BackupFileEntry
- type BackupRunAccepted
- type CreateS3Destination
- type CreateSystemBackupRequest
- type DeleteSystemBackupRequest
- type DiscoverSystemBackupsRequest
- type HistoryEntry
- type ManagementType
- type RestoreSelection
- type RestoreSystemBackupFilesRequest
- type RestoreSystemBackupRequest
- type RunSystemVolumeBackupsRequest
- type S3Destination
- type S3DestinationSync
- type S3DestinationSyncRequest
- type SystemBackupDestination
- type SystemBackupPolicy
- type SystemBackupPolicyCollection
- type SystemBackupRecoveryKey
- type SystemBackupRecoveryKeyStatus
- type SystemBackupRun
- type SystemVolumeBackupCustomRun
- type SystemVolumeBackupFailure
- type SystemVolumeBackupOption
- type SystemVolumeBackupPolicy
- type SystemVolumeBackupPolicyCollection
- type SystemVolumeBackupRunResult
- type SystemVolumeSelectionMode
- type UpdateBackupPolicy
- type UpdateS3Destination
- type UpdateSystemBackupPolicies
- type UpdateSystemBackupPolicy
- type UpdateSystemVolumeBackupPolicies
- type UpdateSystemVolumeBackupPolicy
- type UploadSystemBackupRequest
Constants ¶
const SystemVolumePolicyPrefix = "system-volume:"
SystemVolumePolicyPrefix marks volume-backup records created by the centralized system policy.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type BackupFileEntry ¶ added in v2.10.0
type BackupFileEntry struct {
Path string `json:"path"`
Name string `json:"name"`
IsDirectory bool `json:"isDirectory"`
}
BackupFileEntry describes one file or directory under a backup's logical restore root.
type BackupRunAccepted ¶ added in v2.10.2
type BackupRunAccepted struct {
ActivityID string `json:"activityId"`
Status string `json:"status"`
}
BackupRunAccepted identifies a backup operation accepted for background execution.
type CreateS3Destination ¶
type CreateS3Destination struct {
Name string `json:"name"`
Endpoint string `json:"endpoint,omitempty"`
Bucket string `json:"bucket"`
Region string `json:"region"`
AccessKeyID string `json:"accessKeyId"`
SecretAccessKey string `json:"secretAccessKey"`
Prefix string `json:"prefix,omitempty"`
UseSSL bool `json:"useSsl"`
ForcePathStyle bool `json:"forcePathStyle"`
}
type CreateSystemBackupRequest ¶
type CreateSystemBackupRequest struct {
Destination SystemBackupDestination `json:"destination,omitempty"`
S3DestinationID string `json:"s3DestinationId,omitempty"`
RecoveryKey string `json:"recoveryKey,omitempty"`
PolicyID string `json:"policyId,omitempty"`
}
type DeleteSystemBackupRequest ¶
type DeleteSystemBackupRequest struct {
RecoveryKey string `json:"recoveryKey,omitempty"`
}
type HistoryEntry ¶ added in v2.10.0
type HistoryEntry struct {
ID string `json:"id" sortable:"true"`
Size int64 `json:"size" sortable:"true"`
CreatedAt time.Time `json:"createdAt" sortable:"true"`
Status string `json:"status" sortable:"true"`
Trigger string `json:"trigger" sortable:"true"`
Destination SystemBackupDestination `json:"destination" sortable:"true"`
Format string `json:"format,omitempty"`
LocalSnapshotID string `json:"localSnapshotId,omitempty"`
RemoteSnapshotID string `json:"remoteSnapshotId,omitempty"`
S3DestinationID string `json:"s3DestinationId,omitempty"`
S3DestinationName string `json:"s3DestinationName,omitempty"`
PolicyID string `json:"policyId,omitempty"`
Error string `json:"error,omitempty"`
Type ManagementType `json:"type" sortable:"true"`
ResourceType string `json:"resourceType"`
ResourceName string `json:"resourceName" sortable:"true"`
}
HistoryEntry is a common view over Arcane recovery and volume backup records.
type ManagementType ¶ added in v2.10.0
type ManagementType string
ManagementType identifies which Arcane configuration orchestrated a backup.
const ( ManagementTypeSystem ManagementType = "system" ManagementTypeVolume ManagementType = "volume" )
type RestoreSelection ¶ added in v2.10.0
type RestoreSelection struct {
Paths []string `json:"paths,omitempty"`
SelectAll bool `json:"selectAll,omitempty"`
Search string `json:"search,omitempty"`
}
RestoreSelection selects explicit paths or every eligible backup entry.
type RestoreSystemBackupFilesRequest ¶ added in v2.10.0
type RestoreSystemBackupFilesRequest struct {
RestoreSelection
RecoveryKey string `json:"recoveryKey"`
}
RestoreSystemBackupFilesRequest selects project files to restore from a system backup.
type RestoreSystemBackupRequest ¶
type RestoreSystemBackupRequest struct {
RecoveryKey string `json:"recoveryKey"`
}
type RunSystemVolumeBackupsRequest ¶ added in v2.10.0
type RunSystemVolumeBackupsRequest struct {
PolicyID string `json:"policyId,omitempty"`
Custom *SystemVolumeBackupCustomRun `json:"custom,omitempty"`
}
RunSystemVolumeBackupsRequest selects a saved policy or supplies a transient custom policy.
type S3Destination ¶
type S3Destination struct {
ID string `json:"id"`
Name string `json:"name"`
Endpoint string `json:"endpoint,omitempty"`
Bucket string `json:"bucket"`
Region string `json:"region"`
AccessKeyID string `json:"accessKeyId"`
Prefix string `json:"prefix,omitempty"`
UseSSL bool `json:"useSsl"`
ForcePathStyle bool `json:"forcePathStyle"`
SecretConfigured bool `json:"secretConfigured"`
CreatedAt time.Time `json:"createdAt"`
UpdatedAt *time.Time `json:"updatedAt,omitempty"`
}
type S3DestinationSync ¶
type S3DestinationSyncRequest ¶
type S3DestinationSyncRequest struct {
Destinations []S3DestinationSync `json:"destinations"`
}
type SystemBackupDestination ¶
type SystemBackupDestination string
const ( SystemBackupDestinationLocal SystemBackupDestination = "local" SystemBackupDestinationS3 SystemBackupDestination = "s3" SystemBackupDestinationLocalS3 SystemBackupDestination = "local_s3" )
type SystemBackupPolicy ¶
type SystemBackupPolicy struct {
ID string `json:"id"`
Enabled bool `json:"enabled"`
Schedule string `json:"schedule"`
RetentionCount int `json:"retentionCount"`
LocalEnabled bool `json:"localEnabled"`
S3Enabled bool `json:"s3Enabled"`
S3DestinationID string `json:"s3DestinationId,omitempty"`
S3DestinationName string `json:"s3DestinationName,omitempty"`
LastRun *SystemBackupRun `json:"lastRun,omitempty"`
}
type SystemBackupPolicyCollection ¶
type SystemBackupPolicyCollection struct {
Policies []SystemBackupPolicy `json:"policies"`
RecoveryKeyStored bool `json:"recoveryKeyStored"`
}
type SystemBackupRecoveryKey ¶
type SystemBackupRecoveryKey struct {
RecoveryKey string `json:"recoveryKey"`
}
type SystemBackupRecoveryKeyStatus ¶
type SystemBackupRecoveryKeyStatus struct {
Configured bool `json:"configured"`
}
type SystemBackupRun ¶
type SystemBackupRun struct {
ActivityID string `json:"activityId,omitempty"`
ID string `json:"id"`
Size int64 `json:"size"`
CreatedAt time.Time `json:"createdAt"`
Status string `json:"status"`
Trigger string `json:"trigger"`
Destination SystemBackupDestination `json:"destination"`
LocalSnapshotID string `json:"localSnapshotId,omitempty"`
RemoteSnapshotID string `json:"remoteSnapshotId,omitempty"`
S3DestinationID string `json:"s3DestinationId,omitempty"`
S3DestinationName string `json:"s3DestinationName,omitempty"`
PolicyID string `json:"policyId,omitempty"`
Error string `json:"error,omitempty"`
}
type SystemVolumeBackupCustomRun ¶ added in v2.10.0
type SystemVolumeBackupCustomRun struct {
Destination SystemBackupDestination `json:"destination"`
S3DestinationID string `json:"s3DestinationId,omitempty"`
StopContainers bool `json:"stopContainers"`
SelectionMode SystemVolumeSelectionMode `json:"selectionMode"`
VolumeNames []string `json:"volumeNames"`
IgnoreAnonymous bool `json:"ignoreAnonymous"`
}
SystemVolumeBackupCustomRun is a transient policy used by Create -> Backup.
type SystemVolumeBackupFailure ¶ added in v2.10.0
type SystemVolumeBackupFailure struct {
VolumeName string `json:"volumeName"`
Error string `json:"error"`
}
SystemVolumeBackupFailure records one candidate that could not be backed up.
type SystemVolumeBackupOption ¶ added in v2.10.0
type SystemVolumeBackupOption struct {
Name string `json:"name"`
Anonymous bool `json:"anonymous"`
Available bool `json:"available"`
}
SystemVolumeBackupOption describes a selectable live or unavailable configured volume.
type SystemVolumeBackupPolicy ¶ added in v2.10.0
type SystemVolumeBackupPolicy struct {
ID string `json:"id"`
Enabled bool `json:"enabled"`
Schedule string `json:"schedule"`
RetentionCount int `json:"retentionCount"`
StopContainers bool `json:"stopContainers"`
LocalEnabled bool `json:"localEnabled"`
S3Enabled bool `json:"s3Enabled"`
S3DestinationID string `json:"s3DestinationId,omitempty"`
S3DestinationName string `json:"s3DestinationName,omitempty"`
SelectionMode SystemVolumeSelectionMode `json:"selectionMode"`
VolumeNames []string `json:"volumeNames"`
IgnoreAnonymous bool `json:"ignoreAnonymous"`
LastRun *SystemBackupRun `json:"lastRun,omitempty"`
}
SystemVolumeBackupPolicy is one manager-owned policy for local Docker volumes.
type SystemVolumeBackupPolicyCollection ¶ added in v2.10.0
type SystemVolumeBackupPolicyCollection struct {
Policies []SystemVolumeBackupPolicy `json:"policies"`
}
type SystemVolumeBackupRunResult ¶ added in v2.10.0
type SystemVolumeBackupRunResult struct {
Matched int `json:"matched"`
Succeeded int `json:"succeeded"`
Failed int `json:"failed"`
Skipped int `json:"skipped"`
Failures []SystemVolumeBackupFailure `json:"failures"`
}
SystemVolumeBackupRunResult summarizes a centralized multi-volume execution.
type SystemVolumeSelectionMode ¶ added in v2.10.0
type SystemVolumeSelectionMode string
SystemVolumeSelectionMode controls how configured volume names affect live Docker volumes.
const ( SystemVolumeSelectionAll SystemVolumeSelectionMode = "all" SystemVolumeSelectionAllowlist SystemVolumeSelectionMode = "allowlist" SystemVolumeSelectionBlocklist SystemVolumeSelectionMode = "blocklist" )
type UpdateBackupPolicy ¶
type UpdateBackupPolicy struct {
ID string `json:"id,omitempty"`
Enabled bool `json:"enabled"`
Schedule string `json:"schedule"`
RetentionCount int `json:"retentionCount"`
StopContainers bool `json:"stopContainers,omitempty"`
LocalEnabled bool `json:"localEnabled"`
S3Enabled bool `json:"s3Enabled"`
S3DestinationID string `json:"s3DestinationId,omitempty"`
}
UpdateBackupPolicy is the shared policy-update payload for every backup domain; StopContainers only applies to volume backups.
type UpdateS3Destination ¶
type UpdateS3Destination = CreateS3Destination
UpdateS3Destination carries the same connection fields as create; an empty SecretAccessKey keeps the stored secret.
type UpdateSystemBackupPolicies ¶
type UpdateSystemBackupPolicies struct {
Policies []UpdateSystemBackupPolicy `json:"policies"`
}
type UpdateSystemBackupPolicy ¶
type UpdateSystemBackupPolicy = UpdateBackupPolicy
type UpdateSystemVolumeBackupPolicies ¶ added in v2.10.0
type UpdateSystemVolumeBackupPolicies struct {
Policies []UpdateSystemVolumeBackupPolicy `json:"policies"`
}
type UpdateSystemVolumeBackupPolicy ¶ added in v2.10.0
type UpdateSystemVolumeBackupPolicy struct {
UpdateBackupPolicy
SelectionMode SystemVolumeSelectionMode `json:"selectionMode"`
VolumeNames []string `json:"volumeNames"`
IgnoreAnonymous bool `json:"ignoreAnonymous"`
}
UpdateSystemVolumeBackupPolicy is the writable centralized policy shape.