Adding cloud builders
Building base images locally during development can save a lot of time and money. Waiting for cloud resources to be provisioned can be fairly quick, but usually not as quick as a well-tuned local resource. Also, repeated attempts to provision while addressing minor mistakes during development can generate a significant cloud bill. Once development is complete, you may want to push production images directly through cloud builders.
Providing your cloud credentials
Most cloud builders use similar credential configurations. Static credentials can be defined in your code. As usual, it isn’t wise to store these raw credentials in code. Environment variables can be used for credentials stored outside of the template code. These would need to be set in your build environment or Packer automation pipeline. Even better, we will cover how HashiCorp Vault can issue short-term credentials to Packer templates so that any leaked logs with credentials only show...