Docker on Ubuntu - wyldckat/wyldckat.github.io GitHub Wiki
This is simply a bunch of cheat sheet notes I've been collecting on using Docker on Ubuntu 15.10.
- Instructions: https://docs.docker.com/linux/
- http://stackoverflow.com/questions/27701930/add-user-to-docker-container
- https://github.com/qnib/docker-openfoam/blob/u14.10_of231/Dockerfile
- https://docs.docker.com/engine/userguide/dockervolumes/
- http://stackoverflow.com/questions/19234831/where-are-docker-images-stored-on-the-host-machine
As root:
wget -qO- https://get.docker.com/ | sh
For not having to be root:
sudo usermod -aG docker ofuser
Log out then log back in.
docker run hello-world
Install Ubuntu 15.10 as a container:
docker run -it ubuntu:15.10 bash
Install Ubuntu 14.04.4 as a container:
docker run -it ubuntu:14.04.4 bash
This won't work:
add-apt-repository http://www.openfoam.org/download/ubuntu
Must use this:
echo "deb http://www.openfoam.org/download/ubuntu $(lsb_release -cs) main" > /etc/apt/sources.list.d/openfoam.list
Then:
apt-get update apt-get install openfoam30
But doing the last one:
apt-get install paraviewopenfoam44
won't do you any good, given that there is usually no X in the containers.
No ParaView will be built... although I guess that a headless installation would be neat :)
From here: http://openfoamwiki.net/index.php/Installation/Linux/OpenFOAM-dev/Ubuntu - we only need to run apt-get like this:
apt-get update apt-get install wget cmake git-core build-essential binutils-dev flex bison zlib1g-dev \ libreadline-dev libncurses-dev libopenmpi-dev openmpi-bin libboost-system-dev \ libboost-thread-dev libgmp-dev libmpfr-dev
then the rest is the usual building strategy... well, with the exception that you don't need to download ParaView's source code, nor run makeParaView.
After the build is over, the files were stored somewhere in a container folder at /var/lib/docker/aufs.
docker ps -a docker start CONTAINERID docker attach CONTAINERID