Fix broken CentOS tests; 'DistributionNotFound: jinja2'.

This commit is contained in:
Jeff Geerling 2016-07-10 22:27:51 -05:00
parent 65071dd992
commit c762892bb1
2 changed files with 3 additions and 9 deletions

View File

@ -3,17 +3,13 @@ FROM centos:6
# Install Ansible
RUN yum -y update; yum clean all;
RUN yum -y install epel-release
RUN yum -y install git python-setuptools gcc sudo libffi-devel python-devel openssl-devel
RUN yum -y install git ansible sudo
RUN yum clean all
RUN easy_install pip
RUN pip install ansible
# Disable requiretty
RUN sed -i -e 's/^\(Defaults\s*requiretty\)/#--- \1/' /etc/sudoers
# Install Ansible inventory file
RUN mkdir - p /etc/ansible
RUN echo -e '[local]\nlocalhost ansible_connection=local' > /etc/ansible/hosts
CMD ["/usr/sbin/init"]

View File

@ -13,16 +13,14 @@ rm -f /lib/systemd/system/basic.target.wants/*; \
rm -f /lib/systemd/system/anaconda.target.wants/*;
# Install Ansible
RUN yum -y install git python-setuptools gcc sudo libffi-devel python-devel openssl-devel
RUN yum -y install epel-release
RUN yum -y install git ansible sudo
RUN yum clean all
RUN easy_install pip
RUN pip install ansible
# Disable requiretty
RUN sed -i -e 's/^\(Defaults\s*requiretty\)/#--- \1/' /etc/sudoers
# Install Ansible inventory file
RUN mkdir - p /etc/ansible
RUN echo -e '[local]\nlocalhost ansible_connection=local' > /etc/ansible/hosts
VOLUME ["/sys/fs/cgroup"]