In this exercise I’m going to write a simple shell script, that will make my machine a salt slave.
I dont have experience in shell scripting but since this script is quite simple I decided to give it a try:
sudo apt install salt-minion
sudo nano /etc/salt/minion: “master: 192.168.190.128”
sudo systemctl restart salt-minion
This didn’t work. It just opened the file /etc/salt/minion but didn’t type in my masters ip. So I decided to look it up from the internet, and found article in stackoverflow which helped me to get forward.
I thought it would be good idea to put the script on git so I could easily access it on a computer I want to make as a slave.
First I cloned my git srv repo to my slave: git clone https://github.com/arttugit/srv.git
Then added the script to git: git add testscript.sh
And finally making a commit: git add . git commit; git push; git pull
Now it is time to install and try vagrant. My few first tries installing vagrant wasn’t so successful. I begun installing vagrant and virtualbox. After both packages were installed I headed to vagrant website to look for boxes. At this time I was trying to install vagrant on my guest machine xubuntu. I picked the most downloaded one, ubuntu server 14.04 LTS and entered following commands:
After investigating this issue and finding information about it on the web, I found one post that suggested enabling the GUI so I could see an error message. So I enabled the GUI by editing the Vagrantfile.