Created
July 20, 2018 20:03
-
-
Save deekayen/5de1f7ff233387ceb17976f4211c39a2 to your computer and use it in GitHub Desktop.
Run Once: Start WinRM for Ansible to connect to Windows
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
powershell.exe -Command "& {[Net.ServicePointManager]::SecurityProtocol = 'tls12'; Invoke-WebRequest -Uri https://raw.githubusercontent.com/ansible/ansible/7963279fc2c3a8cfa6affb70307bac6fa669679c/examples/scripts/ConfigureRemotingForAnsible.ps1 -OutFile C:\Windows\Temp\ConfigureRemotingForAnsible.ps1}" | |
powershell.exe -ExecutionPolicy Bypass -File C:\Windows\Temp\ConfigureRemotingForAnsible.ps1 -SkipNetworkProfile -EnableCredSSP -ForceNewSSLCert -CertValidityDays 3650 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment