Install an exe in azure virtual machine created in resource manager portal

心已入冬 提交于 2019-12-24 13:52:45

问题


I am new to azure RM model.Please help me to copy and install an exe in VM created in resource manager portal using powershell script or using API. Thanks in advance.


回答1:


If you want to do the install the EXE remotely then the VM needs to be configured to allow for remote management - you can do this via WinRM. See: https://www.penflip.com/powershellorg/secrets-of-powershell-remoting/blob/master/accessing-remote-computers.txt and http://tarkus.me/post/64761019099/windows-azure-vms-remote-management

Setting this up is non-trivial (you need to ensure it's secure). You could also try adding an VM extension to the VM that will do the copy. Since the VM is already provision I think the only option here would be to use DSC though I've never added a DSC extension to a VM post-provisioning, it should work. That would require authoring and staging a DSC script in addition to adding the extension but definitely less complex than enabling remote management.

Simplest by far is as Gaurav suggested and log on to the VM and copy from there.



来源:https://stackoverflow.com/questions/34868976/install-an-exe-in-azure-virtual-machine-created-in-resource-manager-portal

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!