2017-02-19 13:56:47 +01:00
|
|
|
#!/bin/bash
|
2017-06-21 12:46:51 +02:00
|
|
|
|
2017-02-19 13:56:47 +01:00
|
|
|
if (( $EUID != 0 )); then
|
|
|
|
echo "This script must be run using sudo or as root"
|
|
|
|
exit
|
|
|
|
fi
|
|
|
|
|
2017-02-28 16:31:43 +01:00
|
|
|
apt-get -y install software-properties-common
|
2017-02-19 13:56:47 +01:00
|
|
|
# Add repository for ansible
|
|
|
|
add-apt-repository -y ppa:ansible/ansible
|
|
|
|
# update packages
|
|
|
|
apt-get update
|
|
|
|
# install required packages
|
2017-03-13 14:58:41 +01:00
|
|
|
apt-get -y install ansible
|
2017-03-08 14:48:58 +01:00
|
|
|
|
|
|
|
# TODO: run ansible on local host
|
2017-03-13 15:27:21 +01:00
|
|
|
ansible-playbook yavdr07.yml -b -i 'localhost_inventory' --connection=local
|