Skip to content

Leverage Docker For Your Development Environment Setup

rolivieri edited this page Sep 19, 2016 · 6 revisions

This page describes the steps I took for setting up my development environment for Kitura:

  1. Install Docker on your development system and start a Docker session/terminal.

  2. From the Docker session, pull down the swift-ubuntu image from Docker Hub:

docker pull ibmcom/swift-ubuntu:latest

  1. Create a Docker container using the swift-ubuntu image and mount the folder on your OS X system that contains the Kitura Swift package you are working on:

    docker run -i -t -v <absolute path to the swift package>:/root/<swift package name> ibmcom/swift-ubuntu:latest /bin/bash

    For example:

    docker run -i -t -v /Users/olivieri/git/Kitura/:/root/Kitura ibmcom/swift-ubuntu:latest /bin/bash

  2. Now you have access to the same source code files from your OS X system and Docker container. You can compile and test your code on OS X and also on Linux with minimal effort.