Xicheng Chang 31a3c755f4 Update: add ansible code
Ansible for installing:
Chef(host)
Cobbler
Compass
Currently only three components being on the same host is supported.

Change-Id: I1f36ee77546d3e5734a69660dde9edc41dc8ea13
2015-01-28 10:46:52 -08:00

32 lines
875 B
YAML

---
- name: get epel 6
yum: name={{ epel_6 }} state=present
when: ansible_distribution_major_version == '6'
# I've tried to do a "variable in variable" to dynamically load
# major version, so that getting the correct epel url is way easier.
# but ansible is not friendly with it, will need to dive more into
# it to see if there is a way.
- name: get epel 7
yum: name={{ epel_7 }} state=present
when: ansible_distribution_major_version == '7'
- name: get docker
yum: pkg=docker-io state=installed
when: ansible_distribution_major_version == '6'
- name: get docker if el7
yum: pkg=docker state=installed
when: ansible_distribution_major_version == '7'
# install bridge util/python-pip package
- name: install brctl
yum: pkg={{ item }} state=installed
with_items:
- bridge-utils
- python-pip
- name: pip install dockerpy
pip: name=docker-py