Closed DavidGOrtega closed 2 years ago
I feel adding something to the effect of systemctl is-active cml.service
(returning "failed") in here:
https://github.com/iterative/terraform-provider-iterative/blob/b47f8014c1a222362b43ac9c5afc8a9522fa7ea3/iterative/resource_runner.go#L253-L271
when it fails, triggers a cleanup, capturing https://github.com/iterative/cml/issues/906 as well. In the latter's error printing coming from this condition: https://github.com/iterative/terraform-provider-iterative/blob/b47f8014c1a222362b43ac9c5afc8a9522fa7ea3/iterative/resource_runner.go#L278-L284
Thoughts?
I believe this was resolved with: https://github.com/iterative/terraform-provider-iterative/pull/460 I tried to reproduce this with: https://github.com/iterative/cml/compare/trigger-tpi-348
closed via #460
It clears up the resource if failing creating the machine, however, if registering the runner fails it might not be destroying the resource!?