upstream

package
v1.31.1 Latest Latest
Warning

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

Go to latest
Published: Feb 23, 2021 License: Apache-2.0 Imports: 43 Imported by: 0

Documentation

Index

Constants

View Source
const DefaultMetadata = `` /* 232-byte string literal not displayed */

Variables

View Source
var KnownRepos = map[string]string{
	"stable":  "https://kubernetes-charts.storage.googleapis.com",
	"local":   "http://127.0.0.1:8879",
	"elastic": "https://helm.elastic.co",
	"gomods":  "https://athens.blob.core.windows.net/charts",
	"harbor":  "https://helm.goharbor.io",
}

Functions

func FetchUpstream

func FetchUpstream(upstreamURI string, fetchOptions *types.FetchOptions) (*types.Upstream, error)

func GetApplicationMetadata

func GetApplicationMetadata(upstream *url.URL) ([]byte, error)

GetApplicationMetadata will return any available application yaml from the upstream. If there is no application.yaml, it will return a placeholder one

func LoadApplication added in v1.13.0

func LoadApplication(upstreamDir string) (*kotsv1beta1.Application, error)

func LoadIdentity

func LoadIdentity(upstreamDir string) (*kotsv1beta1.Identity, error)

func LoadIdentityConfig

func LoadIdentityConfig(upstreamDir string) (*kotsv1beta1.IdentityConfig, error)

func LoadInstallation added in v1.12.2

func LoadInstallation(upstreamDir string) (*kotsv1beta1.Installation, error)

func MustMarshalLicense

func MustMarshalLicense(license *kotsv1beta1.License) []byte

func ProcessUpstreamImages

func ProcessUpstreamImages(u *types.Upstream, options ProcessUpstreamImagesOptions) ([]kustomizetypes.Image, error)

func SaveIdentityConfig

func SaveIdentityConfig(identityConfig *kotsv1beta1.IdentityConfig, upstreamDir string) error

func SaveInstallation

func SaveInstallation(installation *kotsv1beta1.Installation, upstreamDir string) error

func WriteUpstream

func WriteUpstream(u *types.Upstream, options types.WriteOptions) error

Types

type App

type App struct {
	Name string
}

type ChannelRelease

type ChannelRelease struct {
	ChannelSequence int    `json:"channelSequence"`
	ReleaseSequence int    `json:"releaseSequence"`
	VersionLabel    string `json:"versionLabel"`
}

type ProcessUpstreamImagesOptions

type ProcessUpstreamImagesOptions struct {
	RootDir             string
	ImagesDir           string
	CreateAppDir        bool
	SkipImagePush       bool
	KnownImages         []kustomizetypes.Image
	Log                 *logger.CLILogger
	ReplicatedRegistry  registry.RegistryOptions
	ReportWriter        io.Writer
	DestinationRegistry registry.RegistryOptions
}

type ProgressImage

type ProgressImage struct {
	// image name and tag, "nginx:latest"
	DisplayName string `json:"displayName"`
	// image upload status: queued, uploading, uploaded, failed
	Status string `json:"status"`
	// error string set when status is failed
	Error string `json:"error"`
	// amount currently uploaded (currently number of layers)
	Current int64 `json:"current"`
	// total amount that needs to be uploaded (currently number of layers)
	Total int64 `json:"total"`
	// time when image started uploading
	StartTime time.Time `json:"startTime"`
	// time when image finished uploading
	EndTime time.Time `json:"endTime"`
}

type ProgressReport

type ProgressReport struct {
	// set to "progressReport"
	Type string `json:"type"`
	// the same progress text that used to be sent in unstructured message
	CompatibilityMessage string `json:"compatibilityMessage"`
	// all images found in archive
	Images []ProgressImage `json:"images"`
}

type Release

type Release struct {
	UpdateCursor ReplicatedCursor
	VersionLabel string
	ReleaseNotes string
	ReleasedAt   *time.Time
	Manifests    map[string][]byte
}

type ReplicatedCursor

type ReplicatedCursor struct {
	ChannelID   string
	ChannelName string
	Cursor      string
}

func (ReplicatedCursor) Equal

func (this ReplicatedCursor) Equal(other ReplicatedCursor) bool

type ReplicatedUpstream

type ReplicatedUpstream struct {
	Channel      *string
	AppSlug      string
	VersionLabel *string
	Sequence     *int
}

type Update added in v1.2.0

type Update struct {
	Cursor       string `json:"cursor"`
	VersionLabel string `json:"versionLabel"`
}

func GetUpdatesUpstream

func GetUpdatesUpstream(upstreamURI string, fetchOptions *types.FetchOptions) ([]Update, error)

type UpstreamSettings

type UpstreamSettings struct {
	SharedPassword       string
	SharedPasswordBcrypt string
	S3AccessKey          string
	S3SecretKey          string
	JWT                  string
	PostgresPassword     string
	APIEncryptionKey     string
	HTTPProxyEnvValue    string
	HTTPSProxyEnvValue   string
	NoProxyEnvValue      string

	AutoCreateClusterToken string
}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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