From 13487f4a39d63db6b816004163fda3d905f16ae5 Mon Sep 17 00:00:00 2001 From: Ross Light Date: Fri, 30 Jul 2021 20:50:29 -0700 Subject: [PATCH] Add timeout parameter --- main.tf | 2 ++ variables.tf | 5 +++++ 2 files changed, 7 insertions(+) diff --git a/main.tf b/main.tf index 39916b0..300dc57 100644 --- a/main.tf +++ b/main.tf @@ -141,6 +141,8 @@ resource "google_cloudbuild_trigger" "deploy" { name = local.firebase_image args = ["deploy"] } + + timeout = "${var.cloud_build_timeout_sec}s" } trigger_template { diff --git a/variables.tf b/variables.tf index 232737c..1d86689 100644 --- a/variables.tf +++ b/variables.tf @@ -29,6 +29,11 @@ variable "cloud_build_trigger" { description = "If set to true, then run Cloud Build to deploy to Hugo on every commit to main." } +variable "cloud_build_timeout_sec" { + default = 600 + description = "Number of seconds before Cloud Build times out" +} + variable "hugo_env" { default = [] description = "List of environment variables to pass to Hugo during build without the `HUGO_` prefix."