Skip to content

## Example: Running commands via WinRM on a Windows Virtual Machine

This example provisions a Virtual Machine running Windows Server 2016 with a Public IP Address and runs a remote-exec provisioner via WinRM.


  • The files involved in this example are split out to make it easier to read, however all of the resources could be combined into a single file if needed.
  • The certificate used for WinRM is generated by Azure KeyVault and then installed on the VM; as such the certificate in this example is self-signed, which may not be desirable in a real-world environment.
You can’t perform that action at this time.