From documentation I know that images are global resources that "are accessible by any resource in any zone within the same project".
I am looking for a functionality similar to sharing AMIs within AWS. That is, I create an image, make it public and anyone can use it immediately.
How to best achieve something similar in GCE? The problem is that the image I need to create would be large - around 100GB. So I am looking for a way of sharing the image that wouldn't involve slow copying (e.g. from a bucket in google cloud storage).
App Engine is Google's Platform-as-a-Service offering and Compute Engine is Google's Infrastructure-as-a-Service offering. App Engine is great for running web-based apps, line of business apps, and mobile backends. Compute Engine is great for when you need more control of the underlying infrastructure.
You could use Google Cloud Storage, but then you will be charged every time it will be downloaded, and it will take long time (if it is 100 GB).
The better solution is to give the user "Can view" access to your project. Then user can create a instance using your image, using gcloud
command line. But be aware, that user will see all that you have in the project, he just won't be able to change it.
This solution is faster, if the owner of the image, has used it in the zone, you want to use. Because the image is cashed there, and it will start instantaneously. Another plus is, that owner doesn't get charged if someone downloads this image.
`gcloud compute instances create [INSTANCE_NAME]
--image-family [IMAGE_FAMILY]
--image-project [IMAGE_PROJECT]
--machine_type=<type-of-machine>
--network="default"
--family my-image-family`
If you want to give access to a larger group of people, you can create a Google group, allow group members "Can view" access to the project. Now you can control who can access it, using your Google group.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With