Documentation
¶
Index ¶
- Constants
- func AddConfig(opts flagsets.ConfigOptions, config flagsets.Config) error
- func ConfigHandler() flagsets.ConfigOptionTypeSetHandler
- type AccessSpec
- func (a *AccessSpec) AccessMethod(c cpi.ComponentVersionAccess) (cpi.AccessMethod, error)
- func (a *AccessSpec) Describe(ctx cpi.Context) string
- func (a *AccessSpec) GetInexpensiveContentVersionIdentity(c cpi.ComponentVersionAccess) string
- func (a *AccessSpec) GlobalAccessSpec(ctx cpi.Context) cpi.AccessSpec
- func (_ *AccessSpec) IsLocal(cpi.Context) bool
- func (a AccessSpec) MarshalJSON() ([]byte, error)
- type AccessSpecV1
- type AccessSpecV2
Constants ¶
View Source
const ( Type = "s3" LegacyType = "S3" LegacyTypeV1 = LegacyType + runtime.VersionSeparator + "v1" )
Type is the access type of S3 registry.
View Source
const LegacyTypeV2 = LegacyType + runtime.VersionSeparator + "v2"
View Source
const TypeV1 = Type + runtime.VersionSeparator + "v1"
View Source
const TypeV2 = Type + runtime.VersionSeparator + "v2"
Variables ¶
This section is empty.
Functions ¶
func ConfigHandler ¶
func ConfigHandler() flagsets.ConfigOptionTypeSetHandler
Types ¶
type AccessSpec ¶
type AccessSpec struct {
runtime.InternalVersionedTypedObject[cpi.AccessSpec]
// 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
// Bucket where the s3 object is located.
Bucket string
// Key of the object to look for. This value will be used together with Bucket and Version to form an identity.
Key string
// Version of the object.
// +optional
Version string
// MediaType defines the mime type of the object to download.
// +optional
MediaType string
// contains filtered or unexported fields
}
AccessSpec describes the access for a S3 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 (a *AccessSpec) AccessMethod(c cpi.ComponentVersionAccess) (cpi.AccessMethod, error)
func (*AccessSpec) GetInexpensiveContentVersionIdentity ¶ added in v0.3.0
func (a *AccessSpec) GetInexpensiveContentVersionIdentity(c cpi.ComponentVersionAccess) string
func (*AccessSpec) GlobalAccessSpec ¶ added in v0.3.0
func (a *AccessSpec) GlobalAccessSpec(ctx cpi.Context) cpi.AccessSpec
func (AccessSpec) MarshalJSON ¶ added in v0.3.0
func (a AccessSpec) MarshalJSON() ([]byte, error)
type AccessSpecV1 ¶ added in v0.3.0
type AccessSpecV1 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"`
}
AccessSpecV1 describes the v1 format.
type AccessSpecV2 ¶ added in v0.3.0
type AccessSpecV2 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:"bucketName"`
// Key of the object to look for. This value will be used together with Bucket and Version to form an identity.
Key string `json:"objectKey"`
// 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"`
}
AccessSpecV2 describes the v2 format.
Click to show internal directories.
Click to hide internal directories.