Skip to content

Instantly share code, notes, and snippets.

Last active Dec 4, 2015
What would you like to do?

With the following Dockerfile:

FROM debian:jessie
RUN cd /opt && mkdir nodebb
WORKDIR /opt/nodebb
RUN date > container_created.txt
CMD date > container_lastrun.txt ; /bin/bash

I built an image:

docker build --no-cache=true -t docker-sandbox .
touch /Users/ed/Dropbox/projects/docker-sandbox/app/bob.txt

Then I run the container with:

docker run 	--name docker-sandbox-1 -v /Users/ed/Dropbox/projects/docker-sandbox/app:/opt/nodebb -t -i docker-sandbox

What should I see?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment