prepull.yml 976 B

12345678910111213141516171819202122232425262728293031
  1. ---
  2. - name: Check that node image is present
  3. command: "{{ openshift_container_cli }} images -q {{ osn_image }}"
  4. register: node_image
  5. # This task runs async to save time while the node is being configured
  6. - name: Pre-pull node image
  7. docker_image:
  8. name: "{{ osn_image }}"
  9. environment:
  10. NO_PROXY: "{{ openshift.common.no_proxy | default('') }}"
  11. when: node_image.stdout_lines == []
  12. # 10 minutes to pull the image
  13. async: 600
  14. poll: 0
  15. register: image_prepull
  16. - name: Check that pod image is present
  17. command: "{{ openshift_container_cli }} images -q {{ osn_pod_image }}"
  18. register: pod_image
  19. # This task runs async to save time while other downloads proceed
  20. - name: pre-pull pod image
  21. command: "{{ openshift_container_cli }} pull {{ osn_pod_image }}"
  22. environment:
  23. NO_PROXY: "{{ openshift.common.no_proxy | default('') }}"
  24. when: pod_image.stdout_lines == []
  25. # 10 minutes to pull the image
  26. async: 600
  27. poll: 0
  28. register: pod_image_prepull