# Install useful tools on the bastion

# Add docker stable repository from PPA and install its signing key.

#  - name: Add repository key (docker)
#    apt_key:
#      keyserver: p80.pool.sks-keyservers.net
#      id: 58118E89F3A912897C070ADBF76221572C52609D
#    tags: tk

  - name: Add repository key (k8s)
    apt_key:
      url: "https://packages.cloud.google.com/apt/doc/apt-key.gpg"
      state: present
    tags: tk

  - name: Add repositories
    apt_repository:
      repo: "{{ item }}"
      state: present
    with_items:
      - "deb https://apt.dockerproject.org/repo ubuntu-xenial main"
      - "deb http://apt.kubernetes.io/ kubernetes-xenial main"
    tags: tk

  - name: Install useful base tools
    apt:
      name: "{{ item }}"
      update_cache: yes
    tags: tk
    with_items:
      - sysstat
      - screen
      - git
      - git-extras
      - docker-engine
      - kubectl

# Install useful tools on the bastion

# Add docker stable repository from PPA and install its signing key.

  - name: Add repository key (docker)
    apt_key:
      keyserver: p80.pool.sks-keyservers.net
      id: 58118E89F3A912897C070ADBF76221572C52609D
    tags: tk

  - name: Add repository key (k8s)
    apt_key:
      url: "https://packages.cloud.google.com/apt/doc/apt-key.gpg"
      state: present
    tags: tk

  - name: Add repositories
    apt_repository:
      repo: "{{ item }}"
      state: present
    with_items:
      - "deb https://apt.dockerproject.org/repo ubuntu-xenial main"
      - "deb http://apt.kubernetes.io/ kubernetes-xenial main"
    tags: tk

  - name: Install useful base tools
    apt:
      name: "{{ item }}"
      update_cache: yes
    tags: tk
    with_items:
      - sysstat
      - screen
      - git
      - git-extras
      - docker-engine
      - kubectl

Add key for the docker repository
Add key for the docker repository
