Skip to content

Commit

Permalink
Added readiness_delay, switch to tcp readiness check
Browse files Browse the repository at this point in the history
  • Loading branch information
BSick7 committed Jan 30, 2024
1 parent 0536386 commit 9b92439
Show file tree
Hide file tree
Showing 3 changed files with 17 additions and 5 deletions.
3 changes: 3 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
# 0.6.1 (Jan 30, 2024)
* Added readiness_delay, switch to tcp readiness check

# 0.6.0 (Aug 08, 2023)
* Added compliance scanning.
* Update `README.md` with application management info.
Expand Down
8 changes: 3 additions & 5 deletions deployment.tf
Original file line number Diff line number Diff line change
Expand Up @@ -73,14 +73,12 @@ resource "kubernetes_deployment_v1" "this" {
readiness_probe {
failure_threshold = 3
success_threshold = 1
initial_delay_seconds = 0
initial_delay_seconds = var.readiness_delay
period_seconds = 10
timeout_seconds = 1

http_get {
scheme = "HTTP"
path = "/"
port = var.port
tcp_socket {
port = var.port
}
}

Expand Down
11 changes: 11 additions & 0 deletions variables.tf
Original file line number Diff line number Diff line change
Expand Up @@ -46,3 +46,14 @@ the service will fail due to bind due to permission errors.
Specify 0 to disable network connectivity to this container.
EOF
}

variable "readiness_delay" {
type = number
default = 0
description = <<EOF
The period of time (in seconds) to delay before performing a readiness check against the application.
If an application has a long start time, readiness_delay can be used to defer readiness checks on the application.
The default value is 0.
EOF
}

0 comments on commit 9b92439

Please sign in to comment.