You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Docker images are HUGE. A simple hello world node app easily takes up > 600MB space.
Downloading/uploading these images can a looong time.
To fix this torrent-docker implements a union file system that allows you to mount a docker image
shared using bittorrent and boot a container - all in realtime!
Usage
Seed a docker image
First create a docker image
FROM ubuntu:14.04
RUN apt-get update && apt-get install -qy curl vim
Then build it
docker build -t test-image .
Now all we need to do is create a torrent from the docker image
torrent-docker create test-image
This creates a file test-image.torrent and a data folder test-image/.
Share this torrent using your favorite torrent client or do
torrent-docker seed test-image.torrent # will print a activity log
Realtime boot the docker image
Now copy test-image.torrent to another machine.
To boot the image do
This will mount the torrent as a union file system (that is writable!) and boot the docker image.
In addition it will also seed the torrent which means the more containers you boot the more the torrent will be seeded.
You can attach to the debug log to see download speed, how many peers your are connected to, which files are being accessed etc using
nc localhost 10000 # will tail the debug log from the boot process
After a couple of seconds (depending on your internet connection, ymmw) you should be attached to a bash process
running in your image! If for some reason your boot process cannot find a seeder you can specify them doing