From cdb27879e71dbfb2076aaebb93242071ef7221ad Mon Sep 17 00:00:00 2001 From: Jeff Geerling Date: Sat, 25 Feb 2017 08:48:30 -0600 Subject: [PATCH] Fixes #1: Add Docker Compose. --- defaults/main.yml | 4 ++++ tasks/main.yml | 7 +++++++ 2 files changed, 11 insertions(+) diff --git a/defaults/main.yml b/defaults/main.yml index 298433a..863d74f 100644 --- a/defaults/main.yml +++ b/defaults/main.yml @@ -1,6 +1,10 @@ --- docker_package: "docker-engine" +# Docker Compose options. +docker_install_compose: true +docker_compose_version: "1.11.2" + # Used only for Debian/Ubuntu. Add 'testing' if you don't want stable. docker_apt_repository: "deb https://apt.dockerproject.org/repo {{ ansible_distribution|lower }}-{{ ansible_distribution_release }} main" diff --git a/tasks/main.yml b/tasks/main.yml index 51e6c5e..985c8ad 100644 --- a/tasks/main.yml +++ b/tasks/main.yml @@ -13,3 +13,10 @@ name: docker state: started enabled: yes + +- name: Install Docker Compose (if configured). + get_url: + url: https://github.com/docker/compose/releases/download/{{ docker_compose_version }}/docker-compose-Linux-x86_64 + dest: /usr/local/bin/docker-compose + mode: 0755 + when: docker_install_compose