gcloud

package
v0.3.75-rc101 Latest Latest
Warning

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

Go to latest
Published: Aug 13, 2024 License: Apache-2.0 Imports: 38 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewGCloud

func NewGCloud(ctx context.Context, cloudPrefix string, gCloud common.GCloud) model.CloudProvider

func NewSM

func NewSM(ctx context.Context, projectId string) (model.SSM, error)

Types

type ApiUsage

type ApiUsage struct {
	// contains filtered or unexported fields
}

func NewApiUsage

func NewApiUsage(ctx context.Context, projectId string) (*ApiUsage, error)

func (*ApiUsage) EnableService

func (a *ApiUsage) EnableService(service string) error

func (*ApiUsage) EnableServices

func (a *ApiUsage) EnableServices(services []string) error

type Builder

type Builder struct {
	// contains filtered or unexported fields
}

func NewBuilder

func NewBuilder(ctx context.Context, projectId, location, zone, serviceAccount string) (*Builder, error)

func (*Builder) CreateAgentProject

func (b *Builder) CreateAgentProject(projectName string, awsPrefix string, imageVersion string) error

func (*Builder) CreateProject

func (b *Builder) CreateProject(projectName string, bucket string, stepName string, step model.Step, imageVersion string, vpcConfig *model.VpcConfig) error

func (*Builder) DeleteProject

func (b *Builder) DeleteProject(projectName string, step model.Step) error

func (*Builder) GetJobManifest

func (b *Builder) GetJobManifest(projectName string, command model.ActionCommand, bucket string, stepName string, step model.Step, image string, templateMeta *runv1.ObjectMeta) runv1.Job

func (*Builder) GetProject

func (b *Builder) GetProject(projectName string) (*model.Project, error)

func (*Builder) UpdateAgentProject

func (b *Builder) UpdateAgentProject(projectName string, version string, cloudPrefix string) error

func (*Builder) UpdateProject

func (b *Builder) UpdateProject(projectName, bucket, stepName string, step model.Step, imageVersion string, vpcConfig *model.VpcConfig) error

type GStorage

type GStorage struct {
	// contains filtered or unexported fields
}

func NewStorage

func NewStorage(ctx context.Context, projectId string, location string, bucket string) (*GStorage, error)

func (*GStorage) CheckFolderExists

func (g *GStorage) CheckFolderExists(folder string) (bool, error)

func (*GStorage) CreateBucket

func (g *GStorage) CreateBucket() error

func (*GStorage) Delete

func (g *GStorage) Delete() error

func (*GStorage) DeleteFile

func (g *GStorage) DeleteFile(file string) error

func (*GStorage) GetFile

func (g *GStorage) GetFile(file string) ([]byte, error)

func (*GStorage) GetRepoMetadata

func (g *GStorage) GetRepoMetadata() (*model.RepositoryMetadata, error)

func (*GStorage) ListFolderFiles

func (g *GStorage) ListFolderFiles(folder string) ([]string, error)

func (*GStorage) PutFile

func (g *GStorage) PutFile(file string, content []byte) error

type IAM

type IAM struct {
	// contains filtered or unexported fields
}

func NewIAM

func NewIAM(ctx context.Context, projectId string) (*IAM, error)

func (*IAM) AddRolesToProject

func (iam *IAM) AddRolesToProject(serviceAccountName string, roles []string) error

func (*IAM) AddRolesToServiceAccount

func (iam *IAM) AddRolesToServiceAccount(serviceAccountName string, roles []string) error

func (*IAM) DeleteServiceAccount

func (iam *IAM) DeleteServiceAccount(name string) error

func (*IAM) GetOrCreateServiceAccount

func (iam *IAM) GetOrCreateServiceAccount(name, displayName string) (*iamv1.ServiceAccount, bool, error)

func (*IAM) GetServiceAccount

func (iam *IAM) GetServiceAccount(serviceAccountName string) (*iamv1.ServiceAccount, error)

type Logging

type Logging struct {
	// contains filtered or unexported fields
}

func NewLogging

func NewLogging(ctx context.Context, projectId string) (*Logging, error)

func (*Logging) GetJobExecutionLogs

func (l *Logging) GetJobExecutionLogs(job string, execution string, location string) *logging.LogEntryIterator

type Pipeline

type Pipeline struct {
	// contains filtered or unexported fields
}

func NewPipeline

func NewPipeline(ctx context.Context, projectId string, location string, prefix string, serviceAccount string, storage *GStorage, builder *Builder, logging *Logging) (*Pipeline, error)

func (*Pipeline) CreateAgentPipeline

func (p *Pipeline) CreateAgentPipeline(_ string, pipelineName string, _ string, _ string) error

func (*Pipeline) CreatePipeline

func (p *Pipeline) CreatePipeline(projectName, stepName string, step model.Step, bucket string) (*string, error)

func (*Pipeline) DeletePipeline

func (p *Pipeline) DeletePipeline(projectName string) error

func (*Pipeline) StartAgentExecution

func (p *Pipeline) StartAgentExecution(pipelineName string) error

func (*Pipeline) StartDestroyExecution

func (p *Pipeline) StartDestroyExecution(projectName string) error

func (*Pipeline) StartPipelineExecution

func (p *Pipeline) StartPipelineExecution(pipelineName string, stepName string, step model.Step, bucket string) (*string, error)

func (*Pipeline) UpdatePipeline

func (p *Pipeline) UpdatePipeline(projectName string, stepName string, step model.Step, bucket string) error

func (*Pipeline) WaitPipelineExecution

func (p *Pipeline) WaitPipelineExecution(pipelineName string, projectName string, releaseId *string, autoApprove bool, stepType model.StepType) error

type Resources

type Resources struct {
	model.CloudResources
}

func (Resources) GetBackendConfigVars

func (r Resources) GetBackendConfigVars(key string) map[string]string

Jump to

Keyboard shortcuts

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