manifests

package
v0.0.0-...-3883afe Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 28, 2022 License: Apache-2.0 Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ByteRange

type ByteRange struct {
	Start int64 `xml:"start,attr"`
	End   int64 `xml:"end,attr"`
}

ByteRange is used for XML generation of a Import Volume Manifest

type ImportVolumeManifest

type ImportVolumeManifest struct {
	XMLName         xml.Name        `xml:"manifest"`
	Version         string          `xml:"version"`
	FileFormat      string          `xml:"file-format"`
	ImporterName    string          `xml:"importer>name"`
	ImporterVersion string          `xml:"importer>version"`
	ImporterRelease string          `xml:"importer>release"`
	SelfDestructURL string          `xml:"self-destruct-url"`
	SizeBytes       int64           `xml:"import>size"`
	VolumeSizeGB    int64           `xml:"import>volume-size"`
	Parts           PartsCollection `xml:"import>parts"`
}

ImportVolumeManifest will produce an Import Volume Manifest when marshalled to XML

func New

func New(imageProperties MachineImageProperties) *ImportVolumeManifest

New returns an Import Volume Manifest ready for marshalling to XML

type MachineImagePart

type MachineImagePart struct {
	Index     int       `xml:"index,attr"`
	ByteRange ByteRange `xml:"byte-range"`
	Key       string    `xml:"key"`
	HeadURL   string    `xml:"head-url"`
	GetURL    string    `xml:"get-url"`
	DeleteURL string    `xml:"delete-url"`
}

MachineImagePart is used for XML generation of a Import Volume Manifest

type MachineImageProperties

type MachineImageProperties struct {
	KeyName      string
	HeadURL      string
	GetURL       string
	DeleteURL    string
	SizeBytes    int64
	VolumeSizeGB int64
	FileFormat   string
}

MachineImageProperties contains information needed by AWS to download a machine image from S3

type PartsCollection

type PartsCollection struct {
	Count int              `xml:"count,attr"`
	Part  MachineImagePart `xml:"part"`
}

PartsCollection is used for XML generation of a Import Volume Manifest

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL