---
- name: Create
  hosts: localhost
  connection: local
  gather_facts: False
  vars:
    molecule_file: "{{ lookup('env', 'MOLECULE_FILE') }}"
    molecule_ephemeral_directory: "{{ lookup('env', 'MOLECULE_EPHEMERAL_DIRECTORY') }}"
    molecule_scenario_directory: "{{ lookup('env', 'MOLECULE_SCENARIO_DIRECTORY') }}"
    molecule_yml: "{{ lookup('file', molecule_file) | from_yaml }}"
    # sha256 digest of quay.io/freedomofpress/sd-docker-builder:2018_05_23
    image_hash: 14be07c3992fd14b7a0cc0137aabeaa97aada91a755c420b1b54a899b9d07567
  tasks:
    - name: Create builders
      docker_container:
        name: "{{ item.name }}"
        hostname: "{{ item.name }}"
        image: "quay.io/freedomofpress/sd-docker-builder@sha256:{{image_hash}}"
        state: started
        command: "tail -f /dev/null"
        privileged: "{{ item.privileged | default(omit) }}"
        volumes: "{{ item.volumes | default(omit) }}"
        capabilities: "{{ item.capabilities | default(omit) }}"
      with_items: "{{ molecule_yml.platforms }}"

---
- name: Create
  hosts: localhost
  connection: local
  gather_facts: False
  vars:
    molecule_file: "{{ lookup('env', 'MOLECULE_FILE') }}"
    molecule_ephemeral_directory: "{{ lookup('env', 'MOLECULE_EPHEMERAL_DIRECTORY') }}"
    molecule_scenario_directory: "{{ lookup('env', 'MOLECULE_SCENARIO_DIRECTORY') }}"
    molecule_yml: "{{ lookup('file', molecule_file) | from_yaml }}"
    # sha256 digest of quay.io/freedomofpress/sd-docker-builder:2018_06_06
    image_hash: 15f43e8d86a164509bccbe9b1c9fb5e2b3e6edd87457a9b67fef47574ec8a89c
  tasks:
    - name: Create builders
      docker_container:
        name: "{{ item.name }}"
        hostname: "{{ item.name }}"
        image: "quay.io/freedomofpress/sd-docker-builder@sha256:{{image_hash}}"
        state: started
        command: "tail -f /dev/null"
        privileged: "{{ item.privileged | default(omit) }}"
        volumes: "{{ item.volumes | default(omit) }}"
        capabilities: "{{ item.capabilities | default(omit) }}"
      with_items: "{{ molecule_yml.platforms }}"

Update SD docker container for latest sec. fixes
Update SD docker container for latest sec. fixes
