Recent posts

Testing Kubernetes resources with Kuttl

1 minute read

In Kubernetes the infrastructure that runs an application is described by some YAML manifests. While application source code is tested with additional code written almost always in the same language, manifest describing the architecture are almost never tested. It means that changes in the manifests affect immediately the infrastructure.

Testing Infrastructure as Code with Python

2 minute read

Infrastructure code is considered 100% code but often good software principle, like testing, are not applied. Apart from checking the correctness of code, testing documents how code should behave, as well. In this post I will show how to test a Terraform module using the Python module tftest along with the testing framework pytest.

Customize Go tests with Flag options

1 minute read

Often some tests of a Go package need to interact with another system. You can mock it but at a certain point, the tests should run against a real system located at a certain address, using a some credentials, and so on. The real system has some parameters that should not be hardcoded because they are ephemeral or because is not safe. To customize these p...

Debugging EC2 user_data script

1 minute read

AWS EC2 instances can be initialized easily at startup using a custom script in the user_data field. Our instances will be ready to use and have all tools installed. It is a great advantage when the initialization script is easy, because we don’t need to use separate tool like Ansible. However, user_data can be tricky because it is not so friendly to debu...