Gandi/docker — pull request #6 by Mic92 (2014-11-27 10:54:49+00:00)
Title: Replace libzfs by zfs-utils

- Use go-zfs for robust handling of the commandline interface
- basic operation like create/destroy/clone works on my machine

**Usage** (a little bit more verbose for beginners):
- the following lines can be tested without messing up your current docker setup
- replace zroot/docker with your preferred zfs dataset

```
$ git clone https://github.com/Mic92/docker
$ cd docker
$ make
root> zfs create -o com.sun:auto-snapshot=false zroot/docker
root> mkdir /var/lib/docker-zfs
root> bundles/1.2.0-dev/binary/docker -p /var/run/docker-zfs.pid -H tcp://127.0.0.1:2376 -s zfs --storage-opt zfs.fsname=zroot/docker -g /var/lib/docker-zfs -d
# go to your favorite docker project and hit
$ export DOCKER_HOST=tcp://127.0.0.1:2376
$ docker --pidfile=/var/run/docker-zfs.pid -H unix:///var/run/docker-zfs.sock build .
```

Docker will also detect if `/var/lib/docker` is located on a zfs dataset and will use it.

**TODO**
- [ ] implement diff related apis
- [ ] integration test

Related to docker/docker#7901