Ubuntu
build images with Packer
There can be variants defined by the ansible playbook in the folder ansible.
For instance the variant docker
selects the ansible playbook ansible-playbook-docker.yml
.
The rentention
step deletes all but the last two images.
For delete process pattern matching with grep
is used, hence the variants should not contain -
to avoid deleting images with longer variant names.
CI variables
There are the following CI variables:
variable | description |
---|---|
HCLOUD_PROJECT | the hcloud project to be used |
PKR_VAR_hcloud_image | the hcloud image to be used as base |
PKR_VAR_variant | the variant (ansible plabook) to be build |