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

[Bug] Updating VMware account password fails in command calm update account #309

Open
choople opened this issue Aug 20, 2024 · 1 comment
Assignees
Labels
bug Something isn't working

Comments

@choople
Copy link

choople commented Aug 20, 2024

Describe the bug
When the password has changed for a VMware account, and a platform sync has occurred, the account is in an error state. When Calm goes to update the account it fails because it sees the account in an error state and won't try updating the account with the new password.

Branch/Container
master

To Reproduce

  1. Change the password of the account used by Self-Service to connect to vCenter Server
  2. Trigger a platform sync or wait for one to occur
  3. Update the account using calm update account

Expected behavior
It should allow updating an account even in an error state. If the admin wants to use update the account using IaC, then DSL is the only way to do it.

Available Logs/Data
[2024-08-19 21:49:46] [INFO] [calm.dsl.cli.accounts:161] xxx found
[2024-08-19 21:49:46] [INFO] [calm.dsl.cli.accounts:167] Fetching account details
[2024-08-19 21:49:50] [ERROR] [calm.dsl.api.connection:326] Oops! Something went wrong.
{
"error": {
"api_version": "3.1",
"code": 422,
"kind": "blueprint",
"message_list": [
{
"details": {
"ecc8b88b-3b8a-2e4a-76ce-00094ab6fe3a": [
"Unable to connect to vmware server xxx: due to error ServerFaultCode: Cannot complete login due to an incorrect user name or password. "
]
},
"message": "Unable to connect to vmware server xxx: due to error ServerFaultCode: Cannot complete login due to an incorrect user name or password.",
"reason": "INVALID_REQUEST"
}
],
"state": "ERROR"
},
"code": 422
}

** System Configuration:**

  • OS: Windows
  • Python: 3.11.9
  • DSL: 3.8.0
@choople choople added the bug Something isn't working label Aug 20, 2024
@choople
Copy link
Author

choople commented Aug 20, 2024

I am able to update the VMware account using the REST API directly, even with the account in an error state in Self-Service.

fabricekrebs pushed a commit to fabricekrebs/calm-dsl that referenced this issue Oct 14, 2024
…utanix#309)

Resource types list is fetched from accounts_uuid_resource_types_list
instead of resource_types_uuid

Cred dict using accounts_uuid_resource_types_list api -
<img width="1109" alt="Screenshot 2023-10-16 at 10 42 24 AM"
src="https://github.com/ideadevice/calm-dsl/assets/134352330/bb421125-b85f-4993-8aa5-430ad3919a5c">

Cred dict using resource_types_uuid  api -
<img width="1113" alt="Screenshot 2023-10-16 at 10 38 49 AM"
src="https://github.com/ideadevice/calm-dsl/assets/134352330/e40f10c5-392a-476d-a07e-522c9d0ebc79">

Cred dict using accounts_uuid_resource_types_list api (Schema list with
secret type and local type variables) -
<img width="1136" alt="Screenshot 2023-10-16 at 12 26 19 PM"
src="https://github.com/ideadevice/calm-dsl/assets/134352330/2e948d46-304a-49b8-8dc4-03dbce4cf822">

Regression link -
http://erdinger.eng.nutanix.com/job/QA/job/DSL_Regression/518/#showFailuresLink

(cherry picked from commit 11c45478b4308c4e8515ddb75c609df03c8f6ae3)
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

2 participants