From 00a7d3078ce75ebc1daca31bb0cd677acbe4d2a8 Mon Sep 17 00:00:00 2001 From: Paul Bastide Date: Tue, 12 Dec 2023 08:59:01 -0500 Subject: [PATCH] fix: resolve issue with cis Signed-off-by: Paul Bastide --- modules/4_pvs_support/pvs_support.tf | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/modules/4_pvs_support/pvs_support.tf b/modules/4_pvs_support/pvs_support.tf index 3f9e9b1..92ac7c7 100644 --- a/modules/4_pvs_support/pvs_support.tf +++ b/modules/4_pvs_support/pvs_support.tf @@ -139,12 +139,14 @@ EOF } resource "null_resource" "create_resolv_conf_for_intel_workers" { + count = var.ibm_cloud_cis ? 0 : 1 + depends_on = [null_resource.limit_csi_arch] connection { type = "ssh" user = var.rhel_username host = var.bastion_public_ip - private_key = file(var.private_key_file) + private_key = sensitive(file(var.private_key_file)) agent = var.ssh_agent timeout = "${var.connection_timeout}m" } @@ -172,12 +174,12 @@ EOF } resource "null_resource" "migrate_mcp" { - depends_on = [null_resource.limit_csi_arch] + depends_on = [null_resource.limit_csi_arch, null_resource.create_resolv_conf_for_intel_workers] connection { type = "ssh" user = var.rhel_username host = var.bastion_public_ip - private_key = file(var.private_key_file) + private_key = sensitive(file(var.private_key_file)) agent = var.ssh_agent timeout = "${var.connection_timeout}m" }