{"action":"closed","issue":{"url":"https://api.github.com/repos/vmware/pyvmomi-community-samples/issues/291","repository_url":"https://api.github.com/repos/vmware/pyvmomi-community-samples","labels_url":"https://api.github.com/repos/vmware/pyvmomi-community-samples/issues/291/labels{/name}","comments_url":"https://api.github.com/repos/vmware/pyvmomi-community-samples/issues/291/comments","events_url":"https://api.github.com/repos/vmware/pyvmomi-community-samples/issues/291/events","html_url":"https://github.com/vmware/pyvmomi-community-samples/issues/291","id":181227565,"number":291,"title":" disabling vmotion on a single VM","user":{"login":"mmumshad","id":2704615,"avatar_url":"https://avatars.githubusercontent.com/u/2704615?v=3","gravatar_id":"","url":"https://api.github.com/users/mmumshad","html_url":"https://github.com/mmumshad","followers_url":"https://api.github.com/users/mmumshad/followers","following_url":"https://api.github.com/users/mmumshad/following{/other_user}","gists_url":"https://api.github.com/users/mmumshad/gists{/gist_id}","starred_url":"https://api.github.com/users/mmumshad/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mmumshad/subscriptions","organizations_url":"https://api.github.com/users/mmumshad/orgs","repos_url":"https://api.github.com/users/mmumshad/repos","events_url":"https://api.github.com/users/mmumshad/events{/privacy}","received_events_url":"https://api.github.com/users/mmumshad/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":1,"created_at":"2016-10-05T18:14:50Z","updated_at":"2016-10-17T19:29:01Z","closed_at":"2016-10-17T19:29:00Z","body":"Do you have sample code for disabling vmotion on a single VM? I am trying to deploy a VM from a template, and when it powers on, I need to be able to disable vmotion for a period of time, until it finishes customization. Appreciate any help.\r\n\r\nSimilar to the PowerCLI command here:\r\n\r\n```\r\n$myVC=MyVMName\r\nGet-VM $myVC | Set-VM -DrsAutomationLevel Disabled -Confirm:$false\r\n \r\nInvoke-VMScript .....\r\n \r\nGet-VM $myVC | Set-VM -DrsAutomationLevel AsSpecifiedByCluster -Confirm:$false\r\n```\r\n"}}
{"actor":{"display_login":"mmumshad"}}