Saltstack

These SaltStack tutorials will learn you how to provision instances and platforms on OpenStack by using SaltStack.

Get our tips, special offers and updates straight into your inbox

An introduction to SaltStack (1/4)
saltstack

An introduction to SaltStack (1/4)

Introduction to SaltStack SaltStack is an Infrastructure Management, Configuration management and Automated Provisioning system. It contains a number of different components. Some of those components will be explained below. Someone can define states and formulas within salt and have them automatically provisioned. What are states States (and by extension state files) are a way to express certain states that a machine needs to be in. An example would be if you want to make sure that nginx is installed: nginx: pkg.
How to configure SaltStack to provision instances (2/4)
saltstack

How to configure SaltStack to provision instances (2/4)

How to deploy a web cluster using SaltStack Getting started: installing SaltStack on the salt master First, you will need a single instance (we typically call it the saltmaster) on the Cyso Openstack Platform. The saltmaster needs to be able to reach the internal (private) IP addresses of the new instances. To install this VM, please follow the tutorials at Create a cloud instance and use Ubuntu when you select an image.
How to use SaltStack to install packages (3/4)
saltstack

How to use SaltStack to install packages (3/4)

Installing packages Installing packages using salt is really easy. Let's say you want to install nginx - you can use the following syntax: nginx: pkg.latest Now, that is already a very simple syntax but - what if you wanted to install a list of packages, all part of the same group of packages? Well, Salt has you covered there as well. Let's say you want a complete php stack (nginx, php5) - You can use the following syntax:
How to use SaltStack to manage Nginx and MySQL (4/4)
saltstack

How to use SaltStack to manage Nginx and MySQL (4/4)

SaltStack makes managing vhosts and other configuration options very simple - Let's start with a very basic example of managing a file with the following state file: Open the file /srv/salt/vhosts/example.com.sls /etc/nginx/sites-available/www.example.com.conf: file: - managed - source: salt://files/templates/nginx.conf - template: jinja - context: - domain: example.com /etc/nginx/sites-enabled/www.example.com.conf: file: - symlink - target: /etc/nginx/sites-available/www.example.com.conf This little snippet makes sure that the file, /etc/nginx/sites-available/www.example.com.conf - contains the rendered version of salt://files/templates/nginx.conf. So, how do we make that file?