Public | Automated Build

Last pushed: 19 hours ago
Short Description
Creates a btrfs partition for docker-machine
Full Description

boot2docker-mkfs.btrfs

Creates a btrfs partition for docker-machine

Install

Create a new machine

docker-machine create -d virtualbox MACHINENAME

Create a new disk

VBoxManage createmedium --filename ~/.docker/machine/machines/MACHINENAME/docker.vmdk --format VMDK  --size 20000
VBoxManage storageattach MACHINENAME --storagectl "SATA" --device 0 --port 2 --type hdd --medium ~/.docker/machine/machines/MACHINENAME/docker.vmdk

Create the partition

docker run --rm --privileged -v /dev:/hostdev -e DEVICE=sdb themecloud/boot2docker-mkfs.btrfs

Mount the partition at boot and reboot the docker daemon

docker-machine ssh MACHINE_NAME "echo -e 'sudo mount -t btrfs /dev/sdb1 /var/lib/docker\nsudo /etc/init.d/docker restart' | sudo tee -a /var/lib/boot2docker/bootlocal.sh > /dev/null"
docker-machine ssh MACHINE_NAME "sudo mount -t btrfs /dev/sdb1 /var/lib/docker && sudo /etc/init.d/docker restart"

Enjoy!

Docker Pull Command
Owner
themecloud