Google Compute Engine : Use snapshot from another project?
The answer posted by @chrispomeroy worked for me, but I was able to simplify it a little as I need to do this more and more.
Let's say you have an image in project-1, and need to create an instance using that image in project-2.
gcloud config set project "project-2"
gcloud compute instances create <name-of-new-instance> \
--image <name-of-your-image-from-project-1> \
--image-project "project-1"
This eliminates the need to worry about using a URL
for anything.
EDIT: My answer pretty much looks like his at this point, but the docs for this stuff is here:
gcloud compute instances create
You can create an image from the snap in Project 1, then create an instance from that image using Project 2.
I'm assuming you have edit rights in both projects.
Your question says you have a snapshot and want to make an instance in project 2 from the snap in project 1.
If you still have the disk available that you had snapshotted, make sure it's no longer attached to an instance. If it's still attached to the instance, uncheck "delete boot disk when deleting instance" and delete the instance. Go to Images and click create image from disk, and create an image from this disk.
If you do not have the disk available, but just the snapshot, create an instance and set the boot disk as a snapshot and select your snapshot. Then follow the directions above to create an image by deleting the instance first.
Now you have an image in project 1. You should see it listed under images.
I'm not sure why, but you won't see the image listed in the console in project 2, however you can use gcloud to create an instance in project 2 using the image from project 1. In project 1, click on the image and click "view REST" there will be a full URL to the image, similar to this:
https://www.googleapis.com/compute/v1/projects/cpomeroy-whitelist/global/images/ruby-image
Use gcloud to create an instance in project 2 using the image in project 1:
gcloud config set project <project-id-of-project-2>
gcloud config list
(You should verify you are in project 2)
gcloud compute instances create <name of instance> --image https://www.googleapis.com/compute/v1/projects/cpomeroy-whitelist/global/images/ruby-image
Obviously your URL will be different.
I just tested this and it works. Let me know if you need more help.