Documentation
¶
Index ¶
- Constants
- func ListBranchResources(ctx context.Context, client Client, repositoryName string) ([]core.IntegrationResource, error)
- func ListBuildResources(ctx context.Context, client Client, projectID string) ([]core.IntegrationResource, error)
- func ListConnectionResources(ctx context.Context, client Client, projectID string, location string) ([]core.IntegrationResource, error)
- func ListLocationResources(ctx context.Context, client Client, projectID string) ([]core.IntegrationResource, error)
- func ListRepositoryResources(ctx context.Context, client Client, connectionName string) ([]core.IntegrationResource, error)
- func ListTagResources(ctx context.Context, client Client, repositoryName string) ([]core.IntegrationResource, error)
- func ListTriggerResources(ctx context.Context, client Client, projectID string) ([]core.IntegrationResource, error)
- func SetClientFactory(...)
- type Client
- type CreateBuild
- func (c *CreateBuild) Cancel(ctx core.ExecutionContext) error
- func (c *CreateBuild) Cleanup(_ core.SetupContext) error
- func (c *CreateBuild) Color() string
- func (c *CreateBuild) Configuration() []configuration.Field
- func (c *CreateBuild) Description() string
- func (c *CreateBuild) Documentation() string
- func (c *CreateBuild) ExampleOutput() map[string]any
- func (c *CreateBuild) Execute(ctx core.ExecutionContext) error
- func (c *CreateBuild) HandleHook(ctx core.ActionHookContext) error
- func (c *CreateBuild) HandleWebhook(_ core.WebhookRequestContext) (int, *core.WebhookResponseBody, error)
- func (c *CreateBuild) Hooks() []core.Hook
- func (c *CreateBuild) Icon() string
- func (c *CreateBuild) Label() string
- func (c *CreateBuild) Name() string
- func (c *CreateBuild) OnIntegrationMessage(ctx core.IntegrationMessageContext) error
- func (c *CreateBuild) OutputChannels(_ any) []core.OutputChannel
- func (c *CreateBuild) ProcessQueueItem(ctx core.ProcessQueueContext) (*uuid.UUID, error)
- func (c *CreateBuild) Setup(ctx core.SetupContext) error
- type CreateBuildConfiguration
- type CreateBuildExecutionMetadata
- type CreateBuildNodeMetadata
- type GetBuild
- func (c *GetBuild) Cancel(_ core.ExecutionContext) error
- func (c *GetBuild) Cleanup(_ core.SetupContext) error
- func (c *GetBuild) Color() string
- func (c *GetBuild) Configuration() []configuration.Field
- func (c *GetBuild) Description() string
- func (c *GetBuild) Documentation() string
- func (c *GetBuild) ExampleOutput() map[string]any
- func (c *GetBuild) Execute(ctx core.ExecutionContext) error
- func (c *GetBuild) HandleHook(ctx core.ActionHookContext) error
- func (c *GetBuild) HandleWebhook(_ core.WebhookRequestContext) (int, *core.WebhookResponseBody, error)
- func (c *GetBuild) Hooks() []core.Hook
- func (c *GetBuild) Icon() string
- func (c *GetBuild) Label() string
- func (c *GetBuild) Name() string
- func (c *GetBuild) OutputChannels(_ any) []core.OutputChannel
- func (c *GetBuild) ProcessQueueItem(ctx core.ProcessQueueContext) (*uuid.UUID, error)
- func (c *GetBuild) Setup(ctx core.SetupContext) error
- type GetBuildConfiguration
- type OnBuildComplete
- func (t *OnBuildComplete) Cleanup(ctx core.TriggerContext) error
- func (t *OnBuildComplete) Color() string
- func (t *OnBuildComplete) Configuration() []configuration.Field
- func (t *OnBuildComplete) Description() string
- func (t *OnBuildComplete) Documentation() string
- func (t *OnBuildComplete) ExampleData() map[string]any
- func (t *OnBuildComplete) HandleHook(ctx core.TriggerHookContext) (map[string]any, error)
- func (t *OnBuildComplete) HandleWebhook(ctx core.WebhookRequestContext) (int, *core.WebhookResponseBody, error)
- func (t *OnBuildComplete) Hooks() []core.Hook
- func (t *OnBuildComplete) Icon() string
- func (t *OnBuildComplete) Label() string
- func (t *OnBuildComplete) Name() string
- func (t *OnBuildComplete) OnIntegrationMessage(ctx core.IntegrationMessageContext) error
- func (t *OnBuildComplete) Setup(ctx core.TriggerContext) error
- type OnBuildCompleteConfiguration
- type OnBuildCompleteMetadata
- type RunTrigger
- func (c *RunTrigger) Cancel(ctx core.ExecutionContext) error
- func (c *RunTrigger) Cleanup(_ core.SetupContext) error
- func (c *RunTrigger) Color() string
- func (c *RunTrigger) Configuration() []configuration.Field
- func (c *RunTrigger) Description() string
- func (c *RunTrigger) Documentation() string
- func (c *RunTrigger) ExampleOutput() map[string]any
- func (c *RunTrigger) Execute(ctx core.ExecutionContext) error
- func (c *RunTrigger) HandleHook(ctx core.ActionHookContext) error
- func (c *RunTrigger) HandleWebhook(_ core.WebhookRequestContext) (int, *core.WebhookResponseBody, error)
- func (c *RunTrigger) Hooks() []core.Hook
- func (c *RunTrigger) Icon() string
- func (c *RunTrigger) Label() string
- func (c *RunTrigger) Name() string
- func (c *RunTrigger) OnIntegrationMessage(ctx core.IntegrationMessageContext) error
- func (c *RunTrigger) OutputChannels(_ any) []core.OutputChannel
- func (c *RunTrigger) ProcessQueueItem(ctx core.ProcessQueueContext) (*uuid.UUID, error)
- func (c *RunTrigger) Setup(ctx core.SetupContext) error
- type RunTriggerConfiguration
- type RunTriggerNodeMetadata
Constants ¶
View Source
const ( ResourceTypeTrigger = "cloudbuild.trigger" ResourceTypeBuild = "cloudbuild.build" ResourceTypeLocation = "cloudbuild.location" ResourceTypeConnection = "cloudbuild.connection" ResourceTypeRepository = "cloudbuild.repository" ResourceTypeBranch = "cloudbuild.branch" ResourceTypeTag = "cloudbuild.tag" )
View Source
const ( EmittedEventType = "gcp.cloudbuild.build" SubscriptionType = "cloudbuild" )
Variables ¶
This section is empty.
Functions ¶
func ListBranchResources ¶
func ListBuildResources ¶
func ListConnectionResources ¶
func ListLocationResources ¶
func ListRepositoryResources ¶
func ListTagResources ¶
func ListTriggerResources ¶
func SetClientFactory ¶
func SetClientFactory(fn func(httpCtx core.HTTPContext, integration core.IntegrationContext) (Client, error))
Types ¶
type Client ¶
type Client interface {
GetURL(ctx context.Context, fullURL string) ([]byte, error)
PostURL(ctx context.Context, fullURL string, body any) ([]byte, error)
ProjectID() string
}
Client is the interface used by Cloud Build components to call the API.
type CreateBuild ¶
type CreateBuild struct{}
func (*CreateBuild) Cancel ¶
func (c *CreateBuild) Cancel(ctx core.ExecutionContext) error
func (*CreateBuild) Cleanup ¶
func (c *CreateBuild) Cleanup(_ core.SetupContext) error
func (*CreateBuild) Color ¶
func (c *CreateBuild) Color() string
func (*CreateBuild) Configuration ¶
func (c *CreateBuild) Configuration() []configuration.Field
func (*CreateBuild) Description ¶
func (c *CreateBuild) Description() string
func (*CreateBuild) Documentation ¶
func (c *CreateBuild) Documentation() string
func (*CreateBuild) ExampleOutput ¶
func (c *CreateBuild) ExampleOutput() map[string]any
func (*CreateBuild) Execute ¶
func (c *CreateBuild) Execute(ctx core.ExecutionContext) error
func (*CreateBuild) HandleHook ¶ added in v0.18.0
func (c *CreateBuild) HandleHook(ctx core.ActionHookContext) error
func (*CreateBuild) HandleWebhook ¶
func (c *CreateBuild) HandleWebhook(_ core.WebhookRequestContext) (int, *core.WebhookResponseBody, error)
func (*CreateBuild) Hooks ¶ added in v0.18.0
func (c *CreateBuild) Hooks() []core.Hook
func (*CreateBuild) Icon ¶
func (c *CreateBuild) Icon() string
func (*CreateBuild) Label ¶
func (c *CreateBuild) Label() string
func (*CreateBuild) Name ¶
func (c *CreateBuild) Name() string
func (*CreateBuild) OnIntegrationMessage ¶
func (c *CreateBuild) OnIntegrationMessage(ctx core.IntegrationMessageContext) error
func (*CreateBuild) OutputChannels ¶
func (c *CreateBuild) OutputChannels(_ any) []core.OutputChannel
func (*CreateBuild) ProcessQueueItem ¶
func (c *CreateBuild) ProcessQueueItem(ctx core.ProcessQueueContext) (*uuid.UUID, error)
func (*CreateBuild) Setup ¶
func (c *CreateBuild) Setup(ctx core.SetupContext) error
type CreateBuildConfiguration ¶
type CreateBuildConfiguration struct {
ProjectID string `json:"projectId" mapstructure:"projectId"`
Source string `json:"source" mapstructure:"source"`
UseConnectedRepository bool `json:"useConnectedRepository" mapstructure:"useConnectedRepository"`
ConnectionLocation string `json:"connectionLocation" mapstructure:"connectionLocation"`
Connection string `json:"connection" mapstructure:"connection"`
ConnectedRepository string `json:"connectedRepository" mapstructure:"connectedRepository"`
ConnectedRevisionType string `json:"connectedRevisionType" mapstructure:"connectedRevisionType"`
ConnectedBranch string `json:"connectedBranch" mapstructure:"connectedBranch"`
ConnectedTag string `json:"connectedTag" mapstructure:"connectedTag"`
ConnectedCommitSHA string `json:"connectedCommitSha" mapstructure:"connectedCommitSha"`
RepoName string `json:"repoName" mapstructure:"repoName"`
BranchName string `json:"branchName" mapstructure:"branchName"`
TagName string `json:"tagName" mapstructure:"tagName"`
CommitSHA string `json:"commitSha" mapstructure:"commitSha"`
Steps string `json:"steps" mapstructure:"steps"`
Images []string `json:"images" mapstructure:"images"`
Substitutions string `json:"substitutions" mapstructure:"substitutions"`
Timeout string `json:"timeout" mapstructure:"timeout"`
}
type CreateBuildNodeMetadata ¶
type CreateBuildNodeMetadata struct {
SubscriptionID string `json:"subscriptionId,omitempty" mapstructure:"subscriptionId,omitempty"`
}
type GetBuild ¶
type GetBuild struct{}
func (*GetBuild) Configuration ¶
func (c *GetBuild) Configuration() []configuration.Field
func (*GetBuild) Description ¶
func (*GetBuild) Documentation ¶
func (*GetBuild) ExampleOutput ¶
func (*GetBuild) HandleHook ¶ added in v0.18.0
func (c *GetBuild) HandleHook(ctx core.ActionHookContext) error
func (*GetBuild) HandleWebhook ¶
func (c *GetBuild) HandleWebhook(_ core.WebhookRequestContext) (int, *core.WebhookResponseBody, error)
func (*GetBuild) OutputChannels ¶
func (c *GetBuild) OutputChannels(_ any) []core.OutputChannel
func (*GetBuild) ProcessQueueItem ¶
type GetBuildConfiguration ¶
type OnBuildComplete ¶
type OnBuildComplete struct{}
func (*OnBuildComplete) Cleanup ¶
func (t *OnBuildComplete) Cleanup(ctx core.TriggerContext) error
func (*OnBuildComplete) Color ¶
func (t *OnBuildComplete) Color() string
func (*OnBuildComplete) Configuration ¶
func (t *OnBuildComplete) Configuration() []configuration.Field
func (*OnBuildComplete) Description ¶
func (t *OnBuildComplete) Description() string
func (*OnBuildComplete) Documentation ¶
func (t *OnBuildComplete) Documentation() string
func (*OnBuildComplete) ExampleData ¶
func (t *OnBuildComplete) ExampleData() map[string]any
func (*OnBuildComplete) HandleHook ¶ added in v0.18.0
func (t *OnBuildComplete) HandleHook(ctx core.TriggerHookContext) (map[string]any, error)
func (*OnBuildComplete) HandleWebhook ¶
func (t *OnBuildComplete) HandleWebhook(ctx core.WebhookRequestContext) (int, *core.WebhookResponseBody, error)
func (*OnBuildComplete) Hooks ¶ added in v0.18.0
func (t *OnBuildComplete) Hooks() []core.Hook
func (*OnBuildComplete) Icon ¶
func (t *OnBuildComplete) Icon() string
func (*OnBuildComplete) Label ¶
func (t *OnBuildComplete) Label() string
func (*OnBuildComplete) Name ¶
func (t *OnBuildComplete) Name() string
func (*OnBuildComplete) OnIntegrationMessage ¶
func (t *OnBuildComplete) OnIntegrationMessage(ctx core.IntegrationMessageContext) error
func (*OnBuildComplete) Setup ¶
func (t *OnBuildComplete) Setup(ctx core.TriggerContext) error
type OnBuildCompleteMetadata ¶
type OnBuildCompleteMetadata struct {
SubscriptionID string `json:"subscriptionId" mapstructure:"subscriptionId"`
}
type RunTrigger ¶
type RunTrigger struct{}
func (*RunTrigger) Cancel ¶
func (c *RunTrigger) Cancel(ctx core.ExecutionContext) error
func (*RunTrigger) Cleanup ¶
func (c *RunTrigger) Cleanup(_ core.SetupContext) error
func (*RunTrigger) Color ¶
func (c *RunTrigger) Color() string
func (*RunTrigger) Configuration ¶
func (c *RunTrigger) Configuration() []configuration.Field
func (*RunTrigger) Description ¶
func (c *RunTrigger) Description() string
func (*RunTrigger) Documentation ¶
func (c *RunTrigger) Documentation() string
func (*RunTrigger) ExampleOutput ¶
func (c *RunTrigger) ExampleOutput() map[string]any
func (*RunTrigger) Execute ¶
func (c *RunTrigger) Execute(ctx core.ExecutionContext) error
func (*RunTrigger) HandleHook ¶ added in v0.18.0
func (c *RunTrigger) HandleHook(ctx core.ActionHookContext) error
func (*RunTrigger) HandleWebhook ¶
func (c *RunTrigger) HandleWebhook(_ core.WebhookRequestContext) (int, *core.WebhookResponseBody, error)
func (*RunTrigger) Hooks ¶ added in v0.18.0
func (c *RunTrigger) Hooks() []core.Hook
func (*RunTrigger) Icon ¶
func (c *RunTrigger) Icon() string
func (*RunTrigger) Label ¶
func (c *RunTrigger) Label() string
func (*RunTrigger) Name ¶
func (c *RunTrigger) Name() string
func (*RunTrigger) OnIntegrationMessage ¶
func (c *RunTrigger) OnIntegrationMessage(ctx core.IntegrationMessageContext) error
func (*RunTrigger) OutputChannels ¶
func (c *RunTrigger) OutputChannels(_ any) []core.OutputChannel
func (*RunTrigger) ProcessQueueItem ¶
func (c *RunTrigger) ProcessQueueItem(ctx core.ProcessQueueContext) (*uuid.UUID, error)
func (*RunTrigger) Setup ¶
func (c *RunTrigger) Setup(ctx core.SetupContext) error
type RunTriggerConfiguration ¶
type RunTriggerNodeMetadata ¶
Click to show internal directories.
Click to hide internal directories.