aws.codebuild.Webhook
Explore with Pulumi AI
Manages a CodeBuild webhook, which is an endpoint accepted by the CodeBuild service to trigger builds from source code repositories. Depending on the source type of the CodeBuild project, the CodeBuild service may also automatically create and delete the actual repository webhook as well.
Example Usage
Bitbucket and GitHub
When working with Bitbucket and GitHub source CodeBuild webhooks, the CodeBuild service will automatically create (on aws.codebuild.Webhook
resource creation) and delete (on aws.codebuild.Webhook
resource deletion) the Bitbucket/GitHub repository webhook using its granted OAuth permissions. This behavior cannot be controlled by this provider.
Note: The AWS account that this provider uses to create this resource must have authorized CodeBuild to access Bitbucket/GitHub’s OAuth API in each applicable region. This is a manual step that must be done before creating webhooks with this resource. If OAuth is not configured, AWS will return an error similar to
ResourceNotFoundException: Could not find access token for server type github
. More information can be found in the CodeBuild User Guide for Bitbucket and GitHub.
Note: Further managing the automatically created Bitbucket/GitHub webhook with the
bitbucket_hook
/github_repository_webhook
resource is only possible with importing that resource after creation of theaws.codebuild.Webhook
resource. The CodeBuild API does not ever provide thesecret
attribute for theaws.codebuild.Webhook
resource in this scenario.
import * as pulumi from "@pulumi/pulumi";
import * as aws from "@pulumi/aws";
const example = new aws.codebuild.Webhook("example", {
projectName: exampleAwsCodebuildProject.name,
buildType: "BUILD",
filterGroups: [{
filters: [
{
type: "EVENT",
pattern: "PUSH",
},
{
type: "BASE_REF",
pattern: "master",
},
],
}],
});
import pulumi
import pulumi_aws as aws
example = aws.codebuild.Webhook("example",
project_name=example_aws_codebuild_project["name"],
build_type="BUILD",
filter_groups=[{
"filters": [
{
"type": "EVENT",
"pattern": "PUSH",
},
{
"type": "BASE_REF",
"pattern": "master",
},
],
}])
package main
import (
"github.com/pulumi/pulumi-aws/sdk/v6/go/aws/codebuild"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := codebuild.NewWebhook(ctx, "example", &codebuild.WebhookArgs{
ProjectName: pulumi.Any(exampleAwsCodebuildProject.Name),
BuildType: pulumi.String("BUILD"),
FilterGroups: codebuild.WebhookFilterGroupArray{
&codebuild.WebhookFilterGroupArgs{
Filters: codebuild.WebhookFilterGroupFilterArray{
&codebuild.WebhookFilterGroupFilterArgs{
Type: pulumi.String("EVENT"),
Pattern: pulumi.String("PUSH"),
},
&codebuild.WebhookFilterGroupFilterArgs{
Type: pulumi.String("BASE_REF"),
Pattern: pulumi.String("master"),
},
},
},
},
})
if err != nil {
return err
}
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Aws = Pulumi.Aws;
return await Deployment.RunAsync(() =>
{
var example = new Aws.CodeBuild.Webhook("example", new()
{
ProjectName = exampleAwsCodebuildProject.Name,
BuildType = "BUILD",
FilterGroups = new[]
{
new Aws.CodeBuild.Inputs.WebhookFilterGroupArgs
{
Filters = new[]
{
new Aws.CodeBuild.Inputs.WebhookFilterGroupFilterArgs
{
Type = "EVENT",
Pattern = "PUSH",
},
new Aws.CodeBuild.Inputs.WebhookFilterGroupFilterArgs
{
Type = "BASE_REF",
Pattern = "master",
},
},
},
},
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.aws.codebuild.Webhook;
import com.pulumi.aws.codebuild.WebhookArgs;
import com.pulumi.aws.codebuild.inputs.WebhookFilterGroupArgs;
import java.util.List;
import java.util.ArrayList;
import java.util.Map;
import java.io.File;
import java.nio.file.Files;
import java.nio.file.Paths;
public class App {
public static void main(String[] args) {
Pulumi.run(App::stack);
}
public static void stack(Context ctx) {
var example = new Webhook("example", WebhookArgs.builder()
.projectName(exampleAwsCodebuildProject.name())
.buildType("BUILD")
.filterGroups(WebhookFilterGroupArgs.builder()
.filters(
WebhookFilterGroupFilterArgs.builder()
.type("EVENT")
.pattern("PUSH")
.build(),
WebhookFilterGroupFilterArgs.builder()
.type("BASE_REF")
.pattern("master")
.build())
.build())
.build());
}
}
resources:
example:
type: aws:codebuild:Webhook
properties:
projectName: ${exampleAwsCodebuildProject.name}
buildType: BUILD
filterGroups:
- filters:
- type: EVENT
pattern: PUSH
- type: BASE_REF
pattern: master
GitHub Enterprise
When working with GitHub Enterprise source CodeBuild webhooks, the GHE repository webhook must be separately managed (e.g., manually or with the github_repository_webhook
resource).
More information creating webhooks with GitHub Enterprise can be found in the CodeBuild User Guide.
Coming soon!
Coming soon!
Coming soon!
Coming soon!
Coming soon!
resources:
example:
type: aws:codebuild:Webhook
properties:
projectName: ${exampleAwsCodebuildProject.name}
exampleRepositoryWebhook:
type: github:RepositoryWebhook
name: example
properties:
active: true
events:
- push
name: example
repository: ${exampleGithubRepository.name}
configuration:
url: ${example.payloadUrl}
secret: ${example.secret}
contentType: json
insecureSsl: false
Create Webhook Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
new Webhook(name: string, args: WebhookArgs, opts?: CustomResourceOptions);
@overload
def Webhook(resource_name: str,
args: WebhookArgs,
opts: Optional[ResourceOptions] = None)
@overload
def Webhook(resource_name: str,
opts: Optional[ResourceOptions] = None,
project_name: Optional[str] = None,
branch_filter: Optional[str] = None,
build_type: Optional[str] = None,
filter_groups: Optional[Sequence[WebhookFilterGroupArgs]] = None,
scope_configuration: Optional[WebhookScopeConfigurationArgs] = None)
func NewWebhook(ctx *Context, name string, args WebhookArgs, opts ...ResourceOption) (*Webhook, error)
public Webhook(string name, WebhookArgs args, CustomResourceOptions? opts = null)
public Webhook(String name, WebhookArgs args)
public Webhook(String name, WebhookArgs args, CustomResourceOptions options)
type: aws:codebuild:Webhook
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.
Parameters
- name string
- The unique name of the resource.
- args WebhookArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- resource_name str
- The unique name of the resource.
- args WebhookArgs
- The arguments to resource properties.
- opts ResourceOptions
- Bag of options to control resource's behavior.
- ctx Context
- Context object for the current deployment.
- name string
- The unique name of the resource.
- args WebhookArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args WebhookArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args WebhookArgs
- The arguments to resource properties.
- options CustomResourceOptions
- Bag of options to control resource's behavior.
Constructor example
The following reference example uses placeholder values for all input properties.
var awsWebhookResource = new Aws.CodeBuild.Webhook("awsWebhookResource", new()
{
ProjectName = "string",
BranchFilter = "string",
BuildType = "string",
FilterGroups = new[]
{
new Aws.CodeBuild.Inputs.WebhookFilterGroupArgs
{
Filters = new[]
{
new Aws.CodeBuild.Inputs.WebhookFilterGroupFilterArgs
{
Pattern = "string",
Type = "string",
ExcludeMatchedPattern = false,
},
},
},
},
ScopeConfiguration = new Aws.CodeBuild.Inputs.WebhookScopeConfigurationArgs
{
Name = "string",
Scope = "string",
Domain = "string",
},
});
example, err := codebuild.NewWebhook(ctx, "awsWebhookResource", &codebuild.WebhookArgs{
ProjectName: pulumi.String("string"),
BranchFilter: pulumi.String("string"),
BuildType: pulumi.String("string"),
FilterGroups: codebuild.WebhookFilterGroupArray{
&codebuild.WebhookFilterGroupArgs{
Filters: codebuild.WebhookFilterGroupFilterArray{
&codebuild.WebhookFilterGroupFilterArgs{
Pattern: pulumi.String("string"),
Type: pulumi.String("string"),
ExcludeMatchedPattern: pulumi.Bool(false),
},
},
},
},
ScopeConfiguration: &codebuild.WebhookScopeConfigurationArgs{
Name: pulumi.String("string"),
Scope: pulumi.String("string"),
Domain: pulumi.String("string"),
},
})
var awsWebhookResource = new Webhook("awsWebhookResource", WebhookArgs.builder()
.projectName("string")
.branchFilter("string")
.buildType("string")
.filterGroups(WebhookFilterGroupArgs.builder()
.filters(WebhookFilterGroupFilterArgs.builder()
.pattern("string")
.type("string")
.excludeMatchedPattern(false)
.build())
.build())
.scopeConfiguration(WebhookScopeConfigurationArgs.builder()
.name("string")
.scope("string")
.domain("string")
.build())
.build());
aws_webhook_resource = aws.codebuild.Webhook("awsWebhookResource",
project_name="string",
branch_filter="string",
build_type="string",
filter_groups=[{
"filters": [{
"pattern": "string",
"type": "string",
"excludeMatchedPattern": False,
}],
}],
scope_configuration={
"name": "string",
"scope": "string",
"domain": "string",
})
const awsWebhookResource = new aws.codebuild.Webhook("awsWebhookResource", {
projectName: "string",
branchFilter: "string",
buildType: "string",
filterGroups: [{
filters: [{
pattern: "string",
type: "string",
excludeMatchedPattern: false,
}],
}],
scopeConfiguration: {
name: "string",
scope: "string",
domain: "string",
},
});
type: aws:codebuild:Webhook
properties:
branchFilter: string
buildType: string
filterGroups:
- filters:
- excludeMatchedPattern: false
pattern: string
type: string
projectName: string
scopeConfiguration:
domain: string
name: string
scope: string
Webhook Resource Properties
To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.
Inputs
The Webhook resource accepts the following input properties:
- Project
Name string - The name of the build project.
- Branch
Filter string - A regular expression used to determine which branches get built. Default is all branches are built. We recommend using
filter_group
overbranch_filter
. - Build
Type string - The type of build this webhook will trigger. Valid values for this parameter are:
BUILD
,BUILD_BATCH
. - Filter
Groups List<WebhookFilter Group> - Information about the webhook's trigger. Filter group blocks are documented below.
- Scope
Configuration WebhookScope Configuration - Scope configuration for global or organization webhooks. Scope configuration blocks are documented below.
- Project
Name string - The name of the build project.
- Branch
Filter string - A regular expression used to determine which branches get built. Default is all branches are built. We recommend using
filter_group
overbranch_filter
. - Build
Type string - The type of build this webhook will trigger. Valid values for this parameter are:
BUILD
,BUILD_BATCH
. - Filter
Groups []WebhookFilter Group Args - Information about the webhook's trigger. Filter group blocks are documented below.
- Scope
Configuration WebhookScope Configuration Args - Scope configuration for global or organization webhooks. Scope configuration blocks are documented below.
- project
Name String - The name of the build project.
- branch
Filter String - A regular expression used to determine which branches get built. Default is all branches are built. We recommend using
filter_group
overbranch_filter
. - build
Type String - The type of build this webhook will trigger. Valid values for this parameter are:
BUILD
,BUILD_BATCH
. - filter
Groups List<WebhookFilter Group> - Information about the webhook's trigger. Filter group blocks are documented below.
- scope
Configuration WebhookScope Configuration - Scope configuration for global or organization webhooks. Scope configuration blocks are documented below.
- project
Name string - The name of the build project.
- branch
Filter string - A regular expression used to determine which branches get built. Default is all branches are built. We recommend using
filter_group
overbranch_filter
. - build
Type string - The type of build this webhook will trigger. Valid values for this parameter are:
BUILD
,BUILD_BATCH
. - filter
Groups WebhookFilter Group[] - Information about the webhook's trigger. Filter group blocks are documented below.
- scope
Configuration WebhookScope Configuration - Scope configuration for global or organization webhooks. Scope configuration blocks are documented below.
- project_
name str - The name of the build project.
- branch_
filter str - A regular expression used to determine which branches get built. Default is all branches are built. We recommend using
filter_group
overbranch_filter
. - build_
type str - The type of build this webhook will trigger. Valid values for this parameter are:
BUILD
,BUILD_BATCH
. - filter_
groups Sequence[WebhookFilter Group Args] - Information about the webhook's trigger. Filter group blocks are documented below.
- scope_
configuration WebhookScope Configuration Args - Scope configuration for global or organization webhooks. Scope configuration blocks are documented below.
- project
Name String - The name of the build project.
- branch
Filter String - A regular expression used to determine which branches get built. Default is all branches are built. We recommend using
filter_group
overbranch_filter
. - build
Type String - The type of build this webhook will trigger. Valid values for this parameter are:
BUILD
,BUILD_BATCH
. - filter
Groups List<Property Map> - Information about the webhook's trigger. Filter group blocks are documented below.
- scope
Configuration Property Map - Scope configuration for global or organization webhooks. Scope configuration blocks are documented below.
Outputs
All input properties are implicitly available as output properties. Additionally, the Webhook resource produces the following output properties:
- Id string
- The provider-assigned unique ID for this managed resource.
- Payload
Url string - The CodeBuild endpoint where webhook events are sent.
- Secret string
- The secret token of the associated repository. Not returned by the CodeBuild API for all source types.
- Url string
- The URL to the webhook.
- Id string
- The provider-assigned unique ID for this managed resource.
- Payload
Url string - The CodeBuild endpoint where webhook events are sent.
- Secret string
- The secret token of the associated repository. Not returned by the CodeBuild API for all source types.
- Url string
- The URL to the webhook.
- id String
- The provider-assigned unique ID for this managed resource.
- payload
Url String - The CodeBuild endpoint where webhook events are sent.
- secret String
- The secret token of the associated repository. Not returned by the CodeBuild API for all source types.
- url String
- The URL to the webhook.
- id string
- The provider-assigned unique ID for this managed resource.
- payload
Url string - The CodeBuild endpoint where webhook events are sent.
- secret string
- The secret token of the associated repository. Not returned by the CodeBuild API for all source types.
- url string
- The URL to the webhook.
- id str
- The provider-assigned unique ID for this managed resource.
- payload_
url str - The CodeBuild endpoint where webhook events are sent.
- secret str
- The secret token of the associated repository. Not returned by the CodeBuild API for all source types.
- url str
- The URL to the webhook.
- id String
- The provider-assigned unique ID for this managed resource.
- payload
Url String - The CodeBuild endpoint where webhook events are sent.
- secret String
- The secret token of the associated repository. Not returned by the CodeBuild API for all source types.
- url String
- The URL to the webhook.
Look up Existing Webhook Resource
Get an existing Webhook resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.
public static get(name: string, id: Input<ID>, state?: WebhookState, opts?: CustomResourceOptions): Webhook
@staticmethod
def get(resource_name: str,
id: str,
opts: Optional[ResourceOptions] = None,
branch_filter: Optional[str] = None,
build_type: Optional[str] = None,
filter_groups: Optional[Sequence[WebhookFilterGroupArgs]] = None,
payload_url: Optional[str] = None,
project_name: Optional[str] = None,
scope_configuration: Optional[WebhookScopeConfigurationArgs] = None,
secret: Optional[str] = None,
url: Optional[str] = None) -> Webhook
func GetWebhook(ctx *Context, name string, id IDInput, state *WebhookState, opts ...ResourceOption) (*Webhook, error)
public static Webhook Get(string name, Input<string> id, WebhookState? state, CustomResourceOptions? opts = null)
public static Webhook get(String name, Output<String> id, WebhookState state, CustomResourceOptions options)
Resource lookup is not supported in YAML
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- resource_name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- Branch
Filter string - A regular expression used to determine which branches get built. Default is all branches are built. We recommend using
filter_group
overbranch_filter
. - Build
Type string - The type of build this webhook will trigger. Valid values for this parameter are:
BUILD
,BUILD_BATCH
. - Filter
Groups List<WebhookFilter Group> - Information about the webhook's trigger. Filter group blocks are documented below.
- Payload
Url string - The CodeBuild endpoint where webhook events are sent.
- Project
Name string - The name of the build project.
- Scope
Configuration WebhookScope Configuration - Scope configuration for global or organization webhooks. Scope configuration blocks are documented below.
- Secret string
- The secret token of the associated repository. Not returned by the CodeBuild API for all source types.
- Url string
- The URL to the webhook.
- Branch
Filter string - A regular expression used to determine which branches get built. Default is all branches are built. We recommend using
filter_group
overbranch_filter
. - Build
Type string - The type of build this webhook will trigger. Valid values for this parameter are:
BUILD
,BUILD_BATCH
. - Filter
Groups []WebhookFilter Group Args - Information about the webhook's trigger. Filter group blocks are documented below.
- Payload
Url string - The CodeBuild endpoint where webhook events are sent.
- Project
Name string - The name of the build project.
- Scope
Configuration WebhookScope Configuration Args - Scope configuration for global or organization webhooks. Scope configuration blocks are documented below.
- Secret string
- The secret token of the associated repository. Not returned by the CodeBuild API for all source types.
- Url string
- The URL to the webhook.
- branch
Filter String - A regular expression used to determine which branches get built. Default is all branches are built. We recommend using
filter_group
overbranch_filter
. - build
Type String - The type of build this webhook will trigger. Valid values for this parameter are:
BUILD
,BUILD_BATCH
. - filter
Groups List<WebhookFilter Group> - Information about the webhook's trigger. Filter group blocks are documented below.
- payload
Url String - The CodeBuild endpoint where webhook events are sent.
- project
Name String - The name of the build project.
- scope
Configuration WebhookScope Configuration - Scope configuration for global or organization webhooks. Scope configuration blocks are documented below.
- secret String
- The secret token of the associated repository. Not returned by the CodeBuild API for all source types.
- url String
- The URL to the webhook.
- branch
Filter string - A regular expression used to determine which branches get built. Default is all branches are built. We recommend using
filter_group
overbranch_filter
. - build
Type string - The type of build this webhook will trigger. Valid values for this parameter are:
BUILD
,BUILD_BATCH
. - filter
Groups WebhookFilter Group[] - Information about the webhook's trigger. Filter group blocks are documented below.
- payload
Url string - The CodeBuild endpoint where webhook events are sent.
- project
Name string - The name of the build project.
- scope
Configuration WebhookScope Configuration - Scope configuration for global or organization webhooks. Scope configuration blocks are documented below.
- secret string
- The secret token of the associated repository. Not returned by the CodeBuild API for all source types.
- url string
- The URL to the webhook.
- branch_
filter str - A regular expression used to determine which branches get built. Default is all branches are built. We recommend using
filter_group
overbranch_filter
. - build_
type str - The type of build this webhook will trigger. Valid values for this parameter are:
BUILD
,BUILD_BATCH
. - filter_
groups Sequence[WebhookFilter Group Args] - Information about the webhook's trigger. Filter group blocks are documented below.
- payload_
url str - The CodeBuild endpoint where webhook events are sent.
- project_
name str - The name of the build project.
- scope_
configuration WebhookScope Configuration Args - Scope configuration for global or organization webhooks. Scope configuration blocks are documented below.
- secret str
- The secret token of the associated repository. Not returned by the CodeBuild API for all source types.
- url str
- The URL to the webhook.
- branch
Filter String - A regular expression used to determine which branches get built. Default is all branches are built. We recommend using
filter_group
overbranch_filter
. - build
Type String - The type of build this webhook will trigger. Valid values for this parameter are:
BUILD
,BUILD_BATCH
. - filter
Groups List<Property Map> - Information about the webhook's trigger. Filter group blocks are documented below.
- payload
Url String - The CodeBuild endpoint where webhook events are sent.
- project
Name String - The name of the build project.
- scope
Configuration Property Map - Scope configuration for global or organization webhooks. Scope configuration blocks are documented below.
- secret String
- The secret token of the associated repository. Not returned by the CodeBuild API for all source types.
- url String
- The URL to the webhook.
Supporting Types
WebhookFilterGroup, WebhookFilterGroupArgs
- Filters
List<Webhook
Filter Group Filter> - A webhook filter for the group. Filter blocks are documented below.
- Filters
[]Webhook
Filter Group Filter - A webhook filter for the group. Filter blocks are documented below.
- filters
List<Webhook
Filter Group Filter> - A webhook filter for the group. Filter blocks are documented below.
- filters
Webhook
Filter Group Filter[] - A webhook filter for the group. Filter blocks are documented below.
- filters
Sequence[Webhook
Filter Group Filter] - A webhook filter for the group. Filter blocks are documented below.
- filters List<Property Map>
- A webhook filter for the group. Filter blocks are documented below.
WebhookFilterGroupFilter, WebhookFilterGroupFilterArgs
- Pattern string
- For a filter that uses
EVENT
type, a comma-separated string that specifies one event:PUSH
,PULL_REQUEST_CREATED
,PULL_REQUEST_UPDATED
,PULL_REQUEST_REOPENED
.PULL_REQUEST_MERGED
,WORKFLOW_JOB_QUEUED
works with GitHub & GitHub Enterprise only. For a filter that uses any of the other filter types, a regular expression. - Type string
- The webhook filter group's type. Valid values for this parameter are:
EVENT
,BASE_REF
,HEAD_REF
,ACTOR_ACCOUNT_ID
,FILE_PATH
,COMMIT_MESSAGE
,WORKFLOW_NAME
,TAG_NAME
,RELEASE_NAME
. At least one filter group must specifyEVENT
as its type. - Exclude
Matched boolPattern - If set to
true
, the specified filter does not trigger a build. Defaults tofalse
.
- Pattern string
- For a filter that uses
EVENT
type, a comma-separated string that specifies one event:PUSH
,PULL_REQUEST_CREATED
,PULL_REQUEST_UPDATED
,PULL_REQUEST_REOPENED
.PULL_REQUEST_MERGED
,WORKFLOW_JOB_QUEUED
works with GitHub & GitHub Enterprise only. For a filter that uses any of the other filter types, a regular expression. - Type string
- The webhook filter group's type. Valid values for this parameter are:
EVENT
,BASE_REF
,HEAD_REF
,ACTOR_ACCOUNT_ID
,FILE_PATH
,COMMIT_MESSAGE
,WORKFLOW_NAME
,TAG_NAME
,RELEASE_NAME
. At least one filter group must specifyEVENT
as its type. - Exclude
Matched boolPattern - If set to
true
, the specified filter does not trigger a build. Defaults tofalse
.
- pattern String
- For a filter that uses
EVENT
type, a comma-separated string that specifies one event:PUSH
,PULL_REQUEST_CREATED
,PULL_REQUEST_UPDATED
,PULL_REQUEST_REOPENED
.PULL_REQUEST_MERGED
,WORKFLOW_JOB_QUEUED
works with GitHub & GitHub Enterprise only. For a filter that uses any of the other filter types, a regular expression. - type String
- The webhook filter group's type. Valid values for this parameter are:
EVENT
,BASE_REF
,HEAD_REF
,ACTOR_ACCOUNT_ID
,FILE_PATH
,COMMIT_MESSAGE
,WORKFLOW_NAME
,TAG_NAME
,RELEASE_NAME
. At least one filter group must specifyEVENT
as its type. - exclude
Matched BooleanPattern - If set to
true
, the specified filter does not trigger a build. Defaults tofalse
.
- pattern string
- For a filter that uses
EVENT
type, a comma-separated string that specifies one event:PUSH
,PULL_REQUEST_CREATED
,PULL_REQUEST_UPDATED
,PULL_REQUEST_REOPENED
.PULL_REQUEST_MERGED
,WORKFLOW_JOB_QUEUED
works with GitHub & GitHub Enterprise only. For a filter that uses any of the other filter types, a regular expression. - type string
- The webhook filter group's type. Valid values for this parameter are:
EVENT
,BASE_REF
,HEAD_REF
,ACTOR_ACCOUNT_ID
,FILE_PATH
,COMMIT_MESSAGE
,WORKFLOW_NAME
,TAG_NAME
,RELEASE_NAME
. At least one filter group must specifyEVENT
as its type. - exclude
Matched booleanPattern - If set to
true
, the specified filter does not trigger a build. Defaults tofalse
.
- pattern str
- For a filter that uses
EVENT
type, a comma-separated string that specifies one event:PUSH
,PULL_REQUEST_CREATED
,PULL_REQUEST_UPDATED
,PULL_REQUEST_REOPENED
.PULL_REQUEST_MERGED
,WORKFLOW_JOB_QUEUED
works with GitHub & GitHub Enterprise only. For a filter that uses any of the other filter types, a regular expression. - type str
- The webhook filter group's type. Valid values for this parameter are:
EVENT
,BASE_REF
,HEAD_REF
,ACTOR_ACCOUNT_ID
,FILE_PATH
,COMMIT_MESSAGE
,WORKFLOW_NAME
,TAG_NAME
,RELEASE_NAME
. At least one filter group must specifyEVENT
as its type. - exclude_
matched_ boolpattern - If set to
true
, the specified filter does not trigger a build. Defaults tofalse
.
- pattern String
- For a filter that uses
EVENT
type, a comma-separated string that specifies one event:PUSH
,PULL_REQUEST_CREATED
,PULL_REQUEST_UPDATED
,PULL_REQUEST_REOPENED
.PULL_REQUEST_MERGED
,WORKFLOW_JOB_QUEUED
works with GitHub & GitHub Enterprise only. For a filter that uses any of the other filter types, a regular expression. - type String
- The webhook filter group's type. Valid values for this parameter are:
EVENT
,BASE_REF
,HEAD_REF
,ACTOR_ACCOUNT_ID
,FILE_PATH
,COMMIT_MESSAGE
,WORKFLOW_NAME
,TAG_NAME
,RELEASE_NAME
. At least one filter group must specifyEVENT
as its type. - exclude
Matched BooleanPattern - If set to
true
, the specified filter does not trigger a build. Defaults tofalse
.
WebhookScopeConfiguration, WebhookScopeConfigurationArgs
- Name string
- The name of either the enterprise or organization.
- Scope string
- The type of scope for a GitHub webhook. Valid values for this parameter are:
GITHUB_ORGANIZATION
,GITHUB_GLOBAL
. - Domain string
- The domain of the GitHub Enterprise organization. Required if your project's source type is GITHUB_ENTERPRISE.
- Name string
- The name of either the enterprise or organization.
- Scope string
- The type of scope for a GitHub webhook. Valid values for this parameter are:
GITHUB_ORGANIZATION
,GITHUB_GLOBAL
. - Domain string
- The domain of the GitHub Enterprise organization. Required if your project's source type is GITHUB_ENTERPRISE.
- name String
- The name of either the enterprise or organization.
- scope String
- The type of scope for a GitHub webhook. Valid values for this parameter are:
GITHUB_ORGANIZATION
,GITHUB_GLOBAL
. - domain String
- The domain of the GitHub Enterprise organization. Required if your project's source type is GITHUB_ENTERPRISE.
- name string
- The name of either the enterprise or organization.
- scope string
- The type of scope for a GitHub webhook. Valid values for this parameter are:
GITHUB_ORGANIZATION
,GITHUB_GLOBAL
. - domain string
- The domain of the GitHub Enterprise organization. Required if your project's source type is GITHUB_ENTERPRISE.
- name String
- The name of either the enterprise or organization.
- scope String
- The type of scope for a GitHub webhook. Valid values for this parameter are:
GITHUB_ORGANIZATION
,GITHUB_GLOBAL
. - domain String
- The domain of the GitHub Enterprise organization. Required if your project's source type is GITHUB_ENTERPRISE.
Import
Using pulumi import
, import CodeBuild Webhooks using the CodeBuild Project name. For example:
$ pulumi import aws:codebuild/webhook:Webhook example MyProjectName
To learn more about importing existing cloud resources, see Importing resources.
Package Details
- Repository
- AWS Classic pulumi/pulumi-aws
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
aws
Terraform Provider.