This project is still a work in progress.
This project aims to provide usage of docker on FreeBSD by installing and running dockerd inside a linux bhyve vm called dockerbox.
This repository (freebsd-docker
) holds the core files to run a dockerbox service, including rc script and configs.
freebsd-dockerbox-debian is the repository for dockerbox's underlying disk images.
freebsd-dockerbox-port holds dockerbox's port related files.
To install from source, clone this repository and run make install
.
# Install dockerbox script, config
make install
Download the dockerbox disk images.
make fetch-disk
Enable and start the dockerbox service.
service dockerbox enable
service dockerbox start
The make install
command automatically detects the default gateway interface for connecting to the Internet. To modify it, edit ext_if
specified in /usr/local/etc/dockerbox/dockerbox.conf
ext_if=ue0
Make sure you have docker
installed and dockerbox's disk image downloaded.
pkg install docker
service dockerbox fetch
Also install tools like grub2-bhyve
etc else you'll end up seeing error messages like pid 2859 (bhyve), jid 0, uid 0: exited on signal 6 (no core dump - other error)
when you start dockerbox.
pkg install grub2-bhyve
pkg install e2fsprogs
Starting dockerbox
service dockerbox start
Export DOCKER_HOST
.
export DOCKER_HOST=10.0.0.1:2375
Try out docker!
docker run hello-world
The ip address of dockerbox is currently fixed to 10.0.0.1
Stopping dockerbox
service dockerbox stop
Resize docker data storage.
dockerbox resize 1G
Currently only extending storage is supported.
Log is at /var/log/dockerbox.log