📜 ⬆️ ⬇️

Salt - continued

image
Some time ago I wrote about a wonderful product: Salt .

Time does not stand still, and Salt is also developing.

From the last changes I can note:
- Attempt to monetize the project (The project moved to .com and got paid support)
- Over States
- Node Groups
- A lot of new documentation
- Subjectively better windows support
')

And now about everything a little more


Over states

Almost always, setting up a system requires performing a series of sequential actions and observing order is very important.
Even in older versions it was possible to organize some sequence within one state. Over State, on the other hand, allows you to organize a sequence of actions between stages.
More details can be found here .
Node groups

The selection of machines subject to a certain state is possible by:
1. minion_id
[root@control salt]# salt 'dc-nl2' test.ping
dc-nl2:
True

2. regular expression
[root@control salt]# salt -E 'dc-nl\d?' test.ping
dc-nl:
True
dc-nl2:
True

3. list
salt -L 'web1,web2,web3' test.ping
4. Grains Details (granules, probably. So I didn’t think how to do it right)
salt -G 'os:CentOS' test.ping
Granules are the static properties of a minion that he receives automatically at the moment of launch. You can also register your granules in the minion config
5. Node Groups Read More
Node Groups allows you to statically define certain groups of hosts in the wizard configuration file.
nodegroups:
group1: 'L@foo.domain.com,bar.domain.com,baz.domain.com or bl*.domain.com'
group2: 'G@os:Debian and foo.domain.com'

Documentation

There is nothing to say, it really grows with the project.
Here is the full table of contents .
I advise you to read the tutorial on the states , it has expanded
Windows support

At the time of this writing, there was somewhere in the 0.12 version of Salt.
I can say that if everything worked fine on linux, on Windows it wanted some dependencies, I didn’t understand exactly which ones. VCredist of some version seems.
Now it is remarkably placed by the installer.
Links

Salt itself
State examples

Actually this is a small review article.

If I see a desire to see examples in the comments, I’m ready to start writing a couple more examples of articles on how to use it all. Now I’m just about busy automating some of the processes on Windows via Salt.

PS Comments on the quality of the article and errors / typos will gladly accept (preferably in a personal), I will correct the mistakes. Do not kick hard: just learning.

Source: https://habr.com/ru/post/190928/


All Articles