archive: "file.zip" does not exist

I have the following:

`

  • name: Compress reports
    archive:
    path: “{{ final_location }}/{{ host }}_reports”
    #dest: “{{ final_location }}/{{ host }}_reports.zip”
    format: zip

`

It returns this:

`

TASK [LookingGlass : Compress reports] *************************************************************************************************************************
fatal: [3.224.151.99]: FAILED! => {“changed”: false, “msg”: “path /Users/joharmon/Desktop/LookingGlass_Reports_2019-11-14/wargames_reports.zip does not exist”, “path”: “/Users/joharmon/Desktop/LookingGlass_Reports_2019-11-14/wargames_reports.zip”}
fatal: [3.225.174.116]: FAILED! => {“changed”: false, “msg”: “path /Users/joharmon/Desktop/LookingGlass_Reports_2019-11-14/wargames_reports.zip does not exist”, “path”: “/Users/joharmon/Desktop/LookingGlass_Reports_2019-11-14/wargames_reports.zip”}
fatal: [3.220.214.197]: FAILED! => {“changed”: false, “msg”: “path /Users/joharmon/Desktop/LookingGlass_Reports_2019-11-14/wargames_reports.zip does not exist”, “path”: “/Users/joharmon/Desktop/LookingGlass_Reports_2019-11-14/wargames_reports.zip”}

`

Am I using this wrong?? If I declare a dest it also fails: ie

`
dest: “{{ final_location }}/{{ host }}_reports.zip”

`

John,

The value for path must exist on the remote machine. Does /Users/joharmon/Desktop/LookingGlass_Reports_2019-11-14/wargames_reports exist on the remote machine? This looks like a path that may be on the control machine.

No, it doesn’t. It is on my laptop. Was hoping to zip it up locally

Then you need to set your playbook to localhost or set delegate_to: localhost
on the task.

DOH! I forgot to add that… Thank you!