Skip to content

Latest commit

 

History

History
104 lines (75 loc) · 3.55 KB

ch01-setup.adoc

File metadata and controls

104 lines (75 loc) · 3.55 KB

Setup Environments

This section describes the hardware and software needed for this workshop, and how to configure them. This workshop is designed for a BYOL (Brying Your Own Laptop) style hands-on-lab.

Hardware

  1. Operating System: Mac OS X (10.10+), Windows 10 Pro+, Ubuntu 12+, CentOS 7+

  2. Memory: At least 4 GB+, preferred 8 GB

Install Docker

Docker runs natively on Mac, Windows and Linux. Follow the instructions to install Docker:

Note
Docker for Mac and Windows have requirements for a fairly recent operating system version. If your machine does not meet these requirements, then you need to install Docker Toolbox.

Complete set of operating systems are listed at Install Docker Engine.

Additional components

Install the following additional components:

Docker Toolbox Notes

Skip this section if you are not using Docker Toolbox for Mac or Windows.

  1. Default Docker Machine: Docker Toolbox creates a Docker Machine named default. To make it easier to start/stop the containers, an entry is added into the host mapping table of your operating system.

    Find out IP address of your machine:

    docker-machine ip default

    This will provide the IP address associated with the Docker Machine created by Toolbox.

  2. Docker CLI Shell: Any Docker CLI command needs to be issued from the Terminal or Command Prompt where eval $(docker-machine env default) command was issued. This will make sure Docker CLI is configured to talk to the VM created by Docker Toolbox.

Setup Host Mapping

For Linux, Docker host is running on local machine and so the IP address would be 127.0.0.1.

Edit /etc/hosts (Mac OS or Linux) or C:\Windows\System32\drivers\etc\hosts (Windows) and add:

<IP ADDRESS>  dockerhost
<IP ADDRESS>  localhost

This allows to access Docker containers using dockerhost or localhost.

Download Images

This tutorial uses a few Docker images and software. Let’s download them before we start the tutorial.

Create a new file, name it docker-compose-pull-images.yml, and add the following content:

ubuntu:
  image: ubuntu
busybox:
  image: busybox
openjdk:
  image: openjdk
wildfly:
  image: jboss/wildfly
mysql:
  image: mysql
javaee7-hol:
  image: arungupta/javaee7-hol
swarm:
  image: swarm
wildfly-couchbase-javaee7:
  image: arungupta/wildfly-couchbase-javaee7
couchbase:
  image: arungupta/couchbase

Give the command to pull all the images:

docker-compose -f docker-compose-pull-images.yml pull
Note
For Linux, docker-compose and docker commands need sudo access. So prefix all commands with sudo.

Other Software

  1. Download Java IDE based upon your choice and install.

  2. Download Maven and install.

  3. Install Docker Cloud CLI following the instructions.