gcp

package
v0.12.67 Latest Latest
Warning

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

Go to latest
Published: Oct 10, 2026 License: MIT Imports: 39 Imported by: 1 module, 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 (
	PreflightCheckEnabledServices           = PreflightCheck("[User] Enabled Services")
	PreflightCheckServiceAccountPermissions = PreflightCheck("[User] Test Permissions")
)

Variables

This section is empty.

Functions

func ClusterManagerClient

func ClusterManagerClient() (*container.ClusterManagerClient, error)

func IsProjectExists

func IsProjectExists(id string) (bool, error)

func LoggedInUserInfo

func LoggedInUserInfo() (string, string, error)

func ManagedZones

func ManagedZones(projectID string) ([]string, error)

func Projects

func Projects() ([]string, error)

func Regions

func Regions(projectID string) []string

func ServiceUsageClient

func ServiceUsageClient() (*serviceusage.Client, error)

func StorageClient

func StorageClient() (*storage.Client, error)

Types

type BucketLocation

type BucketLocation string
const (
	BucketLocationUS   BucketLocation = "US"
	BucketLocationEU   BucketLocation = "EU"
	BucketLocationASIA BucketLocation = "ASIA"
)

type InputProvider

type InputProvider interface {
	Cluster() string
	Project() string
	Region() string
}

InputProvider partially implements the Provider interface. It only contains methods where values need to be read from the user. This is to allow easily swapping out the survey library.

func NewReadonlyInputProvider

func NewReadonlyInputProvider(cluster, project, region string) InputProvider

func NewSurvey

func NewSurvey(defaultCluster string) (InputProvider, error)

type Option

type Option func(*Provider) error

func WithConfig

func WithConfig(c config.Config, defaultCluster string, cloudEnabled, dryRun bool) Option

func WithManifest

func WithManifest(m *manifest.ProjectManifest) Option

type PreflightCheck

type PreflightCheck string

type Provider

type Provider struct {
	// InputProvider partially implements the Provider interface.
	InputProvider
	// contains filtered or unexported fields
}

func NewProvider

func NewProvider(options ...Option) (*Provider, error)

func (*Provider) Bucket

func (in *Provider) Bucket() string

func (*Provider) Context

func (in *Provider) Context() map[string]interface{}

func (*Provider) CreateBucket

func (in *Provider) CreateBucket() error

func (*Provider) Flush

func (in *Provider) Flush() error

func (*Provider) KubeConfig

func (in *Provider) KubeConfig() error

func (*Provider) KubeContext

func (in *Provider) KubeContext() string

func (*Provider) Name

func (in *Provider) Name() string

func (*Provider) Permissions

func (in *Provider) Permissions() (permissions.Checker, error)

func (*Provider) Preflights

func (in *Provider) Preflights() []*preflights.Preflight

Jump to

Keyboard shortcuts

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