Update validate_argument_spec.py (#80547)

##### SUMMARY
Fix example with file lookup, filter 'from_yaml' is required.


##### ISSUE TYPE
- Docs Pull Request

+label: docsite_pr
pull/80544/head
7840vz 1 year ago committed by GitHub
parent 64fb64643d
commit 8d685b89f2
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -69,7 +69,7 @@ EXAMPLES = r'''
- name: verify vars needed for this task file are present when included, with spec from a spec file
ansible.builtin.validate_argument_spec:
argument_spec: "{{lookup('ansible.builtin.file', 'myargspec.yml')['specname']['options']}}"
argument_spec: "{{(lookup('ansible.builtin.file', 'myargspec.yml') | from_yaml )['specname']['options']}}"
- name: verify vars needed for next include and not from inside it, also with params i'll only define there

Loading…
Cancel
Save