Skip to content

Commit

Permalink
Add tag support to doppler_secrets_sync_aws_secrets_manager
Browse files Browse the repository at this point in the history
  • Loading branch information
watsonian committed Jan 8, 2024
1 parent b89afde commit b847413
Show file tree
Hide file tree
Showing 3 changed files with 17 additions and 0 deletions.
6 changes: 6 additions & 0 deletions docs/resources/secrets_sync_aws_secrets_manager.md
Original file line number Diff line number Diff line change
Expand Up @@ -71,10 +71,12 @@ resource "doppler_secrets_sync_aws_secrets_manager" "backend_prod" {
region = "us-east-1"
path = "/backend/"
tags = { myTag = "enabled" }
}
```

<!-- schema generated by tfplugindocs -->

## Schema

### Required
Expand All @@ -85,6 +87,10 @@ resource "doppler_secrets_sync_aws_secrets_manager" "backend_prod" {
- `project` (String) The name of the Doppler project
- `region` (String) The AWS region

### Optional

- `tags` (Map of String) AWS tags to attach to the secrets

### Read-Only

- `id` (String) The ID of this resource.
10 changes: 10 additions & 0 deletions doppler/resource_sync_types.go
Original file line number Diff line number Diff line change
Expand Up @@ -19,11 +19,21 @@ func resourceSyncAWSSecretsManager() *schema.Resource {
Required: true,
ForceNew: true,
},
"tags": {
Description: "AWS tags to attach to the secrets",
Type: schema.TypeMap,
Elem: &schema.Schema{
Type: schema.TypeString,
},
Optional: true,
ForceNew: true,
},
},
DataBuilder: func(d *schema.ResourceData) IntegrationData {
return map[string]interface{}{
"region": d.Get("region"),
"path": d.Get("path"),
"tags": d.Get("tags"),
}
},
}
Expand Down
1 change: 1 addition & 0 deletions examples/resources/integration_aws_secrets_manager.tf
Original file line number Diff line number Diff line change
Expand Up @@ -57,5 +57,6 @@ resource "doppler_secrets_sync_aws_secrets_manager" "backend_prod" {

region = "us-east-1"
path = "/backend/"
tags = { myTag = "enabled" }
}

0 comments on commit b847413

Please sign in to comment.