diff --git a/modules/cloud-function/README.md b/modules/cloud-function/README.md
index d0e91d8d..935c58ae 100644
--- a/modules/cloud-function/README.md
+++ b/modules/cloud-function/README.md
@@ -140,6 +140,7 @@ module "cf-http" {
| name | Name used for cloud function and associated resources. | string
| ✓ | |
| project_id | Project id used for all resources. | string
| ✓ | |
| *bucket_config* | Enable and configure auto-created bucket. Set fields to null to use defaults. | object({...})
| | null
|
+| *description* | Optional description. | string
| | Terraform managed.
|
| *environment_variables* | Cloud function environment variables. | map(string)
| | {}
|
| *function_config* | Cloud function configuration. | object({...})
| | ...
|
| *iam* | IAM bindings for topic in {ROLE => [MEMBERS]} format. | map(list(string))
| | {}
|
diff --git a/modules/cloud-function/main.tf b/modules/cloud-function/main.tf
index cbef1b47..de04f228 100644
--- a/modules/cloud-function/main.tf
+++ b/modules/cloud-function/main.tf
@@ -59,7 +59,7 @@ resource "google_cloudfunctions_function" "function" {
project = var.project_id
region = var.region
name = "${local.prefix}${var.name}"
- description = "Terraform managed."
+ description = var.description
runtime = var.function_config.runtime
available_memory_mb = var.function_config.memory
max_instances = var.function_config.instances
diff --git a/modules/cloud-function/variables.tf b/modules/cloud-function/variables.tf
index 433e768a..05c57e36 100644
--- a/modules/cloud-function/variables.tf
+++ b/modules/cloud-function/variables.tf
@@ -36,6 +36,12 @@ variable "bundle_config" {
})
}
+variable "description" {
+ description = "Optional description."
+ type = string
+ default = "Terraform managed."
+}
+
variable "environment_variables" {
description = "Cloud function environment variables."
type = map(string)