-
-
Save warnergodfrey/2a151e81ab33b5e1dcea to your computer and use it in GitHub Desktop.
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
Set-ExplorerOptions -showHidenFilesFoldersDrives -showProtectedOSFiles -showFileExtensions | |
Enable-RemoteDesktop | |
Disable-UAC | |
Disable-InternetExplorerESC | |
cinst git.install -y -params '"/GitAndUnixToolsOnPath"' | |
cinst virtualbox -y | |
cinst vagrant -y | |
cinst packer -y | |
cinst packer-windows-plugins -pre -y | |
cinst awstools.powershell -y | |
cinst javaruntime -y | |
cinst teamcityagent -y -params "serverurl=http://builds.seek.int agentName=$env:COMPUTERNAME agentDir=$env:SystemDrive/buildAgent" | |
choco install golang -y | |
choco install hg -y | |
# Go | |
$env:GOPATH = "${env:SystemDrive}\go" | |
If ( -not (Test-Path $env:GOPATH) ) { | |
mkdir $env:GOPATH | |
[Environment]::SetEnvironmentVariable("GOPATH", $env:GOPATH, "Machine") | |
$env:path+="${env:GOPATH}\bin" | |
[Environment]::SetEnvironmentVariable("PATH", $env:path, "Machine") | |
} | |
# packer s3 upload plugin | |
go get github.com/lmars/packer-post-processor-vagrant-s3 | |
cp "${env:GOPATH}\bin\packer-*" "${env:APPDATA}\packer.d\plugins\" | |
# team city environment variables: | |
Add-Content "${env:SystemDrive}\buildAgent\conf\buildAgent.properties" "`nenv.PACKER_VERSION=0.7.5" | |
Add-Content "${env:SystemDrive}\buildAgent\conf\buildAgent.properties" "`nenv.PACKER_WINDOWS=1.0.0-RC" | |
Add-Content "${env:SystemDrive}\buildAgent\conf\buildAgent.properties" "`nenv.PACKER_POST_PROCESSOR_VAGRANT_S3_VERSION=0.0.1" # NOTE: there currently is no version. Consider git hash? | |
Add-Content "${env:SystemDrive}\buildAgent\conf\buildAgent.properties" "`nenv.VAGRANT_VERSION=1.7" | |
Add-Content "${env:SystemDrive}\buildAgent\conf\buildAgent.properties" "`nenv.VIRTUALBOX_VERSION=4.3" | |
cmd.exe /c netsh firewall add portopening TCP 9090 "Port 9090 for TC" | |
# WinRM | |
cmd.exe /c winrm quickconfig -q | |
cmd.exe /c winrm quickconfig '-transport:http' | |
cmd.exe /c winrm set "winrm/config" '@{MaxTimeoutms="1800000"}' | |
cmd.exe /c winrm set "winrm/config/winrs" '@{MaxMemoryPerShellMB="1024"}' | |
cmd.exe /c winrm set "winrm/config/service" '@{AllowUnencrypted="true"}' | |
cmd.exe /c winrm set "winrm/config/client" '@{AllowUnencrypted="true"}' | |
cmd.exe /c winrm set "winrm/config/service/auth" '@{Basic="true"}' | |
cmd.exe /c winrm set "winrm/config/client/auth" '@{Basic="true"}' | |
cmd.exe /c winrm set "winrm/config/service/auth" '@{CredSSP="true"}' | |
cmd.exe /c winrm set "winrm/config/listener?Address=*+Transport=HTTP" '@{Port="5985"}' | |
cmd.exe /c netsh advfirewall firewall set rule group="remote administration" new enable=yes | |
cmd.exe /c netsh firewall add portopening TCP 5985 "Port 5985" | |
cmd.exe /c net stop winrm | |
cmd.exe /c sc config winrm start= auto | |
cmd.exe /c net start winrm |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Setup