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

error: something went wrong during authentication: error finding LoginUrl (SOS) #1332

Open
GORO9991 opened this issue Sep 19, 2024 · 4 comments
Assignees

Comments

@GORO9991
Copy link

Hello,

can someone plz help? im new to TF and im using this vmware/vcd provider just for test creating an Org
im getting the following error whenever i run the plan cmd:
[ERROR] vertex "provider["registry.terraform.io/vmware/vcd"]" error: something went wrong during authentication: error finding LoginUrl: could not find valid version for login: API version 37.0 is not supported: version = 37.0 is not supported
PS: im using the same creds to login to webUI without any issue, any hint is much appreciated

Rgds

@adambarreiro
Copy link
Collaborator

Hi @GORO9991, could you provide the HCL snippet that is giving you the issue? (you can obfuscate password and VCD url)

Which version of the VCD Provider are you using, and what version is your VCD?

Thanks in advance.

@GORO9991
Copy link
Author

hello Adam @adambarreiro / everyone and many thanks for ur comment,
well im using : "vmware/vcd" version = "3.12.0" the version compatible with our current vCD environment (which is: 10.3.1.18738571) as per the docs. Below is a snippet example that is still very basic:

main .tf:
terraform {
required_providers {
vcd = {
source = "vmware/vcd"
version = "3.12.0"
}
}
}

Connect VMware vCloud Director Provider

provider "vcd" {
user = var.vcd_user
password = var.vcd_pass
org = "System"
url = var.vcd_url
max_retry_timeout = var.vcd_max_retry_timeout
allow_unverified_ssl = var.vcd_allow_unverified_ssl
}

#Create a new org names "T3"
resource "vcd_org" "org-name" {
name = "T3GoroTest"
full_name = "My organization"
description = "The pride of my work"
is_enabled = "true"
delete_recursive = "true"
delete_force = "true"
}

.tfvars:

vCloud Director Connection Variables

vcd_user = "administrator"
vcd_pass = "....."
vcd_url = "https:///api"
vcd_max_retry_timeout = "60"
vcd_allow_unverified_ssl = "true"

PS: the .tfvars just contain the same creds for "integrated" admin user that i normally use to access the webUI portal (as a provider) as well as the api link (fqdn with /api appended)
Also note that in this environment, we can use both: "integrated" and "saml_adfs" modes of logins

Regards

@adambarreiro
Copy link
Collaborator

I'm not sure whether this would be the root cause, but VCD 10.3 was no longer supported since VCD Provider v3.11.0.
Could you try

terraform {
  required_providers {
    vcd = {
      source = "vmware/vcd"
      version = "3.10.0"
    }
  }
}

Let me know if it works.

@GORO9991
Copy link
Author

owww it worked smoothly ;) many thanks @adambarreiro you rockkk man
meanwhile, ill close this case and thanks once again

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants