]> git.immae.eu Git - github/fretlink/docker-ansible.git/blobdiff - ubuntu16.04/Dockerfile
Update: Ansible PPA now supports the most recent version for Ubuntu 16.04 LTS (Xenial).
[github/fretlink/docker-ansible.git] / ubuntu16.04 / Dockerfile
index cd27d3acabd8b58b7eecc10512d726aa300903da..762c2daf47e92e1bf7d1118c2e82b1a7b02aaf76 100644 (file)
@@ -11,15 +11,20 @@ FROM ubuntu:16.04
 
 MAINTAINER William Yeh <william.pjyeh@gmail.com>
 
-RUN DEBIAN_FRONTEND=noninteractive  apt-get update  && \
+
+RUN echo "===> Adding Ansible's PPA..."  && \
+    echo "deb http://ppa.launchpad.net/ansible/ansible/ubuntu xenial main" | tee /etc/apt/sources.list.d/ansible.list           && \
+    echo "deb-src http://ppa.launchpad.net/ansible/ansible/ubuntu xenial main" | tee -a /etc/apt/sources.list.d/ansible.list    && \
+    apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv-keys 7BB9C367    && \
+    DEBIAN_FRONTEND=noninteractive  apt-get update  && \
     \
     \
     echo "===> Installing Ansible..."  && \
     apt-get install -y ansible  && \
     \
     \
-    echo "===> Clean up..."              && \
-    rm -rf /var/lib/apt/lists/*          && \
+    echo "===> Removing Ansible PPA..."  && \
+    rm -rf /var/lib/apt/lists/*  /etc/apt/sources.list.d/ansible.list  && \
     \
     \
     echo "===> Adding hosts for convenience..."  && \