2 min read
When we are deploying infrastructure using terraform we need to understand that we should not be modifying what we have deployed, otherwise terraform will undo these changes if we apply it again. This is actually a good thing to make sure the code reflex the state of the infrastructure but sometimes can be a pain
24/01/2022
Read more...3 min read
One of the advantages of using AWS Karpenter is that makes straightforward using spot instances. But how do we handle termination notices coming from AWS?
21/01/2022
Read more...2 min read
When running terraform on an AWS account we might need to have some context information such as it's account ID or the region we are in. Instead of having to set them as variables we can use the aws_caller_identity, aws_partition and aws_region datasources to retrieve this information
19/01/2022
Read more...2 min read
To be able to build a Docker image we might need some packages that we won't be using at runtime, an example of this would be the compiler or any of the tools we might be using to build it (make, ant, maven...)
Instead of installing the tools to remove them later on while building the Docker image we can use a multistage build so we can just copy the artifacts we need to the final image.
17/01/2022
Read more...2 min read
To load a specific Jenkins Pipeline Shared Library we can use the @Library() function, but the library needs to be configured on Jenkins:
@Library('demo-shared-library') _
This is particularly annoying if:
13/01/2022
Read more...