SlideShare a Scribd company logo
Automated Application Management
with SaltStack
Arnold Bechtoldt
Cologne, 08.06.2016
Arnold Bechtoldt
Systems Engineer / Consultant @ inovex
〉 Software-Defined Datacenters
〉 Continuous Integration/Delivery
〉 DevOps
2
Assets & Links
3
inovex.de arnoldbechtoldt.comgithub.com/bechtoldt/talk-salt-orchestration
Orchestration in General
Highway To Heaven
5
Asset-
Management,
Accounting
Bare-Metal
Deployment
Configuration
Management/
Containerization
Orchestration
Auto-Scaling +
Elasticity
Cloud
〉 ... uses remote execution to distribute system commands
〉 ... should be more than just executing commands (most of the tools end here)
〉 ... should be able to respect internal & external dependencies/relations
〉 ... should be deterministic and fast
〉 ... must [RFC2119] be easy to understand/learn (YMMV)
Orchestration...
6
7
MCollective + Shell Script
A not-so-cool Example
http://www.ansible.com/blog/orchestration-you-keep-using-that-word
For instance, if you use a single-purpose deployment
tool [...] to trigger some legacy configuration
management, that might be called “orchestrating X
with Y”. In reality, it’s usually just replacing a non-
scaling [...] server solution X with a stand-alone
implementation of Y.
8
SaltStack Orchestration Basics
SaltStack implements the same techiniques that other tools do:
〉 send commands to servers
〉 send commands to servers that have different operating systems
〉 send commands only to a subset of servers
〉 run command A, then B, then C
Often this isn’t enough for us!
SaltStack Orchestration
10
What we really want to have:
〉 scale accross thousands of servers
〉 easy configuration (less software programming)
〉 an interface to implement internal/external relationships (pre/post
tasks)
〉 fully automated workflows/procedures (no manual interaction)
SaltStack Orchestration
11
What we really want to have:
〉 scale accross thousands of servers
SOA – Message Bus Architecture
〉 easy configuration (less software programming)
YAML – JSON – Python DSL
〉 an interface to implement internal/external relationships (pre/post
tasks)
State – Remote Execution – Pillar – Returner – Beacon – Cloud (~ 600 modules)
〉 fully automated workflows/procedures (no manual interaction)
Event System – Reactor – Runner – APIs
SaltStack Orchestration
12
Salt Peer-Publish: Realtime Execution
13
minionminion
minion
minion
minion
master
minion
minion
minion
minion
minion
〉 Peer-2-Peer like
〉 Privilege management on master-side
〉 Synchronous & blocking
Use Cases:
〉 Gathering realtime metrics of other systems (minions)
〉 Automatically-triggered remote execution
Salt Peer-Publish: Realtime Execution
14
Salt Mine: Dynamic Runtime Data Cache
15
minionminion
minion
minion
minion
mine
(master)
minion
minion
minion
minion
minion
minion
〉 Caching arbitrary data/metrics
〉 Replaces slow/expensive peer public calls
Use Cases:
〉 Gathering backend addresses for LB config
〉 Gathering SSH public keys (host/user) of other other hosts
〉 Asynchronous collecting of metrics for monitoring
Salt Mine: Dynamic Runtime Data Cache
16
Salt Reactor: Event-Driven System Automation
17
minion
minion minion
minionminion
minion
minion
minion
minion
minionminion
reactor
(master)
salt/key salt/job/new node/stonith/new update/application
salt/auth salt/job/return scale/out loadbalancer/config/update
salt/minion/start salt/presence/present monitoring/hosts/new firewall/config/update
salt/minion/stop salt/presence/change monitoring/hosts/remove coffee/new
Event-Driven System Automation
18
minion
minion
minion
minion minion
minionmaster
MySQL
Foreman etcd
MySQL
ElasticsearchSMTP
Syslog Icinga
Appliances
HTTP
Docker
Slack
PostgreSQLminion AWS
〉 Automated cfg mgmt and remote execution across several hosts
〉 „Real Orchestration“
〉 Asynchronous
〉 Synchronous/blocking alternative: Orchestration Runner
Use Cases:
〉 Automated loadbalancer configuration updates
〉 Automated host bootstrapping and software provisioning
Salt Reactor: Event-Driven System Automation
19
salt/job/20151104191820394966/new {
"_stamp": "2015-11-04T18:18:20.512126",
"arg": [
”orchestration.bootstrap",
{
"__kwarg__": true,
"test": false
}
],
"fun": "state.sls",
"jid": "20151104191820394966",
"minions": [
”mw42"
],
"tgt": ”mw42",
"tgt_type": "glob",
"user": ”root”
}
Event Structure
20
custom/minion/haste_server_started {
"_stamp": "2015-11-04T18:33:54.650568",
"cmd": "_minion_event",
"data": {
”custom": {
"onchanges": [],
 "foo": "bar",
 "num": 42,
},
"sfun": "wait"
},
"id": "mw2",
"pretag": null,
"tag": "custom/minion/haste_server_started"
}
State A resource should look like {…}
Pillar Database/CMDB (Files, RDBMS, NoSQL)
Execution Execute command X on a server. Used by
other Salt components.
Returner Log store of job results (DB, Elasticsearch,
Syslog, Monitoring)
Beacon Special event triggers (inotify, load, procs,
network/user activity)
Reactor Reacts to events by triggering subsequent
procedures (execution modules)
Cloud IaaS provisioning (EC2, OpenStack, Digital
Ocean, Linode, GCE, VMware)
…
SaltStack Terminology
21
Hands on: Demo
Demo Architecture
23
db
(Redis)
mw
(NodeJS)
fe
(HAProxy)
fe
(HAProxy)
fe
(HAProxy) mw
(NodeJS)
mw
(NodeJS)
mw
(NodeJS)
mw
(NodeJS)
Demo Concept
24
1. Tells MW hosts to install MW
4. Tells FE hosts to install FE
6. Tells MW hosts to deploy App
10. Tells FE to reconfigure FE
2. Install Node.JS (MW)
3. Report back to Master
7. Deploy App
8. Send Notification Mail
9. Report back to Master
5. Install Haproxy (FE)
6. Report back to Master
11. Add/Remove HAProxy backends
12. Report back to Master
Salt Master/Reactor MW hosts FE hosts
Demo Concept
25
1. Tells MW hosts to install MW
4. Tells FE hosts to install FE
6. Tells MW hosts to deploy App
10. Tells FE to reconfigure FE
2. Install Node.JS (MW)
3. Report back to Master
7. Deploy App
8. Send Notification Mail
9. Report back to Master
5. Install Haproxy (FE)
6. Report back to Master
11. Add/Remove HAProxy backends
12. Report back to Master
Salt Master/Reactor MW hosts FE hosts
Assets & Links
26
sh.arbe.io/cloud-provision youtu.be/9MzeK4u4pkM (demo)github.com/bechtoldt/talk-salt-orchestration
Q&A
Arnold Bechtoldt
inovex GmbH
abechtoldt@inovex.de
CC BY-NC-ND inovex.de +ArnoldBechtoldtGER
github.com/bechtoldt arbe.io youtube.com/inovexGmbH

More Related Content

What's hot (20)

PDF
Cloud Native Microservices with Spring Cloud
Conor Svensson
 
PDF
DSLing your System For Scalability Testing Using Gatling - Dublin Scala User ...
Aman Kohli
 
PDF
[OpenInfra Days Korea 2018] Day 2 - E3-2: "핸즈온 워크샵: Kubespray, Helm, Armada를 ...
OpenStack Korea Community
 
PDF
Monitoring of OpenNebula installations
NETWAYS
 
PDF
Cloud Native User Group: Prometheus Day 2
smalltown
 
PDF
Wordpress y Docker, de desarrollo a produccion
Sysdig
 
PDF
Load Balancing in the Cloud using Nginx & Kubernetes
Lee Calcote
 
PDF
Data(?)Ops with CircleCI
Jinwoong Kim
 
PPTX
Moving to Nova Cells without Destroying the World
Mike Dorman
 
PDF
Bulding a reactive game engine with Spring 5 & Couchbase
Alex Derkach
 
PDF
KubeCon EU 2016: A Practical Guide to Container Scheduling
KubeAcademy
 
PDF
AWS re:Invent re:Cap 2019: My ElasticSearch Journey on AWS
smalltown
 
PDF
Kubernetes intro public - kubernetes meetup 4-21-2015
Rohit Jnagal
 
PDF
WebCamp 2016: DevOps. Николай Дойков: Опыт создания клауда для потокового вид...
WebCamp
 
PDF
[OpenInfra Days Korea 2018] Day 1 - T4-7: "Ceph 스토리지, PaaS로 서비스 운영하기"
OpenStack Korea Community
 
PDF
Storing 16 Bytes at Scale
Fabian Reinartz
 
PDF
[오픈소스컨설팅] EFK Stack 소개와 설치 방법
Open Source Consulting
 
PDF
Kubernetes Summit 2019 - Harden Your Kubernetes Cluster
smalltown
 
PDF
Elk for applications on k8s
Che-Chia Chang
 
PDF
AgileTW Feat. DevOpsTW: 維運 Kubernetes 的兩三事
smalltown
 
Cloud Native Microservices with Spring Cloud
Conor Svensson
 
DSLing your System For Scalability Testing Using Gatling - Dublin Scala User ...
Aman Kohli
 
[OpenInfra Days Korea 2018] Day 2 - E3-2: "핸즈온 워크샵: Kubespray, Helm, Armada를 ...
OpenStack Korea Community
 
Monitoring of OpenNebula installations
NETWAYS
 
Cloud Native User Group: Prometheus Day 2
smalltown
 
Wordpress y Docker, de desarrollo a produccion
Sysdig
 
Load Balancing in the Cloud using Nginx & Kubernetes
Lee Calcote
 
Data(?)Ops with CircleCI
Jinwoong Kim
 
Moving to Nova Cells without Destroying the World
Mike Dorman
 
Bulding a reactive game engine with Spring 5 & Couchbase
Alex Derkach
 
KubeCon EU 2016: A Practical Guide to Container Scheduling
KubeAcademy
 
AWS re:Invent re:Cap 2019: My ElasticSearch Journey on AWS
smalltown
 
Kubernetes intro public - kubernetes meetup 4-21-2015
Rohit Jnagal
 
WebCamp 2016: DevOps. Николай Дойков: Опыт создания клауда для потокового вид...
WebCamp
 
[OpenInfra Days Korea 2018] Day 1 - T4-7: "Ceph 스토리지, PaaS로 서비스 운영하기"
OpenStack Korea Community
 
Storing 16 Bytes at Scale
Fabian Reinartz
 
[오픈소스컨설팅] EFK Stack 소개와 설치 방법
Open Source Consulting
 
Kubernetes Summit 2019 - Harden Your Kubernetes Cluster
smalltown
 
Elk for applications on k8s
Che-Chia Chang
 
AgileTW Feat. DevOpsTW: 維運 Kubernetes 的兩三事
smalltown
 

Viewers also liked (20)

PDF
SysDig Metriken zentralisieren
inovex GmbH
 
PDF
Intelligent infrastructure with SaltStack
Love Nyberg
 
PDF
Cloud Wars – what‘s the smartest data platform? Vergleich Microsoft Azure, Am...
inovex GmbH
 
PDF
Prometheus Monitoring
inovex GmbH
 
PDF
Datenprodukte für Deutschlands größten Fahrzeugmarkt
inovex GmbH
 
PDF
Cooking 5 Star Infrastructure with Chef
G. Ryan Fawcett
 
PDF
Bootstrapping Forman with Vagrant - Setting up a local Provision & Deployment...
inovex GmbH
 
PDF
Sysdig
gnosek
 
PPTX
Introduction to Ansible - Jan 28 - Austin MeetUp
tylerturk
 
PDF
StackiFest16: Automation for Event-Driven Infrastructure - Dave Boucha
StackIQ
 
PDF
Arnold Bechtoldt, Inovex GmbH Linux systems engineer - Configuration Manageme...
SaltStack
 
PDF
Configuration Management vs. Container Automation
inovex GmbH
 
PDF
Die dunkle Seite der Microservices - und wie du sie besiegen kannst
inovex GmbH
 
PDF
Erfolgsfaktoren von Datenprodukten
inovex GmbH
 
PDF
Dockerized Microservices
inovex GmbH
 
PDF
Gitlab meets Kubernetes
inovex GmbH
 
PPTX
Container Monitoring with Sysdig
Sreenivas Makam
 
PDF
Microservices under the microscope
Ross Garrett
 
PDF
Microservices, geerdet
inovex GmbH
 
PDF
Advanced Cojure Microservices
inovex GmbH
 
SysDig Metriken zentralisieren
inovex GmbH
 
Intelligent infrastructure with SaltStack
Love Nyberg
 
Cloud Wars – what‘s the smartest data platform? Vergleich Microsoft Azure, Am...
inovex GmbH
 
Prometheus Monitoring
inovex GmbH
 
Datenprodukte für Deutschlands größten Fahrzeugmarkt
inovex GmbH
 
Cooking 5 Star Infrastructure with Chef
G. Ryan Fawcett
 
Bootstrapping Forman with Vagrant - Setting up a local Provision & Deployment...
inovex GmbH
 
Sysdig
gnosek
 
Introduction to Ansible - Jan 28 - Austin MeetUp
tylerturk
 
StackiFest16: Automation for Event-Driven Infrastructure - Dave Boucha
StackIQ
 
Arnold Bechtoldt, Inovex GmbH Linux systems engineer - Configuration Manageme...
SaltStack
 
Configuration Management vs. Container Automation
inovex GmbH
 
Die dunkle Seite der Microservices - und wie du sie besiegen kannst
inovex GmbH
 
Erfolgsfaktoren von Datenprodukten
inovex GmbH
 
Dockerized Microservices
inovex GmbH
 
Gitlab meets Kubernetes
inovex GmbH
 
Container Monitoring with Sysdig
Sreenivas Makam
 
Microservices under the microscope
Ross Garrett
 
Microservices, geerdet
inovex GmbH
 
Advanced Cojure Microservices
inovex GmbH
 
Ad

Similar to Automated Application Management with SaltStack (20)

PDF
Saltstack - Orchestration & Application Deployment
inovex GmbH
 
PDF
Why SaltStack ?
SUSE
 
PPTX
Salting new ground one man ops from scratch
Jay Harrison
 
PDF
Configuration Management with Saltstack
inovex GmbH
 
PDF
SaltStack - An open source software story
SaltStack
 
PDF
CAPS: What's best for deploying and managing OpenStack? Chef vs. Ansible vs. ...
Daniel Krook
 
PDF
CAPS: What's best for deploying and managing OpenStack? Chef vs. Ansible vs. ...
Animesh Singh
 
PDF
Salt conf 2014 - Using SaltStack in high availability environments
Benjamin Cane
 
PDF
Introduction to SaltStack
Aymen EL Amri
 
PDF
Getting started with salt stack
Suresh Paulraj
 
PDF
Getting started with salt stack
Suresh Paulraj
 
PDF
Spot Trading - A case study in continuous delivery for mission critical finan...
SaltStack
 
PDF
Orchestrate Event-Driven Infrastructure with SaltStack
Love Nyberg
 
PDF
SaltStack – (Not) just another Automation & Remote Execution Tool
inovex GmbH
 
PDF
OpenWest 2014-05-10 Where's the Waldo, SaltStack Proxy Minions
croldham
 
PPT
SaltConf14 - Ben Cane - Using SaltStack in High Availability Environments
SaltStack
 
PDF
OSDC 2016 - Scalable Systems Management with Salt Stack by Sebastian Meyer
NETWAYS
 
PDF
Salt - A Scalable Systems Management Solution for Datacenters
B1 Systems GmbH
 
PDF
ODSC 2016 - Scalable Systems Management with Salt Stack by Sebastian Meyer
NETWAYS
 
PDF
OSDC 2016 | Scalable Systems Management with SaltStack by Sebastian Meyer
NETWAYS
 
Saltstack - Orchestration & Application Deployment
inovex GmbH
 
Why SaltStack ?
SUSE
 
Salting new ground one man ops from scratch
Jay Harrison
 
Configuration Management with Saltstack
inovex GmbH
 
SaltStack - An open source software story
SaltStack
 
CAPS: What's best for deploying and managing OpenStack? Chef vs. Ansible vs. ...
Daniel Krook
 
CAPS: What's best for deploying and managing OpenStack? Chef vs. Ansible vs. ...
Animesh Singh
 
Salt conf 2014 - Using SaltStack in high availability environments
Benjamin Cane
 
Introduction to SaltStack
Aymen EL Amri
 
Getting started with salt stack
Suresh Paulraj
 
Getting started with salt stack
Suresh Paulraj
 
Spot Trading - A case study in continuous delivery for mission critical finan...
SaltStack
 
Orchestrate Event-Driven Infrastructure with SaltStack
Love Nyberg
 
SaltStack – (Not) just another Automation & Remote Execution Tool
inovex GmbH
 
OpenWest 2014-05-10 Where's the Waldo, SaltStack Proxy Minions
croldham
 
SaltConf14 - Ben Cane - Using SaltStack in High Availability Environments
SaltStack
 
OSDC 2016 - Scalable Systems Management with Salt Stack by Sebastian Meyer
NETWAYS
 
Salt - A Scalable Systems Management Solution for Datacenters
B1 Systems GmbH
 
ODSC 2016 - Scalable Systems Management with Salt Stack by Sebastian Meyer
NETWAYS
 
OSDC 2016 | Scalable Systems Management with SaltStack by Sebastian Meyer
NETWAYS
 
Ad

More from inovex GmbH (20)

PDF
lldb – Debugger auf Abwegen
inovex GmbH
 
PDF
Are you sure about that?! Uncertainty Quantification in AI
inovex GmbH
 
PDF
Why natural language is next step in the AI evolution
inovex GmbH
 
PDF
WWDC 2019 Recap
inovex GmbH
 
PDF
Network Policies
inovex GmbH
 
PDF
Interpretable Machine Learning
inovex GmbH
 
PDF
Jenkins X – CI/CD in wolkigen Umgebungen
inovex GmbH
 
PDF
AI auf Edge-Geraeten
inovex GmbH
 
PDF
Prometheus on Kubernetes
inovex GmbH
 
PDF
Deep Learning for Recommender Systems
inovex GmbH
 
PDF
Azure IoT Edge
inovex GmbH
 
PDF
Representation Learning von Zeitreihen
inovex GmbH
 
PDF
Talk to me – Chatbots und digitale Assistenten
inovex GmbH
 
PDF
Künstlich intelligent?
inovex GmbH
 
PDF
Dev + Ops = Go
inovex GmbH
 
PDF
Das Android Open Source Project
inovex GmbH
 
PDF
Machine Learning Interpretability
inovex GmbH
 
PDF
Performance evaluation of GANs in a semisupervised OCR use case
inovex GmbH
 
PDF
People & Products – Lessons learned from the daily IT madness
inovex GmbH
 
PDF
Infrastructure as (real) Code – Manage your K8s resources with Pulumi
inovex GmbH
 
lldb – Debugger auf Abwegen
inovex GmbH
 
Are you sure about that?! Uncertainty Quantification in AI
inovex GmbH
 
Why natural language is next step in the AI evolution
inovex GmbH
 
WWDC 2019 Recap
inovex GmbH
 
Network Policies
inovex GmbH
 
Interpretable Machine Learning
inovex GmbH
 
Jenkins X – CI/CD in wolkigen Umgebungen
inovex GmbH
 
AI auf Edge-Geraeten
inovex GmbH
 
Prometheus on Kubernetes
inovex GmbH
 
Deep Learning for Recommender Systems
inovex GmbH
 
Azure IoT Edge
inovex GmbH
 
Representation Learning von Zeitreihen
inovex GmbH
 
Talk to me – Chatbots und digitale Assistenten
inovex GmbH
 
Künstlich intelligent?
inovex GmbH
 
Dev + Ops = Go
inovex GmbH
 
Das Android Open Source Project
inovex GmbH
 
Machine Learning Interpretability
inovex GmbH
 
Performance evaluation of GANs in a semisupervised OCR use case
inovex GmbH
 
People & Products – Lessons learned from the daily IT madness
inovex GmbH
 
Infrastructure as (real) Code – Manage your K8s resources with Pulumi
inovex GmbH
 

Recently uploaded (20)

PDF
Everything you need to know about pricing & licensing Microsoft 365 Copilot f...
Q-Advise
 
PPTX
Operations Profile SPDX_Update_20250711_Example_05_03.pptx
Shane Coughlan
 
PDF
NSF Converter Simplified: From Complexity to Clarity
Johnsena Crook
 
PDF
Message Level Status (MLS): The Instant Feedback Mechanism for UAE e-Invoicin...
Prachi Desai
 
PDF
Notification System for Construction Logistics Application
Safe Software
 
PDF
Salesforce Experience Cloud Consultant.pdf
VALiNTRY360
 
PDF
Australian Enterprises Need Project Service Automation
Navision India
 
PDF
intro_to_cpp_namespace_robotics_corner.pdf
MohamedSaied877003
 
PPTX
Odoo Migration Services by CandidRoot Solutions
CandidRoot Solutions Private Limited
 
PDF
How to get the licensing right for Microsoft Core Infrastructure Server Suite...
Q-Advise
 
PPTX
iaas vs paas vs saas :choosing your cloud strategy
CloudlayaTechnology
 
PPTX
How Odoo ERP Enhances Operational Visibility Across Your Organization.pptx
pintadoxavier667
 
PDF
IDM Crack with Internet Download Manager 6.42 Build 31 2025?
utfefguu
 
PDF
ESUG 2025: Pharo 13 and Beyond (Stephane Ducasse)
ESUG
 
PPTX
UI5con_2025_Accessibility_Ever_Evolving_
gerganakremenska1
 
PPT
24-BuildingGUIs Complete Materials in Java.ppt
javidmiakhil63
 
PDF
Attendance Management Software in Patna.
Camwel Solution LLP
 
PDF
chapter 5.pdf cyber security and Internet of things
PalakSharma980227
 
PPTX
BB FlashBack Pro 5.61.0.4843 With Crack Free Download
cracked shares
 
PDF
ERP Consulting Services and Solutions by Contetra Pvt Ltd
jayjani123
 
Everything you need to know about pricing & licensing Microsoft 365 Copilot f...
Q-Advise
 
Operations Profile SPDX_Update_20250711_Example_05_03.pptx
Shane Coughlan
 
NSF Converter Simplified: From Complexity to Clarity
Johnsena Crook
 
Message Level Status (MLS): The Instant Feedback Mechanism for UAE e-Invoicin...
Prachi Desai
 
Notification System for Construction Logistics Application
Safe Software
 
Salesforce Experience Cloud Consultant.pdf
VALiNTRY360
 
Australian Enterprises Need Project Service Automation
Navision India
 
intro_to_cpp_namespace_robotics_corner.pdf
MohamedSaied877003
 
Odoo Migration Services by CandidRoot Solutions
CandidRoot Solutions Private Limited
 
How to get the licensing right for Microsoft Core Infrastructure Server Suite...
Q-Advise
 
iaas vs paas vs saas :choosing your cloud strategy
CloudlayaTechnology
 
How Odoo ERP Enhances Operational Visibility Across Your Organization.pptx
pintadoxavier667
 
IDM Crack with Internet Download Manager 6.42 Build 31 2025?
utfefguu
 
ESUG 2025: Pharo 13 and Beyond (Stephane Ducasse)
ESUG
 
UI5con_2025_Accessibility_Ever_Evolving_
gerganakremenska1
 
24-BuildingGUIs Complete Materials in Java.ppt
javidmiakhil63
 
Attendance Management Software in Patna.
Camwel Solution LLP
 
chapter 5.pdf cyber security and Internet of things
PalakSharma980227
 
BB FlashBack Pro 5.61.0.4843 With Crack Free Download
cracked shares
 
ERP Consulting Services and Solutions by Contetra Pvt Ltd
jayjani123
 

Automated Application Management with SaltStack

  • 1. Automated Application Management with SaltStack Arnold Bechtoldt Cologne, 08.06.2016
  • 2. Arnold Bechtoldt Systems Engineer / Consultant @ inovex 〉 Software-Defined Datacenters 〉 Continuous Integration/Delivery 〉 DevOps 2
  • 3. Assets & Links 3 inovex.de arnoldbechtoldt.comgithub.com/bechtoldt/talk-salt-orchestration
  • 6. 〉 ... uses remote execution to distribute system commands 〉 ... should be more than just executing commands (most of the tools end here) 〉 ... should be able to respect internal & external dependencies/relations 〉 ... should be deterministic and fast 〉 ... must [RFC2119] be easy to understand/learn (YMMV) Orchestration... 6
  • 7. 7 MCollective + Shell Script A not-so-cool Example
  • 8. http://www.ansible.com/blog/orchestration-you-keep-using-that-word For instance, if you use a single-purpose deployment tool [...] to trigger some legacy configuration management, that might be called “orchestrating X with Y”. In reality, it’s usually just replacing a non- scaling [...] server solution X with a stand-alone implementation of Y. 8
  • 10. SaltStack implements the same techiniques that other tools do: 〉 send commands to servers 〉 send commands to servers that have different operating systems 〉 send commands only to a subset of servers 〉 run command A, then B, then C Often this isn’t enough for us! SaltStack Orchestration 10
  • 11. What we really want to have: 〉 scale accross thousands of servers 〉 easy configuration (less software programming) 〉 an interface to implement internal/external relationships (pre/post tasks) 〉 fully automated workflows/procedures (no manual interaction) SaltStack Orchestration 11
  • 12. What we really want to have: 〉 scale accross thousands of servers SOA – Message Bus Architecture 〉 easy configuration (less software programming) YAML – JSON – Python DSL 〉 an interface to implement internal/external relationships (pre/post tasks) State – Remote Execution – Pillar – Returner – Beacon – Cloud (~ 600 modules) 〉 fully automated workflows/procedures (no manual interaction) Event System – Reactor – Runner – APIs SaltStack Orchestration 12
  • 13. Salt Peer-Publish: Realtime Execution 13 minionminion minion minion minion master minion minion minion minion minion
  • 14. 〉 Peer-2-Peer like 〉 Privilege management on master-side 〉 Synchronous & blocking Use Cases: 〉 Gathering realtime metrics of other systems (minions) 〉 Automatically-triggered remote execution Salt Peer-Publish: Realtime Execution 14
  • 15. Salt Mine: Dynamic Runtime Data Cache 15 minionminion minion minion minion mine (master) minion minion minion minion minion minion
  • 16. 〉 Caching arbitrary data/metrics 〉 Replaces slow/expensive peer public calls Use Cases: 〉 Gathering backend addresses for LB config 〉 Gathering SSH public keys (host/user) of other other hosts 〉 Asynchronous collecting of metrics for monitoring Salt Mine: Dynamic Runtime Data Cache 16
  • 17. Salt Reactor: Event-Driven System Automation 17 minion minion minion minionminion minion minion minion minion minionminion reactor (master) salt/key salt/job/new node/stonith/new update/application salt/auth salt/job/return scale/out loadbalancer/config/update salt/minion/start salt/presence/present monitoring/hosts/new firewall/config/update salt/minion/stop salt/presence/change monitoring/hosts/remove coffee/new
  • 18. Event-Driven System Automation 18 minion minion minion minion minion minionmaster MySQL Foreman etcd MySQL ElasticsearchSMTP Syslog Icinga Appliances HTTP Docker Slack PostgreSQLminion AWS
  • 19. 〉 Automated cfg mgmt and remote execution across several hosts 〉 „Real Orchestration“ 〉 Asynchronous 〉 Synchronous/blocking alternative: Orchestration Runner Use Cases: 〉 Automated loadbalancer configuration updates 〉 Automated host bootstrapping and software provisioning Salt Reactor: Event-Driven System Automation 19
  • 20. salt/job/20151104191820394966/new { "_stamp": "2015-11-04T18:18:20.512126", "arg": [ ”orchestration.bootstrap", { "__kwarg__": true, "test": false } ], "fun": "state.sls", "jid": "20151104191820394966", "minions": [ ”mw42" ], "tgt": ”mw42", "tgt_type": "glob", "user": ”root” } Event Structure 20 custom/minion/haste_server_started { "_stamp": "2015-11-04T18:33:54.650568", "cmd": "_minion_event", "data": { ”custom": { "onchanges": [],  "foo": "bar",  "num": 42, }, "sfun": "wait" }, "id": "mw2", "pretag": null, "tag": "custom/minion/haste_server_started" }
  • 21. State A resource should look like {…} Pillar Database/CMDB (Files, RDBMS, NoSQL) Execution Execute command X on a server. Used by other Salt components. Returner Log store of job results (DB, Elasticsearch, Syslog, Monitoring) Beacon Special event triggers (inotify, load, procs, network/user activity) Reactor Reacts to events by triggering subsequent procedures (execution modules) Cloud IaaS provisioning (EC2, OpenStack, Digital Ocean, Linode, GCE, VMware) … SaltStack Terminology 21
  • 24. Demo Concept 24 1. Tells MW hosts to install MW 4. Tells FE hosts to install FE 6. Tells MW hosts to deploy App 10. Tells FE to reconfigure FE 2. Install Node.JS (MW) 3. Report back to Master 7. Deploy App 8. Send Notification Mail 9. Report back to Master 5. Install Haproxy (FE) 6. Report back to Master 11. Add/Remove HAProxy backends 12. Report back to Master Salt Master/Reactor MW hosts FE hosts
  • 25. Demo Concept 25 1. Tells MW hosts to install MW 4. Tells FE hosts to install FE 6. Tells MW hosts to deploy App 10. Tells FE to reconfigure FE 2. Install Node.JS (MW) 3. Report back to Master 7. Deploy App 8. Send Notification Mail 9. Report back to Master 5. Install Haproxy (FE) 6. Report back to Master 11. Add/Remove HAProxy backends 12. Report back to Master Salt Master/Reactor MW hosts FE hosts
  • 26. Assets & Links 26 sh.arbe.io/cloud-provision youtu.be/9MzeK4u4pkM (demo)github.com/bechtoldt/talk-salt-orchestration
  • 27. Q&A
  • 28. Arnold Bechtoldt inovex GmbH [email protected] CC BY-NC-ND inovex.de +ArnoldBechtoldtGER github.com/bechtoldt arbe.io youtube.com/inovexGmbH