s3

package
v0.1.0-alpha.2 Latest Latest
Warning

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

Go to latest
Published: Dec 16, 2022 License: Apache-2.0 Imports: 15 Imported by: 0

README

s3 - Blobs in a Simple Storage System (S3)

Synopsis
type: s3/v1

Provided blobs use the following media type: attribute mediaType

Description

This method implements the access of a blob stored in an S3 bucket.

Specification Versions

Supported specification version is v1

Version v1

The type specific specification fields are:

  • region (optional) string

    OCI repository reference (this artifact name used to store the blob).

  • bucket string

    The name of the S3 bucket containing the blob

  • key string

    The key of the desired blob

Documentation

Index

Constants

View Source
const (
	TypeV1        = Type + runtime.VersionSeparator + "v1"
	CONSUMER_TYPE = "s3"
)
View Source
const Type = "S3"

Type is the access type of S3 registry.

Variables

This section is empty.

Functions

func AddConfig

func AddConfig(opts flagsets.ConfigOptions, config flagsets.Config) error

Types

type AccessSpec

type AccessSpec struct {
	runtime.ObjectVersionedType `json:",inline"`

	// Region needs to be set even though buckets are global.
	// We can't assume that there is a default region setting sitting somewhere.
	// +optional
	Region string `json:"region,omitempty"`
	// Bucket where the s3 object is located.
	Bucket string `json:"bucket"`
	// Key of the object to look for. This value will be used together with Bucket and Version to form an identity.
	Key string `json:"key"`
	// Version of the object.
	// +optional
	Version string `json:"version,omitempty"`
	// MediaType defines the mime type of the object to download.
	// +optional
	MediaType string `json:"mediaType,omitempty"`
	// contains filtered or unexported fields
}

AccessSpec describes the access for a GitHub registry.

func New

func New(region, bucket, key, version, mediaType string, downloader downloader.Downloader) *AccessSpec

New creates a new GitHub registry access spec version v1.

func (*AccessSpec) AccessMethod

func (*AccessSpec) Describe

func (a *AccessSpec) Describe(ctx cpi.Context) string

func (*AccessSpec) GetType

func (_ *AccessSpec) GetType() string

func (*AccessSpec) IsLocal

func (_ *AccessSpec) IsLocal(cpi.Context) bool

Jump to

Keyboard shortcuts

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