2015-02-05 53 views
0

我正在嘗試在我的Google AppEngine項目中使用Google雲端平臺「Push-to-deploy」,以便持續投放。「推送」GCP功能

這是我第一次嘗試使用它,我無法創建我的虛擬機。

ERROR: (gcloud.compute.instances.create) Could not fetch image resource: - The resource 'projects/bitnami-launchpad/global/images/bitnami-jenkins-1-587-0-linux-debian-7-x86-64-image' was not found

我在配置中錯過了什麼嗎?也許這只是jenkins圖像的這個版本不可用?如何列出可用於項目bitnami-launchpad的圖像?

謝謝你的幫助...

回答

3

我已經得到了我的答案。 要獲得可用的bitnami圖像列表,我們必須將gcloud當前項目設置爲bitnami-launchpad,然後我們可以列出圖像。

gcloud config set project bitnami-launchpad gcloud compute images list

並在列表中,我詹金斯用好版本!

bitnami-jenkins-1-598-0-r01-linux-debian-7-x86-64

然後:

gcloud compute \ instances create bitnami-jenkins \ --project ${PROJECT_ID} \ --image-project bitnami-launchpad \ --image bitnami-jenkins-1-598-0-r01-linux-debian-7-x86-64 \ --zone us-central1-a \ --machine-type n1-standard-1 \ --metadata "bitnami-base-password=${PASSWORD}" \ "bitnami-default-user=user" \ "bitnami-key=jenkins" \ "bitnami-name=Jenkins" \ "bitnami-version=1-598-0-r01" \ "bitnami-url=//bitnami.com/stack/jenkins" \ "bitnami-description=Jenkins." \ "startup-script-url=https://dl.google.com/dl/jenkins/p2dsetup/setup-script.sh" \ --scopes "https://www.googleapis.com/auth/userinfo.email" \ "https://www.googleapis.com/auth/devstorage.full_control" \ "https://www.googleapis.com/auth/projecthosting" \ "https://www.googleapis.com/auth/appengine.admin" \ --tags "bitnami-launchpad"

創建詹金斯實例。

+1

或者在一個命令中:'gcloud compute images list --project = bitnami-launchpad' - 參見[docs](https://cloud.google.com/sdk/gcloud/reference/compute/images/list)。 – 2015-02-06 23:29:47