Skip to content

Instantly share code, notes, and snippets.

@guiniol
Last active July 4, 2016 13:45
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save guiniol/ba66e3468edb44be3be8cfd733d6ea66 to your computer and use it in GitHub Desktop.
Save guiniol/ba66e3468edb44be3be8cfd733d6ea66 to your computer and use it in GitHub Desktop.
# -*- mode: ruby -*-
# vi: set ft=ruby :
Vagrant.configure(2) do |config|
config.vm.guest = :windows
config.vm.communicator = "winrm"
config.winrm.username = "IEUser"
config.winrm.password = "Passw0rd!"
end

Get the box file

  1. Download https://modernievirt.blob.core.windows.net/vhd/VMBuild_20140627/Vagrant/IE8.XP.For.Vagrant.box

Change local security settings

  1. Start >> Control Panel >> Administrative Tools >> Local Security Settings
  2. Security Settings >> Local Policies >> Security Options
  3. Select the Network Access : Sharing and security model for local accounts and set it to: Classic - Local Users authenticate as themselves
  4. Select: Security Settings >> Local Policies >> User Rights Assignment
  5. Make sure that the Access this computer from the network policy includes the Everyone or Administrators account.

Install necessary packages

  1. .Net Framework 2.0 SP1 https://www.microsoft.com/en-us/download/details.aspx?id=16614
  2. Windows Management Framework Core https://www.microsoft.com/en-us/download/details.aspx?id=16818

Configure WinRM

  1. winrm quickconfig -q
  2. winrm set winrm/config/winrs '@{MaxMemoryPerShellMB="512"}'
  3. winrm set winrm/config '@{MaxTimeoutms="1800000"}'
  4. winrm set winrm/config/service '@{AllowUnencrypted="true"}'
  5. winrm set winrm/config/service/auth '@{Basic="true"}'
  6. winrm set winrm/config/winrs '@{MaxShellsPerUser="100"}'
  7. winrm set winrm/config/winrs '@{MaxProcessesPerShell="100"}'
  8. winrm set winrm/config/service '@{MaxConcurrentOperationsPerUser="100"}'

Install mklink

  1. install Visual C++ Redistributable for VS2005 SP1 https://www.microsoft.com/en-us/download/details.aspx?id=5638
  2. install chocolatey @powershell -NoProfile -ExecutionPolicy Bypass -Command "iex ((new-object net.webclient).DownloadString('https://chocolatey.org/install.ps1'))" && SET PATH=%PATH%;%ALLUSERSPROFILE%\chocolatey\bin
  3. Allow executing scripts: set-executionpolicy unrestricted
  4. install win2003-mklink (in a new shell) choco install win2003-mklink
  5. If step 4 doesn't work, install an older version of chocolatey instead, which can be found at https://chocolatey.org/install-lastposhclient.ps1
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment