Documentation ¶
Overview ¶
Package artifact implements interface to fetch the binary artifacts from different sources
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Artifact ¶
Artifact is an interface to download a single plugin binary.
func NewGCPArtifact ¶
NewGCPArtifact returns a new GCP storage distribution.
func NewLocalArtifact ¶
NewLocalArtifact creates Local Artifact object If path is not an absolute path search under `xdg.ConfigHome/tanzu-plugin/distribution` directory
func NewOCIArtifact ¶
NewOCIArtifact creates OCI Artifact object
func NewURIArtifact ¶
NewURIArtifact creates new artifacts based on the URI
type GCPArtifact ¶
type GCPArtifact struct { // Bucket is a Google Cloud Storage bucket. // E.g., tanzu-cli Bucket string `json:"bucket"` // ArtifactPath is a URI path that is prefixed to the object name/path. // E.g., plugins/cluster ArtifactPath string `json:"basePath"` }
GCPArtifact provides a Google Cloud Storage bucket with an optional base path (or object prefix).
type LocalArtifact ¶
type LocalArtifact struct { // Path is path to local binary artifact // if path is not an absolute path search under // `xdg.ConfigHome/tanzu-plugin/localPath` directory Path string }
LocalArtifact defines local artifact path
func (*LocalArtifact) Fetch ¶
func (l *LocalArtifact) Fetch() ([]byte, error)
Fetch reads the local artifact from its path
type OCIArtifact ¶
type OCIArtifact struct {
Image string
}
OCIArtifact defines OCI artifact image endpoint