Steps to create a docker image and setup the environment to be able to run CAF and
perform application lifecycle operations.

Prerequisite is to install docker on your system and pull the ubuntu:14.04 docker image.

1. Create a directory which serves as a source direcotry for the relevant data for the image to be built.
2. Copy the "Dockerfile" from "iox-dev/core/caf/config" to this source directory.
3. Copy the iox-dev code base to this source directory so that this will be copied to the built image.

    Now the content of your source directory will be
    * Dockerfile
    * iox-dev/

4. Change directory to the source directory where the Dockerfile and iox-dev code base is kept.
5. Build the docker image "ioxdev/caf:test" using below command.
    ""sudo docker build -t ioxdev/caf:test .

    Here "ioxdev/caf" is the repository name and "test" is the tag.

6. After the build is successful, verify the image "ioxdev/caf:test" is added to the list of docker images on the system.
    "sudo docker images"

7. Use this image to create containers running CAF instances, using below command.
    "sudo docker run -t -i -p 42000:8443 ioxdev/caf:test"

    You will be able to see a new container started, and the port 8443 from this container is mapped to system port 42000.
    "sudo docker ps -a"

9. Access CAF using the IP of your system and port 42000.

Reference URL for information about Dockerfile : http://docs.docker.com/reference/builder/
