Skip to content

Commit

Permalink
feat(app): create variables for env var configurables
Browse files Browse the repository at this point in the history
  • Loading branch information
bethdevopsbunny committed Aug 25, 2023
1 parent 9182939 commit 78d6049
Show file tree
Hide file tree
Showing 2 changed files with 21 additions and 3 deletions.
6 changes: 3 additions & 3 deletions main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -42,15 +42,15 @@ resource "google_cloud_run_service" "default" {
}
env {
name = "ACTIVATION_TIMEOUT"
value = "60"
value = var.maximum_duration
}
env {
name = "JUSTIFICATION_HINT"
value = "Bug or case number"
value = var.justification_hint
}
env {
name = "JUSTIFICATION_PATTERN"
value = ".*"
value = var.justification_pattern
}
env {
name = "IAP_BACKEND_SERVICE_ID"
Expand Down
18 changes: 18 additions & 0 deletions variables.tf
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,24 @@ variable "allow_unauthenticated_invocations" {
default = false
}

variable "maximum_duration" {
type = number
description = "Sets the longest duration that a user can request"
default = 60
}

variable "justification_hint" {
type = string
description = "Hint provided to the user when selecting why they are asking for the role"
default = "Bug or case number"
}

variable "justification_pattern" {
type = string
description = "Regex pattern that justification must match"
default = ".*"
}

## Scope Variables
variable "scope_type" {
type = string
Expand Down

0 comments on commit 78d6049

Please sign in to comment.