Harbor v3.10.11 published on Wednesday, Jun 19, 2024 by Pulumiverse
harbor.ProjectWebhook
Explore with Pulumi AI
Example Usage
resource "harbor_project" "main" {
name = "test-project"
}
resource "harbor_project_webhook" "main" {
name = "test_webhook"
address = "https://webhook.domain.com"
project_id = harbor_project.main.id
notify_type = "http"
events_types = [
"DELETE_ARTIFACT",
"PULL_ARTIFACT",
"PUSH_ARTIFACT",
"QUOTA_EXCEED",
"QUOTA_WARNING",
"REPLICATION",
"SCANNING_FAILED",
"SCANNING_COMPLETED",
"TAG_RETENTION"
]
}
Create ProjectWebhook Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
new ProjectWebhook(name: string, args: ProjectWebhookArgs, opts?: CustomResourceOptions);
@overload
def ProjectWebhook(resource_name: str,
args: ProjectWebhookArgs,
opts: Optional[ResourceOptions] = None)
@overload
def ProjectWebhook(resource_name: str,
opts: Optional[ResourceOptions] = None,
address: Optional[str] = None,
events_types: Optional[Sequence[str]] = None,
notify_type: Optional[str] = None,
project_id: Optional[str] = None,
auth_header: Optional[str] = None,
description: Optional[str] = None,
enabled: Optional[bool] = None,
name: Optional[str] = None,
skip_cert_verify: Optional[bool] = None)
func NewProjectWebhook(ctx *Context, name string, args ProjectWebhookArgs, opts ...ResourceOption) (*ProjectWebhook, error)
public ProjectWebhook(string name, ProjectWebhookArgs args, CustomResourceOptions? opts = null)
public ProjectWebhook(String name, ProjectWebhookArgs args)
public ProjectWebhook(String name, ProjectWebhookArgs args, CustomResourceOptions options)
type: harbor:ProjectWebhook
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 ProjectWebhookArgs
- 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 ProjectWebhookArgs
- 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 ProjectWebhookArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args ProjectWebhookArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args ProjectWebhookArgs
- 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 projectWebhookResource = new Harbor.ProjectWebhook("projectWebhookResource", new()
{
Address = "string",
EventsTypes = new[]
{
"string",
},
NotifyType = "string",
ProjectId = "string",
AuthHeader = "string",
Description = "string",
Enabled = false,
Name = "string",
SkipCertVerify = false,
});
example, err := harbor.NewProjectWebhook(ctx, "projectWebhookResource", &harbor.ProjectWebhookArgs{
Address: pulumi.String("string"),
EventsTypes: pulumi.StringArray{
pulumi.String("string"),
},
NotifyType: pulumi.String("string"),
ProjectId: pulumi.String("string"),
AuthHeader: pulumi.String("string"),
Description: pulumi.String("string"),
Enabled: pulumi.Bool(false),
Name: pulumi.String("string"),
SkipCertVerify: pulumi.Bool(false),
})
var projectWebhookResource = new ProjectWebhook("projectWebhookResource", ProjectWebhookArgs.builder()
.address("string")
.eventsTypes("string")
.notifyType("string")
.projectId("string")
.authHeader("string")
.description("string")
.enabled(false)
.name("string")
.skipCertVerify(false)
.build());
project_webhook_resource = harbor.ProjectWebhook("projectWebhookResource",
address="string",
events_types=["string"],
notify_type="string",
project_id="string",
auth_header="string",
description="string",
enabled=False,
name="string",
skip_cert_verify=False)
const projectWebhookResource = new harbor.ProjectWebhook("projectWebhookResource", {
address: "string",
eventsTypes: ["string"],
notifyType: "string",
projectId: "string",
authHeader: "string",
description: "string",
enabled: false,
name: "string",
skipCertVerify: false,
});
type: harbor:ProjectWebhook
properties:
address: string
authHeader: string
description: string
enabled: false
eventsTypes:
- string
name: string
notifyType: string
projectId: string
skipCertVerify: false
ProjectWebhook 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 ProjectWebhook resource accepts the following input properties:
- Address string
- The address of the webhook.
- Events
Types List<string> - The type events you want to subscript to can be
- Notify
Type string - The notification type either
http
orslack
. - Project
Id string - The project id of the harbor that webhook related to.
- Auth
Header string - Description string
- Enabled bool
- Name string
- The name of the webhook that will be created in harbor.
- Skip
Cert boolVerify
- Address string
- The address of the webhook.
- Events
Types []string - The type events you want to subscript to can be
- Notify
Type string - The notification type either
http
orslack
. - Project
Id string - The project id of the harbor that webhook related to.
- Auth
Header string - Description string
- Enabled bool
- Name string
- The name of the webhook that will be created in harbor.
- Skip
Cert boolVerify
- address String
- The address of the webhook.
- events
Types List<String> - The type events you want to subscript to can be
- notify
Type String - The notification type either
http
orslack
. - project
Id String - The project id of the harbor that webhook related to.
- auth
Header String - description String
- enabled Boolean
- name String
- The name of the webhook that will be created in harbor.
- skip
Cert BooleanVerify
- address string
- The address of the webhook.
- events
Types string[] - The type events you want to subscript to can be
- notify
Type string - The notification type either
http
orslack
. - project
Id string - The project id of the harbor that webhook related to.
- auth
Header string - description string
- enabled boolean
- name string
- The name of the webhook that will be created in harbor.
- skip
Cert booleanVerify
- address str
- The address of the webhook.
- events_
types Sequence[str] - The type events you want to subscript to can be
- notify_
type str - The notification type either
http
orslack
. - project_
id str - The project id of the harbor that webhook related to.
- auth_
header str - description str
- enabled bool
- name str
- The name of the webhook that will be created in harbor.
- skip_
cert_ boolverify
- address String
- The address of the webhook.
- events
Types List<String> - The type events you want to subscript to can be
- notify
Type String - The notification type either
http
orslack
. - project
Id String - The project id of the harbor that webhook related to.
- auth
Header String - description String
- enabled Boolean
- name String
- The name of the webhook that will be created in harbor.
- skip
Cert BooleanVerify
Outputs
All input properties are implicitly available as output properties. Additionally, the ProjectWebhook resource produces the following output properties:
- Id string
- The provider-assigned unique ID for this managed resource.
- Id string
- The provider-assigned unique ID for this managed resource.
- id String
- The provider-assigned unique ID for this managed resource.
- id string
- The provider-assigned unique ID for this managed resource.
- id str
- The provider-assigned unique ID for this managed resource.
- id String
- The provider-assigned unique ID for this managed resource.
Look up Existing ProjectWebhook Resource
Get an existing ProjectWebhook 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?: ProjectWebhookState, opts?: CustomResourceOptions): ProjectWebhook
@staticmethod
def get(resource_name: str,
id: str,
opts: Optional[ResourceOptions] = None,
address: Optional[str] = None,
auth_header: Optional[str] = None,
description: Optional[str] = None,
enabled: Optional[bool] = None,
events_types: Optional[Sequence[str]] = None,
name: Optional[str] = None,
notify_type: Optional[str] = None,
project_id: Optional[str] = None,
skip_cert_verify: Optional[bool] = None) -> ProjectWebhook
func GetProjectWebhook(ctx *Context, name string, id IDInput, state *ProjectWebhookState, opts ...ResourceOption) (*ProjectWebhook, error)
public static ProjectWebhook Get(string name, Input<string> id, ProjectWebhookState? state, CustomResourceOptions? opts = null)
public static ProjectWebhook get(String name, Output<String> id, ProjectWebhookState 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.
- Address string
- The address of the webhook.
- Auth
Header string - Description string
- Enabled bool
- Events
Types List<string> - The type events you want to subscript to can be
- Name string
- The name of the webhook that will be created in harbor.
- Notify
Type string - The notification type either
http
orslack
. - Project
Id string - The project id of the harbor that webhook related to.
- Skip
Cert boolVerify
- Address string
- The address of the webhook.
- Auth
Header string - Description string
- Enabled bool
- Events
Types []string - The type events you want to subscript to can be
- Name string
- The name of the webhook that will be created in harbor.
- Notify
Type string - The notification type either
http
orslack
. - Project
Id string - The project id of the harbor that webhook related to.
- Skip
Cert boolVerify
- address String
- The address of the webhook.
- auth
Header String - description String
- enabled Boolean
- events
Types List<String> - The type events you want to subscript to can be
- name String
- The name of the webhook that will be created in harbor.
- notify
Type String - The notification type either
http
orslack
. - project
Id String - The project id of the harbor that webhook related to.
- skip
Cert BooleanVerify
- address string
- The address of the webhook.
- auth
Header string - description string
- enabled boolean
- events
Types string[] - The type events you want to subscript to can be
- name string
- The name of the webhook that will be created in harbor.
- notify
Type string - The notification type either
http
orslack
. - project
Id string - The project id of the harbor that webhook related to.
- skip
Cert booleanVerify
- address str
- The address of the webhook.
- auth_
header str - description str
- enabled bool
- events_
types Sequence[str] - The type events you want to subscript to can be
- name str
- The name of the webhook that will be created in harbor.
- notify_
type str - The notification type either
http
orslack
. - project_
id str - The project id of the harbor that webhook related to.
- skip_
cert_ boolverify
- address String
- The address of the webhook.
- auth
Header String - description String
- enabled Boolean
- events
Types List<String> - The type events you want to subscript to can be
- name String
- The name of the webhook that will be created in harbor.
- notify
Type String - The notification type either
http
orslack
. - project
Id String - The project id of the harbor that webhook related to.
- skip
Cert BooleanVerify
Package Details
- Repository
- harbor pulumiverse/pulumi-harbor
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
harbor
Terraform Provider.