2016-08-08 19:25:52 +02:00
|
|
|
---
|
|
|
|
layout: "bitbucket"
|
2016-10-03 14:23:54 +02:00
|
|
|
page_title: "Bitbucket: bitbucket_hook"
|
2016-08-08 19:25:52 +02:00
|
|
|
sidebar_current: "docs-bitbucket-resource-hook"
|
|
|
|
description: |-
|
|
|
|
Provides a Bitbucket Webhook
|
|
|
|
---
|
|
|
|
|
|
|
|
# bitbucket\_hook
|
|
|
|
|
|
|
|
Provides a Bitbucket hook resource.
|
|
|
|
|
|
|
|
This allows you to manage your webhooks on a repository.
|
|
|
|
|
|
|
|
## Example Usage
|
|
|
|
|
|
|
|
```
|
2017-04-03 18:52:35 +02:00
|
|
|
# Manage your repositories hooks
|
2016-08-08 19:25:52 +02:00
|
|
|
resource "bitbucket_hook" "deploy_on_push" {
|
2017-02-18 23:48:50 +01:00
|
|
|
owner = "myteam"
|
|
|
|
repository = "terraform-code"
|
|
|
|
url = "https://mywebhookservice.mycompany.com/deploy-on-push"
|
|
|
|
description = "Deploy the code via my webhook"
|
|
|
|
|
|
|
|
events = [
|
|
|
|
"repo:push",
|
|
|
|
]
|
2016-08-08 19:25:52 +02:00
|
|
|
}
|
|
|
|
```
|
|
|
|
|
|
|
|
## Argument Reference
|
|
|
|
|
|
|
|
The following arguments are supported:
|
|
|
|
|
2016-09-09 21:13:45 +02:00
|
|
|
* `owner` - (Required) The owner of this repository. Can be you or any team you
|
2016-08-08 19:25:52 +02:00
|
|
|
have write access to.
|
|
|
|
* `repository` - (Required) The name of the repository.
|
|
|
|
* `url` - (Required) Where to POST to.
|
|
|
|
* `description` - (Required) The name / description to show in the UI.
|
|
|
|
* `events` - (Required) The event you want to react on.
|