• Using AWS Karpenter with spot instances

    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...
  • Terraform: retrieve AWS information

    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...
  • Using multi-stage build to optimize Docker images

    2 min read

    docker build multistage

    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...
  • Load a Jenkins Pipeline Shared Library from a git repository

    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:

    • We don't have admin access to Jenkins (so we might need to request every single change)
    • We need to test several libraries, so we would need to configure every single library we want to test

    13/01/2022

    Read more...
  • Kubernetes PersistentVolume: Data cleanup on object deletion

    2 min read

    kubernetes PersistentVolume persistentVolumeReclaimPolicy

    A PersistentVolume is the abstract representation of storage as a resource within a Kubernetes cluster. The attributes describe the storage resource, it's underlying resource can either be a disk provisioned by the cloud you are using or something as simple as manually provisioned NFS disk

    On PersistentVolumes we can configure several reclaim policies to define how it's data removal is handled once the PersistentVolume object is deleted.

    12/01/2022

    Read more...

More recent...

Older content...