Last active
March 9, 2016 08:06
-
-
Save DrPaulBrewer/f8beeb9af349ad32a219 to your computer and use it in GitHub Desktop.
gcloud-discounted-VM-with-disk-and-startup-script.sh
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
!/bin/bash | |
# Do NOT use this as-is | |
# you probably need to change a few lines (disk, subnet, script) | |
# The google compute engine web UI may provide you | |
# with an equivalent command line for a specific configuration built in the web UI | |
gcloud compute instances create "my-spark-notebook" \ | |
--description "docker spark jupyter-notebook analysis platform" \ | |
--zone "us-east1-c" \ | |
--machine-type "n1-highcpu-32" \ | |
--subnet "default-754f8fec2c9e9fe2" \ | |
--metadata startup-script-url=https://storage.googleapis.com/eaftc-spark-init/sparkinit.sh \ | |
--no-restart-on-failure \ | |
--maintenance-policy "TERMINATE" \ | |
--preemptible \ | |
--scopes default="https://www.googleapis.com/auth/cloud.useraccounts.readonly","https://www.googleapis.com/auth/devstorage.read_only","https://www.googleapis.com/auth/logging.write","https://www.googleapis.c\ | |
om/auth/monitoring.write" \ | |
--tags "http-server","https-server" \ | |
--disk "name=jupyter-data,device-name=jupyter-data,mode=rw,boot=no" \ | |
--image "https://www.googleapis.com/compute/v1/projects/coreos-cloud/global/images/coreos-stable-835-13-0-v20160218" \ | |
--boot-disk-size "20" \ | |
--boot-disk-type "pd-ssd" \ | |
--boot-disk-device-name "spark-notebook" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment