cloud

package
v0.3.0 Latest Latest
Warning

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

Go to latest
Published: Jun 22, 2021 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// UserAgent is the default user agent to use to make requests to the
	// Upbound Cloud API.
	UserAgent = "up-cli"
	// CookieName is the default cookie name used to identify a session token.
	CookieName = "SID"
)

Variables

This section is empty.

Functions

func BuildSDKConfig

func BuildSDKConfig(session string, endpoint *url.URL) (*up.Config, error)

BuildSDKConfig builds an Upbound SDK config suitable for usage with any service client.

func ExtractConfig

func ExtractConfig() (*config.Config, config.Source, error)

ExtractConfig performs extraction of configuration from the default source, which is the ~/.up/config.json file on the local filesystem.

Types

type Context

type Context struct {
	Profile  string
	ID       string
	Token    string
	Type     config.ProfileType
	Account  string
	Endpoint *url.URL
	Cfg      *config.Config
	CfgSrc   config.Source
}

Context includes common data that Upbound Cloud consumers may utilize.

Jump to

Keyboard shortcuts

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