mirror of
https://github.com/Kichiyaki/terraform-provider-woodpecker.git
synced 2024-06-26 14:27:41 +00:00
55 lines
1.8 KiB
Markdown
55 lines
1.8 KiB
Markdown
---
|
|
# generated by https://github.com/hashicorp/terraform-plugin-docs
|
|
page_title: "woodpecker_repository_secret Resource - terraform-provider-woodpecker"
|
|
subcategory: ""
|
|
description: |-
|
|
This resource allows you to add/remove secrets that are only available to specific repositories. When applied, a new secret will be created. When destroyed, that secret will be removed. For more information see the Woodpecker docs https://woodpecker-ci.org/docs/usage/secrets.
|
|
---
|
|
|
|
# woodpecker_repository_secret (Resource)
|
|
|
|
This resource allows you to add/remove secrets that are only available to specific repositories. When applied, a new secret will be created. When destroyed, that secret will be removed. For more information see [the Woodpecker docs](https://woodpecker-ci.org/docs/usage/secrets).
|
|
|
|
## Example Usage
|
|
|
|
```terraform
|
|
resource "woodpecker_repository" "test_repo" {
|
|
full_name = "Kichiyaki/test-repo"
|
|
is_trusted = true
|
|
visibility = "public"
|
|
}
|
|
|
|
resource "woodpecker_repository_secret" "test" {
|
|
repository_id = woodpecker_repository.test_repo.id
|
|
name = "test"
|
|
value = "test"
|
|
events = ["cron", "deployment"]
|
|
}
|
|
```
|
|
|
|
<!-- schema generated by tfplugindocs -->
|
|
## Schema
|
|
|
|
### Required
|
|
|
|
- `events` (Set of String) events for which the secret is available (push, tag, pull_request, pull_request_closed, deployment, cron, manual, release)
|
|
- `name` (String) the name of the secret
|
|
- `repository_id` (Number) the ID of the repository
|
|
- `value` (String, Sensitive) the value of the secret
|
|
|
|
### Optional
|
|
|
|
- `images` (Set of String) list of Docker images for which this secret is available, leave blank to allow all images
|
|
|
|
### Read-Only
|
|
|
|
- `id` (Number) the secret's id
|
|
|
|
## Import
|
|
|
|
Import is supported using the following syntax:
|
|
|
|
```shell
|
|
terraform import woodpecker_repository_secret.test "<repository_id>/<name>"
|
|
```
|