Created
May 11, 2020 08:56
-
-
Save ebuildy/798f31413050689a9f3d242ee450f8d6 to your computer and use it in GitHub Desktop.
Install docker-compose via Ansible
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
--- | |
- hosts: recette | |
become: yes | |
become_user: root | |
tasks: | |
- name: "Get Linux uname's" | |
command: "uname -{{ item }}" | |
register: unames | |
with_items: ["s", "m"] | |
- set_fact: | |
uname_s: "{{ unames.results[0].stdout }}" | |
uname_m: "{{ unames.results[1].stdout }}" | |
- name: Install docker-compose | |
get_url: | |
url : https://github.com/docker/compose/releases/download/1.25.4/docker-compose-{{ uname_s }}-{{ uname_m }} | |
dest: /usr/bin/docker-compose | |
mode: 'u+x,g+x' |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment