vmware / govmomi

Go library for the VMware vSphere API
Apache License 2.0
2.31k stars 912 forks source link

govc: no such host #3157

Closed jakharpraveen closed 1 year ago

jakharpraveen commented 1 year ago

Hello folks. I'm running these test cases in a docker container. I've stuck with this problem... I'm trying delete vm in vmwarevsphere using govc(in CDS workflow, venom cli test case fails ).

When I run this:

# destroyVM
- name: destroyVM
  steps:
  - type: exec
    retry: 3
    delay: 20
    script: |
        export GOVC_URL="{{.API.serviceName}}"
        export GOVC_USERNAME="{{.userName}}"
        export GOVC_PASSWORD="{{.userPass}}"
        export GOVC_DATACENTER="{{.API.serviceName}}_datacenter{{.API.datacenterId}}"
        govc vm.destroy {{.restored_vm_name}}*
    info: "Result status code : {{.result.code}} {{.result}} {{.userName}} {{.userPass}}"
    assertions:
    - result.code ShouldEqual 0

I am getting following error

govc: Post "https://pcc-xx-xx-xx-xx/sdk": dial tcp: lookup pcc-xx-xx-xx-xx on xx.xx.xx.xx:53: no such host

Troubleshoot I have done is checked network access

github-actions[bot] commented 1 year ago

Howdy 🖐   jakharpraveen ! Thank you for your interest in this project. We value your feedback and will respond soon.

If you want to contribute to this project, please make yourself familiar with the CONTRIBUTION guidelines.

dougm commented 1 year ago

Looks like a dns issue, not a govc issue. Do you see the same with other programs, such as curl:

% curl https://pcc-xx-xx-xx-xx
curl: (6) Could not resolve host: pcc-xx-xx-xx-xx
github-actions[bot] commented 1 year ago

This issue is stale because it has been open for 90 days with no activity. It will automatically close after 30 more days of inactivity. Mark as fresh by adding the comment /remove-lifecycle stale.