[5.0.0] Bump version to 5.0.0, remove deprecated features (#4516)

* Remove deprecated features.

* Fix changelog.

* Remove ignore.txt entries.

* One more.

* Remove state=get tests.
This commit is contained in:
Felix Fontein 2022-04-26 11:45:15 +02:00 committed by GitHub
parent 29c49febd9
commit 54b2f0819d
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
28 changed files with 79 additions and 500 deletions

View file

@ -626,7 +626,7 @@ def main():
if not vmid and state == 'present':
vmid = proxmox.get_nextvmid()
elif not vmid and hostname:
vmid = proxmox.get_vmid(hostname, choose_first_if_multiple=True)
vmid = proxmox.get_vmid(hostname)
elif not vmid:
module.exit_json(changed=False, msg="Vmid could not be fetched for the following action: %s" % state)
@ -637,9 +637,9 @@ def main():
module.exit_json(changed=False, msg="VM with vmid = %s is already exists" % vmid)
# If no vmid was passed, there cannot be another VM named 'hostname'
if (not module.params['vmid'] and
proxmox.get_vmid(hostname, ignore_missing=True, choose_first_if_multiple=True) and
proxmox.get_vmid(hostname, ignore_missing=True) and
not module.params['force']):
vmid = proxmox.get_vmid(hostname, choose_first_if_multiple=True)
vmid = proxmox.get_vmid(hostname)
module.exit_json(changed=False, msg="VM with hostname %s already exists and has ID number %s" % (hostname, vmid))
elif not proxmox.get_node(node):
module.fail_json(msg="node '%s' not exists in cluster" % node)
@ -681,9 +681,9 @@ def main():
module.exit_json(changed=False, msg="VM with vmid = %s is already exists" % vmid)
# If no vmid was passed, there cannot be another VM named 'hostname'
if (not module.params['vmid'] and
proxmox.get_vmid(hostname, ignore_missing=True, choose_first_if_multiple=True) and
proxmox.get_vmid(hostname, ignore_missing=True) and
not module.params['force']):
vmid = proxmox.get_vmid(hostname, choose_first_if_multiple=True)
vmid = proxmox.get_vmid(hostname)
module.exit_json(changed=False, msg="VM with hostname %s already exists and has ID number %s" % (hostname, vmid))
if not proxmox.get_vm(clone, ignore_missing=True):
module.exit_json(changed=False, msg="Container to be cloned does not exist")