As of Juju 2.8.0, Juju administrators are now able to specify virtual machine images that Juju should consider when provisioning new compute capacity on Amazon AWS and OpenStack. The
juju metadata add-image command informs Juju that an image should be considered when the series is selected.
The basic syntax involves tagging a specific series name with an “image identifier” or
juju metadata add-image --series <series> <image-id>
The format for image identifiers is provider-specific. Juju passes this information to the cloud directly and performs minimal validation when the image is added. Here are some provider-specific guides for identifying which
<image-id> to select:
- AWS EC2 refers to images as “AMIs” (Amazon Machine Image). AMIs are region-specific.
- Google Compute Engine https://cloud.google.com/compute/docs/images
- Azure Machine Images
metadata add-image sub-command includes a number of provider-specific options that may be useful for specialised use cases:
--virt-type: the virtualisation type for the VM, e.g.
--storage-type: the root disk storage type, e.g.
ebsfor Elastic Block Storage on AWS
--storage-size: the size of the VM’s root disk
juju metadata command provides the ability for Juju administrators to introspect the VM images that clouds support. The image metadata is also how controllers know how to provision new machines.
juju metadata includes several sub-commands:
add-image: (new) adds image metadata to model
delete-image: deletes image metadata from environment
generate-agents: generate simplestreams agent metadata
generate-image: generate simplestreams image metadata
list-images: lists cloud image metadata that’s currently available
sign: cryptographically sign simplestreams metadata
validate-agents: validate agent metadata and ensure agent binary tarball(s) exist for Juju version(s)
validate-images- validate image metadata and ensure image(s) exist for a model