-
-
Save nitzmahone/4271319ab8e7acf3330c to your computer and use it in GitHub Desktop.
Ansible Provision Windows in AWS with Stock AMIs (Part 1)
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
ansible win -i hosts -m win_ping |
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
aws-win-host ansible_ssh_host=(your aws host public IP here) | |
[win] | |
aws-win-host | |
[win:vars] | |
ansible_connection=winrm | |
ansible_ssh_port=5986 | |
ansible_ssh_user=Administrator | |
ansible_ssh_pass=myTempPassword123! |
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> | |
$admin = [adsi]("WinNT://./administrator, user") | |
$admin.PSBase.Invoke("SetPassword", "myTempPassword123!") | |
Invoke-Expression ((New-Object System.Net.Webclient).DownloadString('https://raw.githubusercontent.com/ansible/ansible/devel/examples/scripts/ConfigureRemotingForAnsible.ps1')) | |
</powershell> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment