When an image is private, it is only available to the tenant to which that image was uploaded. OpenStack Image Service provides a mechanism whereby these private images can be shared between different tenants. This allows greater control over images that need to exist for different tenants without making them public for all tenants.
Getting ready
To begin with, ensure you are logged in to our Ubuntu client where we can run the glance tool. This can be installed using the following command:
Carry out the following steps to share a private image in our cookbook tenant to another tenant:
We first get the tenant ID of the tenant that is able to use our image. We do this as follows:
keystone tenant-list
We then list our images as follows:
glance image-list
From our cookbook tenant with ID 45c787efeaec42aa9cab522711bf5f4d and an image with ID 18584bff-2c12-4c2d-85f6-59771073c936, we would share the image as follows: