SlideShare a Scribd company logo
SaltStack and
Google Compute Engine
Eric Johnson
Technical Program Manager
Agenda: January 30th, 2014
Whirlwind Tour of Google Cloud Platform
Google Compute Engine
Using SaltStack and Compute Engine (demo)
1
2
3
Whirlwind Tour of Google Cloud Platform
Google Compute Engine
Using SaltStack and Compute Engine (demo)
1
2
3
For the past 15 years, Google
has been building out the
world’s fastest, most powerful,
highest quality cloud
infrastructure on the planet.
Images by Connie Zhou
Why Google Cloud Platform?
A Network that Spans the Globe
Innovating Software & Driving Technology Forward
SpannerDremelMapReduce
Big Table Colossus
2012 20132002 2004 2006 2008 2010
GFS
Compute
Engine
Building Products that Scale
Google Maps Gmail Google Drive YouTube
“[Google's] ability to build, organize, and
operate a huge network of servers and fiber-
optic cables with an efficiency and speed that
rocks physics on its heels.
This is what makes Google Google: its physical
network, its thousands of fiber miles, and those
many thousands of servers that, in aggregate,
add up to the mother of all clouds.”
- Wired
Images by Connie Zhou
Storage
Cloud Storage Cloud SQL
Cloud
Datastore
Compute
Compute
Engine
App Engine
App Services
BigQuery
Cloud
Endpoints
Google Cloud Platform
Compute
Compute
Engine
App Engine
Storage
Cloud Storage Cloud SQL
Cloud
Datastore
App Services
BigQuery
Cloud
Endpoints
Power Computation
Storage
Cloud Storage Cloud SQL
Cloud
Datastore
Storing What You Want, However You Want
Compute
Compute
Engine
App Engine
App Services
BigQuery
Cloud
Endpoints
App Services
BigQuery
Cloud
Endpoints
Building Robust, Intelligent Systems
Storage
Cloud Storage Cloud SQL
Cloud
Datastore
Compute
Compute
Engine
App Engine
Whirlwind Tour of Google Cloud Platform
Google Compute Engine
Using SaltStack and Compute Engine (demo)
1
2
3
• IaaS: VMs, Network, Storage
• Google DNA (speed, scale, reliable, secure)
• Fast Provisioning, Consistent Performance
• Enterprise Ready
• 24x7 Support
• 99.95% monthly SLA
• ISO 27001, SSAE-16 SOC 1,2,3
• Accessible Through
• Web @ https://cloud.google.com/console
• gcutil command-line utility
• REST API
• Partners (Commercial and FOSS)
Google Compute Engine
Launching 100 virtual machines
Block Storage
Persistent Disks
Persistent Disk
10 TB
• Data and root partitions
• Billed only by capacity (GB/month)
• Performance caps scale linearly with size
• Volume striping is automatic
• Differential snapshots
• Create new PDs based on snapshots
PD Use-cases
Root
Stateful root
volume
User managed data
volume
Root
RW
Data
RO
Data
Instant distribution of
static content
Global Snapshot and Restore
GCS
vol1 vol2 vol3
vol1.
t2
vol2.
t2
vol3.
t3
t1 t1 t1
t1 t1 t1
t1 t1 t1
t1 t1
t1 t1
t2 t2
t2
t2
t3 t3 t3
● Point in time snapshot to
Google Cloud Storage
(GCS)
● Differential snapshots
● GCS global replication!
● Restore from snapshot
anywhere in the world
us-central1-a
europe-west1-a
Virtual Machines
standard
• For workloads with balanced CPU and
memory
highmem
• For workloads with higher memory
requirements
highcpu
• For workloads with higher CPU requirements
Shared Core Instances
• For inexpensive prototyping and staging
workloads (g1-small, f1-micro)
Machine Types
Machine Type Virtual Cores
Memory
(GB)
n1-standard-1 1 3.75
n1-standard-2 2 7.50
n1-standard-4 4 15.00
n1-standard-8 8 30.00
n1-standard-16 16 60.00
n1-highmem-2 2 13.00
n1-highmem-4 4 26.00
n1-highmem-8 8 52.00
n1-highmem-16 16 104.00
n1-highcpu-2 2 1.80
n1-highcpu-4 4 3.60
n1-highcpu-8 8 7.20
n1-highcpu-16 16 14.40
Images
+ Custom Kernel Support
(debian backports works great for docker)
Sub-hour Billing
1 minute granularity
10 minute minimum
Enhanced Reliability
us-central1-a
scheduled maintenance event
Live Migration
• No downtime during
scheduled datacenter
maintenance events
Automatic Restart
• Instances automatically
restarted if subjected to
system events such as
hardware failure
Networking
Images by Connie Zhou
Networking
• Google's Network
• Projects are isolated private networks
• TCP, UDP, ICMP only
• Multiple private network groups and firewalls
• Tags and address ranges
• Addresses
• public: static or ephemeral
• private: ephemeral with DNS
• Routes, gateways, VPNs, and IP Forwarding
Region: us-central1
Target Pool (tp-a)
Load-balancer
• Region based
• Session affinity
• Hashed on src ip:port and dst ip:port
• Consists of:
• Target pool: collection of instances
• Forwarding rules: protocol:port, pool
• HTTP health check: optional us-central1-b
us-central1-a
www0
www1
www2
www3
Forwarding Rules
tcp:443 ➔ tp-a
tcp:80 ➔ tp-a
Internet
http://googlecloudplatform.blogspot.com/2013/11/compute-engine-load-balancing-hits-1-million-requests-per-second.html
...and
Noteworthy
• Metadata
• Startup scripts
• SSH Keys
• Tags (instance/network)
• OAuth2 and Scopes
• Access other Google Cloud Platform services
• Ecosystem is growing
• Partners: RightScale, Scalr, New Relic, MongoLab, MapR, and many more...
• Open Source: Salt, Chef, Puppet, Ansible, Vagrant, Docker, CoreOS, fog, libcloud
Whirlwind Tour of Google Cloud Platform
Google Compute Engine
Using SaltStack and Compute Engine (demo)
1
2
3
Start to finish
1. Use the Developers Console to create the salt master (metadata: saltdemo=yup)
salt
This is a Compute
Engine instance
named "salt"
Start to finish
1. Use the Developers Console to create the salt-master (metadata: saltdemo=yup)
2. Use salt-cloud to create 4 instances (2 per zone), install apache
us-central1-a
minion1
minion3
us-central1-b
minion2
minion4
salt
# salt-cloud -P -m /etc/salt/demo.map
# salt 'minion*' state.highstate
GooglePublicAPI
Start to finish
1. Use the Developers Console to create the salt-master (metadata: saltdemo=yup)
2. Use salt-cloud to create 4 instances (2 per zone)
3. Use salt-cloud networking functions Region: us-central1
Target Pool (lb-tp)
us-central1-a
minion1
minion3
us-central1-b
minion2
minion4
Forwarding Rules
tcp:80 ➔ lb-tp
PublicLBIP:a.b.c.d
salt
# salt-cloud -f create_fwrule gce ...
# salt-cloud -f create_lb gce ...
Start to finish
1. Use the Developers Console to create the salt-master (metadata: saltdemo=yup)
2. Use salt-cloud to create 4 instances (2 per zone)
3. Use salt-cloud networking functions
4. Generate some HTTP requests to LB IP
Region: us-central1
Target Pool (lb-tp)
us-central1-a
minion1
minion3
us-central1-b
minion2
minion4
Forwarding Rules
tcp:80 ➔ lb-tp
PublicLBIP:a.b.c.d
Internet
dst port 80
salt
The salt master via custom "startup-script" metadata
startup-script1 #!/bin/bash
2
3 SALT=$(curl -s http://metadata/computeMetadata/v1beta1/instance/attributes/saltdemo)
4
5 if [ "$SALT" = "yup" ]; then
6 # update and install dependencies (libcloud 0.14.0 + bugfix)
7 apt-get install vim tmux git python-pip -y
8 pip install git+https://github.com/apache/libcloud@58f3722ba54dc79cc9ef40271f6a3d39d6e8841d
9
10 # salt master
11 curl -L http://bootstrap.saltstack.org | sudo sh -s -- -M -N git v2014.1.0rc3
12
13 # dev gce provider
14 git clone https://github.com/erjohnso/salt
15 cp salt/salt/cloud/clouds/gce.py /usr/lib/python2.7/dist-packages/salt/cloud/clouds/gce.py
16
17 # set up root
18 mkdir /root/.gsutil
19 echo 1391212799 > /root/.gsutil/.last_software_update_check
20 gsutil cp gs://5ej/saltconf/root-ssh/goo* /root/.ssh
21 chmod 600 /root/.ssh/google_compute_engine
22
23 # copy salt config/srv files
24 gsutil cp -Rp gs://5ej/saltconf/etc /
25 gsutil cp -Rp gs://5ej/saltconf/srv /
26 fi
Compute Engine provider configuration
1 zone1a:
2 minion:
3 master: salt
4 image: debian-7
5 size: n1-standard-1
6 location: us-central1-a
7 make_master: False
8 deploy: True
9 delete_boot_pd: True
10 tags: '["minion", "salt", "z1a"]'
11 provider: gce-config
12
13 zone1b:
14 minion:
15 master: salt
16 image: debian-7
17 size: n1-standard-1
18 location: us-central1-b
19 make_master: False
20 deploy: True
21 delete_boot_pd: True
22 tags: '["minion", "salt", "z1b"]'
23 provider: gce-config
/etc/salt/cloud.profiles
/etc/salt/cloud1 providers:
2 gce-config:
3 project: 'google.com:erjohnso'
4 service_account_email_address: '...@developer.gserviceaccount.com'
5 service_account_private_key: '/etc/salt/pkey.pem'
6 provider: gce
/etc/salt/demo.map1 zone1a:
2 - minion1
3 - minion3
4 zone1b:
5 - minion2
6 - minion4
Available now and more coming!
• Standard salt-cloud compatibility
• Create, destroy instances
• --list-sizes, --list-images, --list-locations
• --show_instance myinstance
Available
Now!!
Coming
Soon!!
• Plus... Persistent Disks and Snapshots
• create_disk, delete_disk, show_disk, attach_disk, detach_disk
• create_snapshot, delete_snapshot, show_snapshot
• Plus... Networks and Firewall Rules
• create_network, delete_network, show_network
• create_fwrule, delete_fwrule, show_fwrule
• Plus... Load-balancer and HTTP Health Checks
• create_lb, delete_lb, show_lb, lb_attach, lb_detach
cloud.google.com
Google Compute Engine: https://cloud.google.com/products/compute-engine
Salt + Compute Engine: http://salt.readthedocs.org/en/latest/topics/cloud/gce.html

More Related Content

PDF
Building Docker images with Puppet
PDF
[오픈소스컨설팅] EFK Stack 소개와 설치 방법
PDF
Red Hat Satellite 6 - Automation with Puppet
PDF
Automating the Network
PDF
Weird things we've seen with OpenStack Neutron
PDF
제4회 한국IBM과 함께하는 난공불락 오픈소스 인프라 세미나-Ranchers
PPTX
Automating aws infrastructure and code deployments using Ansible @WebEngage
PDF
PuppetConf 2016: An Introduction to Measuring and Tuning PE Performance – Cha...
Building Docker images with Puppet
[오픈소스컨설팅] EFK Stack 소개와 설치 방법
Red Hat Satellite 6 - Automation with Puppet
Automating the Network
Weird things we've seen with OpenStack Neutron
제4회 한국IBM과 함께하는 난공불락 오픈소스 인프라 세미나-Ranchers
Automating aws infrastructure and code deployments using Ansible @WebEngage
PuppetConf 2016: An Introduction to Measuring and Tuning PE Performance – Cha...

What's hot (20)

PDF
Ansible best practices
PPTX
Vagrant, Ansible, and OpenStack on your laptop
PPT
Python Deployment with Fabric
PDF
Introduction to ansible galaxy
PDF
Arnold Bechtoldt, Inovex GmbH Linux systems engineer - Configuration Manageme...
PDF
DevOps for Humans - Ansible for Drupal Deployment Victory!
PDF
StackiFest16: What's Next in Stacki - Mason Katz
PDF
Getting started with puppet and vagrant (1)
PPTX
Openstack study-nova-02
PDF
Kube-AWS
PPTX
Cyansible
PDF
openstack源码分析(1)
PDF
docker build with Ansible
PPTX
Docker ansible-make-chef-puppet-unnecessary-minnihan
PDF
Docker at Shopify: From This-Looks-Fun to Production by Simon Eskildsen (Shop...
PDF
Managing Your Cisco Datacenter Network with Ansible
PDF
Chef Provisioning a Chef Server Cluster - ChefConf 2015
PPTX
So I Wrote a Manifest
PDF
StackiFest16: Stacki 1600+ Server Journey - Dave Peterson, Salesforce
PPT
Hadoop on ec2
Ansible best practices
Vagrant, Ansible, and OpenStack on your laptop
Python Deployment with Fabric
Introduction to ansible galaxy
Arnold Bechtoldt, Inovex GmbH Linux systems engineer - Configuration Manageme...
DevOps for Humans - Ansible for Drupal Deployment Victory!
StackiFest16: What's Next in Stacki - Mason Katz
Getting started with puppet and vagrant (1)
Openstack study-nova-02
Kube-AWS
Cyansible
openstack源码分析(1)
docker build with Ansible
Docker ansible-make-chef-puppet-unnecessary-minnihan
Docker at Shopify: From This-Looks-Fun to Production by Simon Eskildsen (Shop...
Managing Your Cisco Datacenter Network with Ansible
Chef Provisioning a Chef Server Cluster - ChefConf 2015
So I Wrote a Manifest
StackiFest16: Stacki 1600+ Server Journey - Dave Peterson, Salesforce
Hadoop on ec2
Ad

Similar to SaltConf14 - Eric johnson, Google - Orchestrating Google Compute Engine with SaltStack (20)

PDF
How to Puppetize Google Cloud Platform - PuppetConf 2014
PDF
FIWARE Wednesday Webinars - Short Term History within Smart Systems
PDF
Integrating ChatGPT with Apache Airflow
PDF
Cloud Native Use Cases / Case Studies - KubeCon 2019 San Diego - RECAP
PDF
DSLing your System For Scalability Testing Using Gatling - Dublin Scala User ...
PDF
Testing kubernetes and_open_shift_at_scale_20170209
PDF
SCM Puppet: from an intro to the scaling
PDF
PuppetConf 2017: Kubernetes in the Cloud w/ Puppet + Google Container Engine-...
PDF
Containers > VMs
PPTX
Salting new ground one man ops from scratch
PDF
Kubernetes for java developers - Tutorial at Oracle Code One 2018
PPTX
Cloud Foundry V2 | Intermediate Deep Dive
PPTX
Flexible compute
PPTX
Sanger, upcoming Openstack for Bio-informaticians
PDF
Docker Monitoring Webinar
PDF
Docker Logging and analysing with Elastic Stack
PDF
Docker Logging and analysing with Elastic Stack - Jakub Hajek
PDF
2014 11-05 hpcac-kniep_christian_dockermpi
PDF
Ignacy Kowalczyk
PDF
Get Your Head in the Cloud - Lessons in GPU Computing with Schlumberger
How to Puppetize Google Cloud Platform - PuppetConf 2014
FIWARE Wednesday Webinars - Short Term History within Smart Systems
Integrating ChatGPT with Apache Airflow
Cloud Native Use Cases / Case Studies - KubeCon 2019 San Diego - RECAP
DSLing your System For Scalability Testing Using Gatling - Dublin Scala User ...
Testing kubernetes and_open_shift_at_scale_20170209
SCM Puppet: from an intro to the scaling
PuppetConf 2017: Kubernetes in the Cloud w/ Puppet + Google Container Engine-...
Containers > VMs
Salting new ground one man ops from scratch
Kubernetes for java developers - Tutorial at Oracle Code One 2018
Cloud Foundry V2 | Intermediate Deep Dive
Flexible compute
Sanger, upcoming Openstack for Bio-informaticians
Docker Monitoring Webinar
Docker Logging and analysing with Elastic Stack
Docker Logging and analysing with Elastic Stack - Jakub Hajek
2014 11-05 hpcac-kniep_christian_dockermpi
Ignacy Kowalczyk
Get Your Head in the Cloud - Lessons in GPU Computing with Schlumberger
Ad

More from SaltStack (20)

PPTX
Integration testing for salt states using aws ec2 container service
PDF
Spot Trading - A case study in continuous delivery for mission critical finan...
PDF
SaltConf14 - Craig Sebenik, LinkedIn - SaltStack at Web Scale
PDF
Salt Air 19 - Intro to SaltStack RAET (reliable asyncronous event transport)
PDF
SaltConf14 - Matthew Williams, Flowroute - Salt Virt for Linux contatiners an...
PDF
Configuration Management - Finding the tool to fit your needs
PPT
SaltConf14 - Ben Cane - Using SaltStack in High Availability Environments
PPT
SaltConf14 - Oz Akan, Rackspace - Deploying OpenStack Marconi with SaltStack
PDF
SaltConf14 - Yazz Atlas, HP Cloud - Installing OpenStack using SaltStack
PDF
SaltConf14 - Anita Kuno, HP & OpenStack - Using SaltStack for event-driven or...
PPT
SaltConf14 - Saurabh Surana, HP Cloud - Automating operations and support wit...
PDF
SaltConf14 - Ryan Lane, Wikimedia - Immediate consistency with Trebuchet Depl...
PDF
SaltConf14 - Forrest Alvarez, Choice Hotels - Salt Formulas and States
PPT
SaltConf14 - Brendan Burns, Google - Management at Google Scale
PDF
SaltConf14 - Justin Carmony, Deseret Digital Media - Teaching Devs About DevOps
PPTX
SaltConf14 - Thomas Jackson, LinkedIn - Safety with Power Tools
PDF
SaltStack - An open source software story
PDF
Real-time Cloud Management with SaltStack
PDF
A user's perspective on SaltStack and other configuration management tools
PDF
Adding to your Python Armory - OpenWest 2013
Integration testing for salt states using aws ec2 container service
Spot Trading - A case study in continuous delivery for mission critical finan...
SaltConf14 - Craig Sebenik, LinkedIn - SaltStack at Web Scale
Salt Air 19 - Intro to SaltStack RAET (reliable asyncronous event transport)
SaltConf14 - Matthew Williams, Flowroute - Salt Virt for Linux contatiners an...
Configuration Management - Finding the tool to fit your needs
SaltConf14 - Ben Cane - Using SaltStack in High Availability Environments
SaltConf14 - Oz Akan, Rackspace - Deploying OpenStack Marconi with SaltStack
SaltConf14 - Yazz Atlas, HP Cloud - Installing OpenStack using SaltStack
SaltConf14 - Anita Kuno, HP & OpenStack - Using SaltStack for event-driven or...
SaltConf14 - Saurabh Surana, HP Cloud - Automating operations and support wit...
SaltConf14 - Ryan Lane, Wikimedia - Immediate consistency with Trebuchet Depl...
SaltConf14 - Forrest Alvarez, Choice Hotels - Salt Formulas and States
SaltConf14 - Brendan Burns, Google - Management at Google Scale
SaltConf14 - Justin Carmony, Deseret Digital Media - Teaching Devs About DevOps
SaltConf14 - Thomas Jackson, LinkedIn - Safety with Power Tools
SaltStack - An open source software story
Real-time Cloud Management with SaltStack
A user's perspective on SaltStack and other configuration management tools
Adding to your Python Armory - OpenWest 2013

Recently uploaded (20)

PDF
Building Integrated photovoltaic BIPV_UPV.pdf
PDF
gpt5_lecture_notes_comprehensive_20250812015547.pdf
PPTX
Tartificialntelligence_presentation.pptx
PDF
Unlocking AI with Model Context Protocol (MCP)
PDF
Transform Your ITIL® 4 & ITSM Strategy with AI in 2025.pdf
PDF
Assigned Numbers - 2025 - Bluetooth® Document
PPTX
Programs and apps: productivity, graphics, security and other tools
PPTX
OMC Textile Division Presentation 2021.pptx
PDF
DASA ADMISSION 2024_FirstRound_FirstRank_LastRank.pdf
PDF
Encapsulation_ Review paper, used for researhc scholars
PDF
NewMind AI Weekly Chronicles - August'25-Week II
PDF
Accuracy of neural networks in brain wave diagnosis of schizophrenia
PPTX
cloud_computing_Infrastucture_as_cloud_p
PDF
7 ChatGPT Prompts to Help You Define Your Ideal Customer Profile.pdf
PDF
Mushroom cultivation and it's methods.pdf
PDF
Heart disease approach using modified random forest and particle swarm optimi...
PDF
Microsoft Solutions Partner Drive Digital Transformation with D365.pdf
PPTX
1. Introduction to Computer Programming.pptx
PDF
Hindi spoken digit analysis for native and non-native speakers
PDF
Profit Center Accounting in SAP S/4HANA, S4F28 Col11
Building Integrated photovoltaic BIPV_UPV.pdf
gpt5_lecture_notes_comprehensive_20250812015547.pdf
Tartificialntelligence_presentation.pptx
Unlocking AI with Model Context Protocol (MCP)
Transform Your ITIL® 4 & ITSM Strategy with AI in 2025.pdf
Assigned Numbers - 2025 - Bluetooth® Document
Programs and apps: productivity, graphics, security and other tools
OMC Textile Division Presentation 2021.pptx
DASA ADMISSION 2024_FirstRound_FirstRank_LastRank.pdf
Encapsulation_ Review paper, used for researhc scholars
NewMind AI Weekly Chronicles - August'25-Week II
Accuracy of neural networks in brain wave diagnosis of schizophrenia
cloud_computing_Infrastucture_as_cloud_p
7 ChatGPT Prompts to Help You Define Your Ideal Customer Profile.pdf
Mushroom cultivation and it's methods.pdf
Heart disease approach using modified random forest and particle swarm optimi...
Microsoft Solutions Partner Drive Digital Transformation with D365.pdf
1. Introduction to Computer Programming.pptx
Hindi spoken digit analysis for native and non-native speakers
Profit Center Accounting in SAP S/4HANA, S4F28 Col11

SaltConf14 - Eric johnson, Google - Orchestrating Google Compute Engine with SaltStack

  • 1. SaltStack and Google Compute Engine Eric Johnson Technical Program Manager
  • 2. Agenda: January 30th, 2014 Whirlwind Tour of Google Cloud Platform Google Compute Engine Using SaltStack and Compute Engine (demo) 1 2 3
  • 3. Whirlwind Tour of Google Cloud Platform Google Compute Engine Using SaltStack and Compute Engine (demo) 1 2 3
  • 4. For the past 15 years, Google has been building out the world’s fastest, most powerful, highest quality cloud infrastructure on the planet. Images by Connie Zhou Why Google Cloud Platform?
  • 5. A Network that Spans the Globe
  • 6. Innovating Software & Driving Technology Forward SpannerDremelMapReduce Big Table Colossus 2012 20132002 2004 2006 2008 2010 GFS Compute Engine
  • 7. Building Products that Scale Google Maps Gmail Google Drive YouTube
  • 8. “[Google's] ability to build, organize, and operate a huge network of servers and fiber- optic cables with an efficiency and speed that rocks physics on its heels. This is what makes Google Google: its physical network, its thousands of fiber miles, and those many thousands of servers that, in aggregate, add up to the mother of all clouds.” - Wired Images by Connie Zhou
  • 9. Storage Cloud Storage Cloud SQL Cloud Datastore Compute Compute Engine App Engine App Services BigQuery Cloud Endpoints Google Cloud Platform
  • 10. Compute Compute Engine App Engine Storage Cloud Storage Cloud SQL Cloud Datastore App Services BigQuery Cloud Endpoints Power Computation
  • 11. Storage Cloud Storage Cloud SQL Cloud Datastore Storing What You Want, However You Want Compute Compute Engine App Engine App Services BigQuery Cloud Endpoints
  • 12. App Services BigQuery Cloud Endpoints Building Robust, Intelligent Systems Storage Cloud Storage Cloud SQL Cloud Datastore Compute Compute Engine App Engine
  • 13. Whirlwind Tour of Google Cloud Platform Google Compute Engine Using SaltStack and Compute Engine (demo) 1 2 3
  • 14. • IaaS: VMs, Network, Storage • Google DNA (speed, scale, reliable, secure) • Fast Provisioning, Consistent Performance • Enterprise Ready • 24x7 Support • 99.95% monthly SLA • ISO 27001, SSAE-16 SOC 1,2,3 • Accessible Through • Web @ https://cloud.google.com/console • gcutil command-line utility • REST API • Partners (Commercial and FOSS) Google Compute Engine
  • 17. Persistent Disk 10 TB • Data and root partitions • Billed only by capacity (GB/month) • Performance caps scale linearly with size • Volume striping is automatic • Differential snapshots • Create new PDs based on snapshots
  • 18. PD Use-cases Root Stateful root volume User managed data volume Root RW Data RO Data Instant distribution of static content
  • 19. Global Snapshot and Restore GCS vol1 vol2 vol3 vol1. t2 vol2. t2 vol3. t3 t1 t1 t1 t1 t1 t1 t1 t1 t1 t1 t1 t1 t1 t2 t2 t2 t2 t3 t3 t3 ● Point in time snapshot to Google Cloud Storage (GCS) ● Differential snapshots ● GCS global replication! ● Restore from snapshot anywhere in the world us-central1-a europe-west1-a
  • 21. standard • For workloads with balanced CPU and memory highmem • For workloads with higher memory requirements highcpu • For workloads with higher CPU requirements Shared Core Instances • For inexpensive prototyping and staging workloads (g1-small, f1-micro) Machine Types Machine Type Virtual Cores Memory (GB) n1-standard-1 1 3.75 n1-standard-2 2 7.50 n1-standard-4 4 15.00 n1-standard-8 8 30.00 n1-standard-16 16 60.00 n1-highmem-2 2 13.00 n1-highmem-4 4 26.00 n1-highmem-8 8 52.00 n1-highmem-16 16 104.00 n1-highcpu-2 2 1.80 n1-highcpu-4 4 3.60 n1-highcpu-8 8 7.20 n1-highcpu-16 16 14.40
  • 22. Images + Custom Kernel Support (debian backports works great for docker)
  • 23. Sub-hour Billing 1 minute granularity 10 minute minimum
  • 24. Enhanced Reliability us-central1-a scheduled maintenance event Live Migration • No downtime during scheduled datacenter maintenance events Automatic Restart • Instances automatically restarted if subjected to system events such as hardware failure
  • 26. Images by Connie Zhou Networking • Google's Network • Projects are isolated private networks • TCP, UDP, ICMP only • Multiple private network groups and firewalls • Tags and address ranges • Addresses • public: static or ephemeral • private: ephemeral with DNS • Routes, gateways, VPNs, and IP Forwarding
  • 27. Region: us-central1 Target Pool (tp-a) Load-balancer • Region based • Session affinity • Hashed on src ip:port and dst ip:port • Consists of: • Target pool: collection of instances • Forwarding rules: protocol:port, pool • HTTP health check: optional us-central1-b us-central1-a www0 www1 www2 www3 Forwarding Rules tcp:443 ➔ tp-a tcp:80 ➔ tp-a Internet http://googlecloudplatform.blogspot.com/2013/11/compute-engine-load-balancing-hits-1-million-requests-per-second.html
  • 29. Noteworthy • Metadata • Startup scripts • SSH Keys • Tags (instance/network) • OAuth2 and Scopes • Access other Google Cloud Platform services • Ecosystem is growing • Partners: RightScale, Scalr, New Relic, MongoLab, MapR, and many more... • Open Source: Salt, Chef, Puppet, Ansible, Vagrant, Docker, CoreOS, fog, libcloud
  • 30. Whirlwind Tour of Google Cloud Platform Google Compute Engine Using SaltStack and Compute Engine (demo) 1 2 3
  • 31. Start to finish 1. Use the Developers Console to create the salt master (metadata: saltdemo=yup) salt This is a Compute Engine instance named "salt"
  • 32. Start to finish 1. Use the Developers Console to create the salt-master (metadata: saltdemo=yup) 2. Use salt-cloud to create 4 instances (2 per zone), install apache us-central1-a minion1 minion3 us-central1-b minion2 minion4 salt # salt-cloud -P -m /etc/salt/demo.map # salt 'minion*' state.highstate GooglePublicAPI
  • 33. Start to finish 1. Use the Developers Console to create the salt-master (metadata: saltdemo=yup) 2. Use salt-cloud to create 4 instances (2 per zone) 3. Use salt-cloud networking functions Region: us-central1 Target Pool (lb-tp) us-central1-a minion1 minion3 us-central1-b minion2 minion4 Forwarding Rules tcp:80 ➔ lb-tp PublicLBIP:a.b.c.d salt # salt-cloud -f create_fwrule gce ... # salt-cloud -f create_lb gce ...
  • 34. Start to finish 1. Use the Developers Console to create the salt-master (metadata: saltdemo=yup) 2. Use salt-cloud to create 4 instances (2 per zone) 3. Use salt-cloud networking functions 4. Generate some HTTP requests to LB IP Region: us-central1 Target Pool (lb-tp) us-central1-a minion1 minion3 us-central1-b minion2 minion4 Forwarding Rules tcp:80 ➔ lb-tp PublicLBIP:a.b.c.d Internet dst port 80 salt
  • 35. The salt master via custom "startup-script" metadata startup-script1 #!/bin/bash 2 3 SALT=$(curl -s http://metadata/computeMetadata/v1beta1/instance/attributes/saltdemo) 4 5 if [ "$SALT" = "yup" ]; then 6 # update and install dependencies (libcloud 0.14.0 + bugfix) 7 apt-get install vim tmux git python-pip -y 8 pip install git+https://github.com/apache/libcloud@58f3722ba54dc79cc9ef40271f6a3d39d6e8841d 9 10 # salt master 11 curl -L http://bootstrap.saltstack.org | sudo sh -s -- -M -N git v2014.1.0rc3 12 13 # dev gce provider 14 git clone https://github.com/erjohnso/salt 15 cp salt/salt/cloud/clouds/gce.py /usr/lib/python2.7/dist-packages/salt/cloud/clouds/gce.py 16 17 # set up root 18 mkdir /root/.gsutil 19 echo 1391212799 > /root/.gsutil/.last_software_update_check 20 gsutil cp gs://5ej/saltconf/root-ssh/goo* /root/.ssh 21 chmod 600 /root/.ssh/google_compute_engine 22 23 # copy salt config/srv files 24 gsutil cp -Rp gs://5ej/saltconf/etc / 25 gsutil cp -Rp gs://5ej/saltconf/srv / 26 fi
  • 36. Compute Engine provider configuration 1 zone1a: 2 minion: 3 master: salt 4 image: debian-7 5 size: n1-standard-1 6 location: us-central1-a 7 make_master: False 8 deploy: True 9 delete_boot_pd: True 10 tags: '["minion", "salt", "z1a"]' 11 provider: gce-config 12 13 zone1b: 14 minion: 15 master: salt 16 image: debian-7 17 size: n1-standard-1 18 location: us-central1-b 19 make_master: False 20 deploy: True 21 delete_boot_pd: True 22 tags: '["minion", "salt", "z1b"]' 23 provider: gce-config /etc/salt/cloud.profiles /etc/salt/cloud1 providers: 2 gce-config: 3 project: 'google.com:erjohnso' 4 service_account_email_address: '...@developer.gserviceaccount.com' 5 service_account_private_key: '/etc/salt/pkey.pem' 6 provider: gce /etc/salt/demo.map1 zone1a: 2 - minion1 3 - minion3 4 zone1b: 5 - minion2 6 - minion4
  • 37. Available now and more coming! • Standard salt-cloud compatibility • Create, destroy instances • --list-sizes, --list-images, --list-locations • --show_instance myinstance Available Now!! Coming Soon!! • Plus... Persistent Disks and Snapshots • create_disk, delete_disk, show_disk, attach_disk, detach_disk • create_snapshot, delete_snapshot, show_snapshot • Plus... Networks and Firewall Rules • create_network, delete_network, show_network • create_fwrule, delete_fwrule, show_fwrule • Plus... Load-balancer and HTTP Health Checks • create_lb, delete_lb, show_lb, lb_attach, lb_detach
  • 38. cloud.google.com Google Compute Engine: https://cloud.google.com/products/compute-engine Salt + Compute Engine: http://salt.readthedocs.org/en/latest/topics/cloud/gce.html