Added common playbook for undetected linux system
This commit is contained in:
parent
9150117972
commit
26e2a1ffec
2 changed files with 8 additions and 1 deletions
4
playbooks/common.yml
Normal file
4
playbooks/common.yml
Normal file
|
@ -0,0 +1,4 @@
|
||||||
|
---
|
||||||
|
- hosts: local
|
||||||
|
roles:
|
||||||
|
- role: common
|
|
@ -8,8 +8,11 @@ if [[ `uname` == "Linux" ]]; then
|
||||||
ansible-playbook -i inventory arch.yml
|
ansible-playbook -i inventory arch.yml
|
||||||
elif [[ -f /etc/lsb-release ]]; then
|
elif [[ -f /etc/lsb-release ]]; then
|
||||||
ansible-playbook -i inventory ubuntu.yml
|
ansible-playbook -i inventory ubuntu.yml
|
||||||
else
|
elif [[ -f /etc/fedora-release ]]; then
|
||||||
ansible-playbook -i inventory fedora.yml
|
ansible-playbook -i inventory fedora.yml
|
||||||
|
else
|
||||||
|
echo "can't autodetermine distro, just running default inventory"
|
||||||
|
ansible-playbook -i inventory common.yml
|
||||||
fi
|
fi
|
||||||
else
|
else
|
||||||
ansible-playbook -i inventory osx.yml
|
ansible-playbook -i inventory osx.yml
|
||||||
|
|
Loading…
Add table
Reference in a new issue