Foreman VMware Compute Resource!


Do we have any feasibility to add vcenter ip under vmware compute resource, because im able to add individual esxi but vcenter server ip not.


could you elaborate what exactly you are trying to do?
On a VSphere compute resource, under “VCenter/Server” you can and have to enter you VCenter Server.
Using single ESX Servers as Compute Resource is not supported and will probably not work due to incompatibilities in the APIs/differences in features.


Case 1). I have foreman in public network and each site have smartproxy with NAT ip, that specific proxy is reserved for specific organization, now im trying to add vcenter which have only private ip and can communicate with smartproxy, here im trying to add that vcenter using private ip (as i assumed that my smart proxy will bridge the communication between foreman and vcenter) but, it is (foreman) not able to communicate with vcenter and getting timed out error.

Case 2). With https://proxy-fqdn/vcenter or https://proxy-fqdn:9443 (reverse proxy) also throwing error like

Failed to open TCP connection to https://proxy-fqdn/vcenter:443 (getaddrinfo: Name or service not known)

Failed to open TCP connection to https://proxy-fqdn/vcenter:9443:443 (getaddrinfo: Name or service not known)

I think you missunderstood the concept of the smartproxy (a common mistake, tbh, which is why there is an effort to find a better name and explain the concept better).
The reverse proxy part only works in the direction from the managed hosts to Foreman, which is why your case 2) does not work.
Also, the Smartproxy currently has no capability to manage compute resources via smartproxy. Compute ressources are always accessed from Foreman directly (which is why case 1 does not work).
In your case, I would recommend setting up a VPN or similar of some sort to connect your Foreman Server to the other private sites.

Sorry to disappoint you.

@areyus, Thanks for the clarification and agree with you but, that VCenter/Server column not accepting any other custom ports other than 443. My issue will solve if i able to use 9443/8443.

is there any way to define customer port for vcenter?.

Parameters: {“utf8”=>“✓”, “authenticity_token”=>“PhwpXsVK3EzDDNm1qYnkXF7WJecW+SeEAsuRSBV4L00Uuh8sVz4wQeK1rcGuGnv9VS/jLXEhbcqVhrosWLo7xQ==”, “compute_resource”=>{“name”=>“test”, “provider”=>“Vmware”, “description”=>"", “server”=>“”, “user”=>“root”, “password”=>"[FILTERED]", “display_type”=>“vmrc”, “set_console_password”=>"[FILTERED]", “caching_enabled”=>“1”, “location_ids”=>["", “2”], “organization_ids”=>["", “1”]}, “fakepassword”=>"[FILTERED]", “cr_id”=>""}