1 #############################################################################
2 # Copyright (c) 2016 The Linux Foundation and others.
3 # All rights reserved. This program and the accompanying materials
4 # are made available under the terms of the Apache License, Version 2.0
5 # which accompanies this distribution, and is available at
6 # http://www.apache.org/licenses/LICENSE-2.0
7 #############################################################################
9 - name: Ensure old versions of Docker are not installed.
17 - name: Ensure depdencies are installed.
50 - openjdk-8-jre-headless
60 - name: Add Docker apt key.
62 url: https://download.docker.com/linux/ubuntu/gpg
63 id: 9DC858229FC7DD38854AE2D88D81803C0EBFCD88
65 register: add_repository_key
68 - name: Ensure curl is present (on older systems without SNI).
69 package: name=curl state=present
70 when: add_repository_key|failed
72 - name: Add Docker apt key (alternative for older systems without SNI).
73 # yamllint disable rule:line-length
74 shell: "curl -sSL https://download.docker.com/linux/ubuntu/gpg | sudo apt-key add -"
75 # yamllint enable rule:line-length
78 when: add_repository_key|failed
80 - name: Add Docker repository.
82 repo: "{{ docker_apt_repository }}"