2015-12-14 07:18:01 +01:00
|
|
|
FROM centos:6
|
2015-12-14 15:38:39 +01:00
|
|
|
|
|
|
|
# Install Ansible
|
2015-12-14 07:18:01 +01:00
|
|
|
RUN yum -y update; yum clean all;
|
|
|
|
RUN yum -y install epel-release
|
|
|
|
RUN yum -y install git ansible sudo
|
|
|
|
RUN yum clean all
|
2015-12-14 15:38:39 +01:00
|
|
|
|
2015-12-14 07:18:01 +01:00
|
|
|
# Disable requiretty
|
|
|
|
RUN sed -i -e 's/^\(Defaults\s*requiretty\)/#--- \1/' /etc/sudoers
|
2015-12-14 15:38:39 +01:00
|
|
|
|
2015-12-14 07:18:01 +01:00
|
|
|
# Install Ansible inventory file
|
|
|
|
RUN echo -e '[local]\nlocalhost ansible_connection=local' > /etc/ansible/hosts
|
|
|
|
|
2015-12-14 15:38:39 +01:00
|
|
|
CMD ["/usr/sbin/init"]
|