Don't forget to set Docker host variable.
export DOCKER_HOST=tcp://192.168.59.103:2375I also had increase the memory and disk size of the image in the boot2docker config profile, see Boot2Docker CLI on how to update profile.
In the end I set memory=4096 and disk size=30000.
Make sure the build file is excutable, because I didn't which led to a permissions bonk.
chmod +x buildThen run:
docker build -t phantomjs2 .docker run -e VERSION=2.0.0-dev phantomjs2After it is done, which will be a long ass time, you can copy the binary back to host machine:
docker cp CONTAINER_ID:/home/phantomjs/bin/phantomjs-VERSION-lucid.tar.gz .Don't have time to figure out the 'RequestTimeTooSkewed' error, so try at your own risk
docker run -e VERSION=2.0.0-dev -e AWS_ACCESS_KEY_ID=key -e AWS_SECRET_ACCESS_KEY=secret -e BUCKET=s3bucket phantomjs2docker run -t -i phantomjs2 /bin/bash