Edit /etc/default/docker and add
DOCKER_OPTS="--dns 8.8.8.8 --dns 8.8.4.4 -g /home/user/docker"
replacing user by your user. That prevents filling /, depending on how your system is partitioned.
The base image is based on ubuntu and contains Java8, MongoDB, texlive. From the docker folder:
docker build -t base base (this may take a while; the resulting images is about 4.8GB, because of the full TeX installation)docker build -t server serverdocker build -t db dbdocker run -d -v /dbfs --name dbfs ubuntu true (run the database container)docker run -d --name db --volumes-from dbfs -p 27017:27017 db (run the database)docker run -d --name server --net host -v ~/tb/taskbase/:/taskbase server ant start -buildfile taskbase/build.xml -Darg0=local -Darg1=0 (run the server)Do not forget to replace the path ~/tb/ by the path where you cloned this github repository
To start the next time:
docker start db
docker start server
Remark: -Darg0 tells the server which properties file to load. Type -Darg0=local for default properties.
Caution: the database contents are stored in the database container. Deleting the latter would delete the database.
In the taskbase folder, run ant resolve to retrieve packages. Then you can run the server with docker run -d --name server --net host -v ~/tb/taskbase/:/taskbase server ant startfast -buildfile taskbase/build.xml -Darg0=local -Darg1=0
docker tag <IMAGEID> bersling/taskbase:base
docker push bersling/taskbase
See http://blog.eye48.com/post/98551740424/when-dockerio-eats-up-your-disc-space.
Note: this worked on my Fedora 20 machine, using two different partitions for the system and home directories!
Get root: sudo su
Stop the Docker demon: systemctl stop docker.service
Copy Docker files: cp -R /var/lib/docker/ /home/_varlibdockerfiles
Backup original Docker files: mv /var/lib/docker/ /var/lib/docker.backup
Add link to new Docker files: ln -s /home/_varlibdockerfiles/ /var/lib/docker
Start Docker demon again: systemctl start docker.service
Now you can test it by running one of your built Docker containers. You may run into an error like:
Error response from daemon: Error running DeviceCreate (createSnapDevice) dm_task_run failed.
That means you may have to repair the device mapper meta data:
Stop the Docker demon again: systemctl stop docker.service
thin_check /home/_varlibdockerfiles/devicemapper/devicemapper/metadata
If this do not show any errors, proceed with: thin_check --clear-needs-check-flag /home/_varlibdockerfiles/devicemapper/devicemapper/metadata
Start Docker demon: systemctl start docker.service
git clone https://github.com/jjoller/tb.git
cd tb/vagrant
vagrant up
vagrant ssh
cd tb/docker
docker build -t server base-light
docker run --name server --net host --net host -v ~/tb/taskbase/:/taskbase server ant start -buildfile taskbase/build.xml -Darg0=local -Darg1=0
Now you should be able to access taskbase at https://localhost:9999. To stop the server do: docker stop server. To start the server again run docker start -i server.
In case yo uwant to generate a self signed certificate:
openssl req -x509 -nodes -sha256 -days 365 -newkey rsa:2048 -keyout nginx.key -out nginx.crt
Access https://127.0.0.1:8443 in your browser.
Default username and password: [email protected] / givemegodpower
Content type
Image
Digest
sha256:8ced10497…
Size
2.9 GB
Last updated
over 9 years ago
docker pull jjoller/tb:base