--- - name: Ensure base images directory exists file: path: "{{ base_images_dir }}" state: directory mode: '0755' become: true - name: Set cached image path set_fact: cached_image_path: "{{ base_images_dir }}/{{ qcow2_url | basename }}" - name: Download QCOW2 image get_url: url: "{{ qcow2_url }}" dest: "{{ cached_image_path }}" mode: '0644' timeout: "{{ download_timeout }}" force: "{{ force_download }}" become: true - name: Set image path fact set_fact: "{{ image_path_var }}": "{{ cached_image_path }}"