From 819b935a4fb9d4de315dfb310be3233cf8cc33c7 Mon Sep 17 00:00:00 2001 From: James Cleverley-Prance Date: Tue, 22 Feb 2022 11:24:23 +0000 Subject: [PATCH] fix: ensure tests are run during node re-deploy --- terraform/modules/AWS/Kubernetes/test.tf | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/terraform/modules/AWS/Kubernetes/test.tf b/terraform/modules/AWS/Kubernetes/test.tf index cc8238bf..82e05fe2 100644 --- a/terraform/modules/AWS/Kubernetes/test.tf +++ b/terraform/modules/AWS/Kubernetes/test.tf @@ -1,6 +1,10 @@ resource "null_resource" "master_test" { count = var.number_of_master_instances + triggers = { + cluster_instance_ids = "${join(",", aws_instance.simulator_master_instances.*.id)}" + } + connection { bastion_host = var.bastion_public_ip bastion_private_key = file(pathexpand("~/.kubesim/cp_simulator_rsa")) @@ -41,6 +45,10 @@ resource "null_resource" "master_test" { resource "null_resource" "node_test" { count = var.number_of_cluster_instances + triggers = { + cluster_instance_ids = "${join(",", aws_instance.simulator_node_instances.*.id)}" + } + connection { bastion_host = var.bastion_public_ip bastion_private_key = file(pathexpand("~/.kubesim/cp_simulator_rsa")) @@ -55,6 +63,7 @@ resource "null_resource" "node_test" { agent = "false" private_key = file(pathexpand("~/.kubesim/cp_simulator_rsa")) + // Increase the timeout so the server has time to reboot timeout = "10m" } @@ -77,4 +86,3 @@ resource "null_resource" "node_test" { ] } } -