Skip to content

How to set up a Windows PC

David Chaiken edited this page Feb 7, 2018 · 25 revisions

Welcome!

This document describes how to install the software needed to perform the labs in this class on a Windows personal computer. We have purposefully kept the number of tools to a minimum: you'll need Git to load the source code onto your PC, and Docker to build, test, run, and ultimately deploy Limbo.

Installing Docker

Docker requires Windows 10 Pro. If you're interested in all of the requirements, see the What to know before you install section of the Docker for Windows installation page.

  • Before starting this installation, save all of your work because the process will log you out at least once and may require you to restart Windows.
  • In your browser, open the Download Docker for Windows web page and click on the "Get Docker for (Windows Stable)" box, which will download Docker for Windows Installer.exe. If Windows asks what you want to do with this download, select Run. You can also select "Save" and then run the installer after the download is complete.
  • Hit the Yes button on the dialog box that says, "Do you want to allow this app to make changes to your device?"
  • The installation process should result in a dialog box that provides the Docker for Windows version number and a message that says, "Installation succeeded." Click the button that says "Close and log out."
  • After logging back into Windows, you should see a message that says, " Docker is starting... This will only take a few seconds."
  • You may see a message that says, "Hyper-V and Containers features are not enabled. Do you want to eanble them for Docker to be able to work properly? Your computer will restart automatically." Hit the Ok button. If Windows does not restart automatically, restart manually.
  • You may see a message that says, "Containers feature is not enabled. Do you want to enable it for Docker to be able to work properly? Your computer will restart automatically." Hit the Ok button and wait for Windows to restart. If Windows does not restart automatically, restart manually.
  • You may see a message that says, "Hardware assisted virtualization and data execution protection must be enabled in the BIOS." Resolving this issue depends on the hardware manufacturer and the BIOS of your PC. The web page on enabling Virtualization in your PC BIOS has helpful instructions that cover a variety of hardware vendors. (This is an archived version of the web page in case the original disappears.)

Starting Docker

  • Windows should start Docker automatically after the last restart in the installation process documented above.
  • You may see a message that says, "Not enough memory to start Docker. You are trying to start Docker but you don't have enough memory. Free some memory of change your settings." If you see this message:
    • Hit the OK button.
    • In the system tray on the bottom of the screen, find the Docker whale. Do to the memory configuration problem, it will be red in color.
    • Right click on the Docker whale and select the "Settings..." option.
    • Click on the Advanced tab and move the memory slider from 2048MB to 1024MB.
    • Hit the Apply button.
    • You should see a message that says, "Docker is restarting. This may take some time."
  • Watch the Docker whale icon in the system tray. It should eventually stop moving. When you hover over the icon, it should say, "Docker is running."
  • To confirm that Docker is running, open a Windows PowerShell.
  • Running docker ps and docker images should result in output that looks like this:
> docker ps
CONTAINER ID        IMAGE               COMMAND             CREATED             STATUS              PORTS               NAMES
> docker images
REPOSITORY          TAG                 IMAGE ID            CREATED             SIZE

Troubleshooting Docker

If you see an error that looks like this during the labs:

An error occurred (InvalidSignatureException) when calling the CreateRepository operation: Signature expired: 20180206T123821Z is now earlier than 20180207T053403Z (20180207T054903Z - 15 min.)

there is likely clock skew in Docker, your Windows PC has been in sleep mode. To restart Docker:

  • Right-click on the Docker whale in the system tray and select "Settings..."
  • Select the Reset tab.
  • Select the "Restart Docker..." option.

Installing git

  • In your browser, open the Downloading git web page.
  • The git installer will start downloading automatically. Select "Run" when Windows asks what you want to do with the installer executable.
  • Hit the Yes button on the dialog box that says, "Do you want to allow this app to make changes to your device?"
  • Follow the following steps in the installer window:
    • Hit "Next" on the dialog box that shows the GNU General Public License.
    • Hit "Next" to accept the default Destination Location.
    • Hit "Next" to accept the default Components.
    • Hit "Next" to accept the default Start Menu Folder.
    • Select your preferred default editor, and then hit "Next."
    • Hit "Next" to Use Git from the Windows Command Prompt.
    • Hit "Next" to Use the OpenSSL library.
    • Hit "Next" to Checkout Windows-style, commit Unix-style line endings.
    • Select "Use Windows' default console window" and then hit "Next."
    • Do not modify the extra options, and hit "Install."
    • Wait for the installation to complete.
    • Unselect "View Release Notes."
    • Hit "Finish."
  • Close any open PowerShell windows, and open a new PowerShell window.
  • In PowerShell, run git --version and verify that the output looks something like this:
> git --version
git version 2.16.1.windows.2
  • In PowerShell, run the following command to enable compatibility between Unix and Windows line endings.
> git config --global core.autocrlf input

Installing WSL (Windows Subsystem for Linux)

Although WSL is not strictly required for the labs, consider installing compatibility with Linux to make it easier to work with other students and to get help from instructors. You can find the instructions for installing WSL on the Microsoft documentation web site.