An introduction to SaltStack

 

by Viet Hung Nguyen

robotinfra.com

  • Blog: familug.org
  • Everywhere name: hvnsweeting

 

Saltstack.com

Official Vietnam SaltStack user group

http://www.meetup.com/VietNam-SaltStack-Meetup/

Opensource

http://github.com/saltstack/

 

What next?

  • Automation evolution
  • Installing saltstack
  • Salt components
  • Two ways of using Salt
  • Practice, practice, practice
  • Q&A

Automation evolution

Problems 😨

  • Install software on multiple machines (server)
  • Managing file contents
  • Auto deployment?
  • 100 machines ?
  • How long? how many people?
  • What installed on this machine?
  • What if mrX leave company?

Solutions 🤓

Bash (shell)

It's all about that bash,

'bout that bash

'bout that bash

not problem!

Bash

- Ubiquitous

- Easy to run any commands

 

Bash

- How to managing file?

- Change content of a file? sed?

- Can I run this script again?

Bash

- Cryptic language

- Organizing modules?

 

Fabric/Capistrano

  • Remote execution

  • Write python/ruby code

Configuration management

- CF engine

- Puppet

- Chef

- Salt

- Ansible

Comparing 🙄

 

 

 

http://blog.takipi.com/deployment-management-tools-chef-vs-puppet-vs-ansible-vs-saltstack-vs-fabric/

Puppet/Chef

- Write Ruby code

- Steep learning path

- Chef still requires 4GB server?

SaltStack/Ansible

YAML config file

 

Awards

https://saltstack.com/awards/

Customer?

  • LinkedIn (now in Microsoft)
  • Photobucket
  • Rackspace
  • Hulu
  • HP cloud
  • ...

Stop the ads...

Stop comparing ...

Let's get your hands dirty 🙌
 

Install SaltStack

 

Install on your OSes

 

https://docs.saltstack.com/en/latest/contents.html

Pkg: salt-minion

Remote execution

https://docs.saltstack.com/en/latest/ref/modules/all/index.html

Configuration management

https://docs.saltstack.com/en/latest/ref/states/all/

Serverless salt

/srv/salt

/srv/pillar (later)

Usecase1: vim

Usecase2: postgresql

Usecase3: build app from source

redis

What's wrong?

  • App build all the time
  • I don't want to build app on all machines

Redis from PPA

  • ppa:chris-lea/redis-server

Components

State (SLS file) - formula

Grains

Pillar

Grains

Provides static - system data

Pillar

Provides user data

For states

Usecase4: setup postgresql db

Usecase5: setup Mattermost chat service

 

More formulas?

https://github.com/saltstack-formulas
https://github.com/bclermont/states https://github.com/hvnsweeting/saltstates # old

Q & A

Thank you!

 

and join us at

http://www.meetup.com/VietNam-SaltStack-Meetup/

 

We are waiting...

SaltStack Meetup

By hvnsweeting

SaltStack Meetup

An introduction to saltstack

  • 224