encrypt-file: roll back extended file stat
Change I8e7bc38c68c224795630b90a1b989098a7661491 switched the "Validate input file" task to use a path stat, but when a list of files is passed into encrypt_file this fails because the list is treated as a string. Switch back to the more naive "is undefined" check until it can be properly redone with a loop or similar and appropriate tests added. Change-Id: I83e665bc890aec42462776e0079457bb4506552f
This commit is contained in:
parent
096e8bd9c1
commit
e88f592c4d
@ -1,12 +1,7 @@
|
||||
- name: Stat input file
|
||||
stat:
|
||||
path: '{{ encrypt_file }}'
|
||||
register: _stat_result
|
||||
|
||||
- name: Validate input file
|
||||
fail:
|
||||
msg: '{{ encrypt_file }} : file does not exist'
|
||||
when: not _stat_result.stat.exists
|
||||
msg: 'Must define "encrypt_file"'
|
||||
when: encrypt_file is undefined
|
||||
|
||||
- name: Ensure gpg2 installed
|
||||
package:
|
||||
|
Loading…
x
Reference in New Issue
Block a user