Skip to content

Commit f19c5b8

Browse files
committed
type conversion
1 parent af9fa08 commit f19c5b8

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

libs/platforms/rosa/terraform/terraform.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -121,7 +121,7 @@ def apply_tf_template(self, platform):
121121
return 0
122122
trying += 1
123123
cluster_apply_time = int(datetime.datetime.utcnow().timestamp())
124-
terraform_apply_code, terraform_apply_out, terraform_apply_err = self.utils.subprocess_exec("terraform apply -state=" + tf_path + "/terraform.tfstate " + tf_path + "/" + tf_name + ".tfplan", tf_path + "/terraform_apply-" + trying + ".log", {"cwd": self.environment['path'] + "/terraform", 'preexec_fn': self.utils.disable_signals, "env": myenv})
124+
terraform_apply_code, terraform_apply_out, terraform_apply_err = self.utils.subprocess_exec("terraform apply -state=" + tf_path + "/terraform.tfstate " + tf_path + "/" + tf_name + ".tfplan", tf_path + "/terraform_apply-" + str(trying) + ".log", {"cwd": self.environment['path'] + "/terraform", 'preexec_fn': self.utils.disable_signals, "env": myenv})
125125
if terraform_apply_code != 0:
126126
self.logging.debug(terraform_apply_out)
127127
self.logging.debug(terraform_apply_err)
@@ -200,7 +200,7 @@ def destroy_tf_template(self, platform, tf_module="cluster"):
200200
self.logging.error(f"Exiting clusters deletion for {tf_name} looping {loop_counter + 1} after capturing Ctrl-C")
201201
return 0
202202
trying += 1
203-
cleanup_code, cleanup_out, cleanup_err = self.utils.subprocess_exec("terraform apply -destroy -state=" + tf_path + "/terraform.tfstate --auto-approve", tf_path + "/cleanup-" + trying + ".log", {"cwd": self.environment['path'] + "/terraform", 'preexec_fn': self.utils.disable_signals, "env": myenv})
203+
cleanup_code, cleanup_out, cleanup_err = self.utils.subprocess_exec("terraform apply -destroy -state=" + tf_path + "/terraform.tfstate --auto-approve", tf_path + "/cleanup-" + str(trying) + ".log", {"cwd": self.environment['path'] + "/terraform", 'preexec_fn': self.utils.disable_signals, "env": myenv})
204204
if cleanup_code != 0:
205205
self.logging.debug(f"Clusters Cleanup with seed {tf_name} looping {loop_counter + 1} is failed")
206206
self.logging.debug(cleanup_out)

0 commit comments

Comments
 (0)