Skip to content

Instantly share code, notes, and snippets.

@jkoelker
Created March 9, 2017 18:58
Show Gist options
  • Save jkoelker/e9c7cf3bb4482dbb3d5791aacd7766f0 to your computer and use it in GitHub Desktop.
Save jkoelker/e9c7cf3bb4482dbb3d5791aacd7766f0 to your computer and use it in GitHub Desktop.
Windows 2016 Docker Jenkins Slave AWS user-data
<powershell> [87/513]
Set-ExecutionPolicy Unrestricted
net user Administrator '{{ win_admin_password }}'
iwr https://chocolatey.org/install.ps1 -UseBasicParsing | iex
choco install -y jre8 git
winrm quickconfig -q
winrm set winrm/config/winrs '@{MaxMemoryPerShellMB="2048"}'
winrm set winrm/config '@{MaxTimeoutms="1800000"}'
winrm set winrm/config/service '@{AllowUnencrypted="true"}'
winrm set winrm/config/service/auth '@{Basic="true"}'
Set-NetFirewallProfile -Profile Domain,Public,Private -Enabled False
Set-MpPreference -DisableRealtimeMonitoring $true
</powershell>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment