diff --git a/README.md b/README.md index 3b1c10a..917b202 100644 --- a/README.md +++ b/README.md @@ -43,9 +43,11 @@ module "pubsub" { | Name | Description | |------|-------------| +| id | The ID of the Pub/Sub topic | | subscription_names | The name list of Pub/Sub subscriptions | | subscription_paths | The path list of Pub/Sub subscriptions | | topic | The name of the Pub/Sub topic | +| uri | The URI of the Pub/Sub topic | [^]: (autogen_docs_end) @@ -155,4 +157,4 @@ are as follows: - Golang - gofmt. gofmt comes with the standard golang installation. golang -s a compiled language so there is no standard linter. - Terraform - terraform has a built-in linter in the `terraform validate` command. -- Dockerfiles - hadolint. Can be found in homebrew +- Dockerfiles - hadolint. Can be found in homebrew \ No newline at end of file diff --git a/outputs.tf b/outputs.tf index c41ad88..649aea4 100644 --- a/outputs.tf +++ b/outputs.tf @@ -19,6 +19,16 @@ output "topic" { description = "The name of the Pub/Sub topic" } +output "id" { + value = "${google_pubsub_topic.topic.id}" + description = "The ID of the Pub/Sub topic" +} + +output "uri" { + value = "pubsub.googleapis.com/${google_pubsub_topic.topic.id}" + description = "The URI of the Pub/Sub topic" +} + output "subscription_names" { value = "${concat( google_pubsub_subscription.push_subscriptions.*.name,