---
- hosts: all
  gather_facts: no
  become: true
  pre_tasks:
    - name: Install Python 2 first
      raw: python --version || apt-get update && apt-get install -y python
  roles:
    - opsta.host_preparation

---
- hosts: all
  gather_facts: no
  become: true
  pre_tasks:
    - name: Configure apt-cacher-ng
      raw: "(test -f /etc/apt/apt.conf.d/11proxy ||
        echo 'Acquire::http::Proxy \"{{ host_preparation_apt_cacher_ng }}\";' >
          /etc/apt/apt.conf.d/11proxy)"
      when: host_preparation_apt_cacher_ng is defined
    - name: Install Python 2 first
      raw: python --version || apt-get update && apt-get install -y python
  roles:
    - opsta.host_preparation

Add host preparation playbook to support apt-cacher when install python
Add host preparation playbook to support apt-cacher when install python
