Page Menu
Home
Phabricator
Search
Configure Global Search
Log In
Files
F3349916
D12730.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Flag For Later
Size
878 B
Referenced Files
None
Subscribers
None
D12730.diff
View Options
diff --git a/services/terraform/self-host/keyserver_secondary.tf b/services/terraform/self-host/keyserver_secondary.tf
--- a/services/terraform/self-host/keyserver_secondary.tf
+++ b/services/terraform/self-host/keyserver_secondary.tf
@@ -126,6 +126,21 @@
operating_system_family = "LINUX"
}
+ # Wait indefinitely for primary service to become healthy before deploying secondary service
+ provisioner "local-exec" {
+ command = <<EOT
+ while true; do
+ if curl --silent --output /dev/null --fail "https://${var.domain_name}/health"; then
+ echo "Primary service is healthy. Proceeding with deployment of secondary service."
+ exit 0
+ else
+ echo "Primary service is not healthy yet. Waiting 10 seconds before checking again..."
+ sleep 10
+ fi
+ done
+ EOT
+ }
+
skip_destroy = false
}
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Sat, Nov 23, 7:46 PM (16 h, 13 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
2572256
Default Alt Text
D12730.diff (878 B)
Attached To
Mode
D12730: [terraform] Ensure that the primary service is running before deploying secondary service
Attached
Detach File
Event Timeline
Log In to Comment