client

package
v1.1.4 Latest Latest
Warning

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

Go to latest
Published: Nov 25, 2026 License: Apache-2.0 Imports: 17 Imported by: 0 modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

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

Variables

View Source
var (
	DefaultAPIEndpoint, _ = url.Parse("https://api.upbound.io")
)

Functions

This section is empty.

Types

type CLIConfig

type CLIConfig struct {
	Upbound Upbound `json:"upbound"`
}

CLIConfig is format for the up configuration file.

type GetProviderConfigSpecFn added in v1.0.0

type GetProviderConfigSpecFn func(ctx context.Context, kube client.Client) (*pcv1alpha1common.ProviderConfigSpec, error)

GetProviderConfigSpecFn returns the referenced ProviderConfig's spec from a legacy cluster-scoped MR or from a namespaced MR.

type Profile

type Profile struct {
	// ID is either a username, email, or token.
	ID string `json:"id"`

	// Type is the type of the profile.
	Type ProfileType `json:"type"`

	// Session is a session token used to authenticate to Upbound.
	Session string `json:"session,omitempty"`

	// Account is the default account to use when this profile is selected.
	Account string `json:"account,omitempty"`

	// BaseConfig represent persisted settings for this profile.
	// For example:
	// * flags
	// * environment variables
	BaseConfig map[string]string `json:"base,omitempty"`
}

A Profile is a set of credentials

func NewConfig

func NewConfig(ctx context.Context, kube client.Client, getPCFn GetProviderConfigSpecFn) (*up.Config, Profile, error)

type ProfileType

type ProfileType string

ProfileType is a type of Upbound profile.

const (
	UserProfileType  ProfileType = "user"
	TokenProfileType ProfileType = "token"
)

Types of profiles.

type Upbound

type Upbound struct {
	// Default indicates the default profile.
	Default string `json:"default"`

	// Profiles contain sets of credentials for communicating with Upbound. Key
	// is name of the profile.
	Profiles map[string]Profile `json:"profiles,omitempty"`
}

Upbound contains configuration information for Upbound.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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