You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The --check argument is not being honored when the vmware.vmware_rest Ansible module is being called and is still executing the code as you can see in the video below the POST request still gets sent when the check_mode: true parameter is set whereas the other honor the check flag and do not execute a request.
In the video was running a HTTP server and HTTPS server in python as you can see a post request is sent by the vmware.vmware_rest module to the HTTPS server but there is no request for HTTP because it honors the check_mode: true.
No LSB modules are available.
Distributor ID: Linuxmint
Description: Linux Mint 21.2
Release: 21.2
Codename: victoria
STEPS TO REPRODUCE
---
- name: VMware REST API Playbookhosts: localhostgather_facts: falsetasks:
- name: This task will never make changes to the systemansible.builtin.lineinfile:
line: "important config"dest: ~/vmware_ansible/myconfig.confstate: presentcheck_mode: true # Does not execute.register: changes_to_important_config
- name: POST request to serveruri:
url: "http://localhost:12345/"method: POSTbody: '{"key1": "value1", "key2": "value2"}'body_format: jsonheaders:
Content-Type: "application/json"status_code: 200check_mode: true # Does not execute.register: response
- name: Get VM informationvmware.vmware_rest.vcenter_vm_info:
vcenter_hostname: "localhost"vcenter_username: "username"vcenter_password: "password"vcenter_validate_certs: falsevm: "vm"check_mode: true # Executes?register: vm_info
EXPECTED RESULTS
vmware.vmware_rest does not execute at all when yaml check_mode: true .
ACTUAL RESULTS
Watch video :)
The text was updated successfully, but these errors were encountered:
#419
#363
Release branch is affect, not tested devel.
SUMMARY
The
--check
argument is not being honored when the vmware.vmware_rest Ansible module is being called and is still executing the code as you can see in the video below the POST request still gets sent when thecheck_mode: true
parameter is set whereas the other honor the check flag and do not execute a request.In the video was running a HTTP server and HTTPS server in python as you can see a post request is sent by the vmware.vmware_rest module to the HTTPS server but there is no request for HTTP because it honors the
check_mode: true
.2023-12-21.16-47-10.mp4
ISSUE TYPE
COMPONENT NAME
vmware.vmware_rest
ANSIBLE VERSION
COLLECTION VERSION
CONFIGURATION
OS / ENVIRONMENT
No LSB modules are available.
Distributor ID: Linuxmint
Description: Linux Mint 21.2
Release: 21.2
Codename: victoria
STEPS TO REPRODUCE
EXPECTED RESULTS
vmware.vmware_rest does not execute at all when
yaml check_mode: true
.ACTUAL RESULTS
Watch video :)
The text was updated successfully, but these errors were encountered: