The json credential resource allows you to congiure a credential using a json object.
resource "boundary_scope" "org" {
name = "organization_one"
description = "global scope"
scope_id = "global"
auto_create_admin_role = true
auto_create_default_role = true
}
resource "boundary_scope" "project" {
name = "project_one"
description = "My first scope!"
scope_id = boundary_scope.org.id
auto_create_admin_role = true
}
resource "boundary_credential_store_static" "example" {
name = "example_static_credential_store"
description = "My first static credential store!"
scope_id = boundary_scope.project.id
}
resource "boundary_credential_json" "example" {
name = "example_json"
description = "My first json credential!"
credential_store_id = boundary_credential_store_static.example.id
object = file("~/object.json") # change to valid json file
}
credential_store_id
(String) The credential store in which to save this json credential.object
(String, Sensitive) The object for the this json credential. Either values encoded with the "jsonencode" function, pre-escaped JSON string, or a filedescription
(String) The description of this json credential.name
(String) The name of this json credential. Defaults to the resource name.id
(String) The ID of this json credential.object_hmac
(String) The object hmac.Import is supported using the following syntax:
terraform import boundary_credential_json.example_json <my-id>