Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

HTTP Error 422: UNPROCESSABLE ENTITY #462

Closed
BrGitHub11 opened this issue Jan 30, 2024 · 1 comment
Closed

HTTP Error 422: UNPROCESSABLE ENTITY #462

BrGitHub11 opened this issue Jan 30, 2024 · 1 comment
Assignees
Labels
bug Something isn't working

Comments

@BrGitHub11
Copy link

Describe the bug
We were running deployments for weeks now. We didn't change anything in our code but now the deployment fails with the error code for one single cluster and template (for other clusters it's still working):
HTTP Error 422: UNPROCESSABLE ENTITY

To Reproduce
nutanix.ncp.ntnx_vms:
state: present
name: "XXXvmname"
nutanix_host: "XXXhostname"
nutanix_username: 'XXXusername'
nutanix_password: 'XXXpassword'
cluster:
name: "XXXclustername"
networks:
- is_connected: True
subnet:
uuid: "XXXuuidname"
disks: "[
{
"type": "DISK",
"size_gb": 150,
"bus": "SCSI",
"clone_image": {
"name": "rhel9"
}
},
{
"type": "CDROM",
"bus": "SATA",
"empty_cdrom": true
}
]"
vcpus: "2"
cores_per_vcpu: "2"
memory_gb: "8"
categories:
Environment:
- "Dev"
authentication:
- "devops"
Team:
- "devops"
Department:
- "it"

Stack trace
{
"status_code": 422,
"error": "HTTP Error 422: UNPROCESSABLE ENTITY",
"response": null,
"msg": "Failed fetching URL: https://XXXhostname:9440/api/nutanix/v3/vms",
"invocation": {
"module_args": {
"state": "present",
"name": "XXXvmname",
"nutanix_host": "XXXhostname",
"nutanix_username": "XXXusername",
"nutanix_password": "VALUE_SPECIFIED_IN_NO_LOG_PARAMETER",
"cluster": {
"name": "XXXclustername"
},
"networks": [
{
"is_connected": true,
"subnet": {
"uuid": "XXXuuidname"
}
}
],
"disks": [
{
"type": "DISK",
"size_gb": 150,
"bus": "SCSI",
"clone_image": {
"name": "rhel9"
}
},
{
"type": "CDROM",
"bus": "SATA",
"empty_cdrom": true
}
],
"vcpus": 2,
"cores_per_vcpu": 2,
"memory_gb": 8,
"categories": {
"Environment": [
"Dev"
],
"authentication": [
"devops"
],
"Team": [
"devops"
],
"Department": [
"it"
]
},
"nutanix_port": "9440",
"validate_certs": true,
"wait": true,
"timezone": "UTC",
"force_power_off": false,
"remove_categories": false
}
},
"_ansible_no_log": null,
"changed": false
}

Expected behavior
VM should be deployed without error

Additional context
Like mentioned above: we can only deploy RHEL9 on a certain cluster. And only RHEL9 is deployed on this cluster.
The issue started from one day to another without any changes on our side.
On other clusters and with other templates the code is still working fine with all other settings the same (like team,
user, password, host).

@BrGitHub11 BrGitHub11 added the bug Something isn't working label Jan 30, 2024
@BrGitHub11 BrGitHub11 changed the title [Bug] <summary of issue> in module <module_name> HTTP Error 422: UNPROCESSABLE ENTITY Jan 30, 2024
@BrGitHub11
Copy link
Author

Found the root cause. The image was missing. But the error message should be more descriptive.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

4 participants