- With Salt:
- change motd (message of the day)
- change desktop background
- create state installing essential software
SaltStack installed on the machines.
Three virtual machines.
VM1: Running Mint 17.2, Salt master || specs
VM2: Running Mint 17.2, Salt minion
VM3: Running Mint 17.2, Salt minion
Message of the day can be easily changed by editing the /etc/motd -file.
The init.sls file is build as follows:
I tested that the state runs normally.
No errors. Next I modified the motd.jinja -file to create a customised message with the IP of the host using Salt grains.
I ran the state again and then used ssh to connect to my local machine.
Motd has been successfully changed.
Changing desktop wallpaper on is done rather simply by overriding the default background binary file.
Installing essential software is done easily with a state using Pkg.installed. You can just create a new state and list wanted software with Pkg.installed(“nameofsoftware”). For example, I created this state with a list of some software I would use.
If you install software that requires configuration prior to use, you can do that with File.managed – and edit the conf files. In the way shown above with motd.
I ran the state locally. It can as well be deployed to slaves using salt ‘*’.
It took a while to process..
Done, and my software is here too.
+ FIREFOX SETTINGS
– – Work in progress
- Copying, modifying and redistributing this and all the other documents in this blog is allowed according to the GNU General Public License (versio 2 or newer).http://www.gnu.org/licenses/gpl.html
- Based on the Linux course by Tero Karvinen 2015: terokarvinen.com