Skip to content

Latest commit

 

History

History
28 lines (18 loc) · 1.1 KB

README.md

File metadata and controls

28 lines (18 loc) · 1.1 KB

push2docker

You can use push2docker to create a Docker image that very closely resembles a Cloud Foundry droplet. push2docker takes a buildpack as an input and creates a Docker image with the same OS, file structure, and environment variables as a droplet.

Prerequisites

  1. Ubuntu 14.04 with Docker installed.

Usage

  1. Clone this project.
  2. In the push2docker directory run ./push <appName> -p <PATH> -b <BUILDPACK_URL> to create the Docker image. For example:
$  ./push ferret -p /samples/ferret.war -b https://github.com/cloudfoundry/java-buildpack

The <PATH> value for -p argument must be an absolute path to a file or a directory. You can also pass additional environment variables using -e option. For example:

$ ./push ferret -p /samples/ferret.war -b https://github.com/cloudfoundry/ibm-websphere-liberty-buildpack.git -e IBM_JVM_LICENSE=XXX -e IBM_LIBERTY_LICENSE=YYY
  1. The created Docker image will the tagged with the given <appName>. Once the image is created you can run it, for example:
$ docker run -p 8080:8080 -t ferret