Closed enolfc closed 2 months ago
Manual tests working for me, thanks!
how can we automate this?
Manual tests working for me, thanks!
how can we automate this?
AKA @brucellino? 😇
Manual tests working for me, thanks!
how can we automate this?
AKA @brucellino? 😇
I guess we can:
And if we do step 0, build the image as part of the action, then this would be 🚀
I would have typically used terratest for this - if can rely on the terraform provider, then nontrivial test cases can be written. I have a basic example https://github.com/brucellino/terraform-digitalocean-vpc/blob/main/test/vpc_test.go
We can easily test point 3 above by writing an inspec or testinfra compliance profile, and then using a Terraform provisioner during the test.
However, it's better to separate layers - test the image during image build time and test the deployment at deployment time. So we should insert the compliance profile in the packer template, and then write infrastructure tests for the deployment.
This should actually be native in Terraform > 1.7 iirc so we might not need Terratest after all.... @enolfc you want to open an issue on this and see where we can get to?
Summary
Update to the image as it's expiring in 4 days
Related issue :