Meet a Docker written with Shell Script
A Docker implemented with only 100 lines of Bash.
Bocker is a Docker implemented with only 100 lines of Bash, or around that.
Prerequisites
The necessary packages for you to be able to run Bocker (the dependencies) are:
- btrfs-progs
- curl
- iproute2
- iptables
- libcgroup-tools
- util-linux> = 2.25.2
- coreutils> = 7.5
Since most distributions do not provide a new enough version of util-linux, you will probably need to take the sources from here and compile them yourself.
In addition, your system will need to be configured with the following:
A btrfs file system mounted on /var/bocker
- A bridge mode network named
bridge0
and an IP of10.0.0.1/24
- IP forwarding enabled in
/proc/sys/net/ipv4/ip_forward
- A firewall routing
bridge0
traffic to a physical interface.
For ease of use, a Vagrantfile is included, which will create the necessary environment.
Even if you meet the above prerequisites, you can probably still run Bocker on a virtual machine. Bocker runs as root
and, among other things, needs to make changes to its network interfaces, routing table and firewall rules. According to the developer, it is guaranteed that this will not destroy your system.
Example of use
Functionalities
Currently implemented
- docker build †
- docker pull
- docker images
- ps docker
- docker run
- docker exec
- docker logs
- docker commit
- rm docker/rmi docker
- Networking
- Support/CGroups Quota
Not implemented
- Data Volume Containers
- Date Volumes
- Port Forwarding
License
The Bocker license is GPL-3.0 License and the official project page is on GitHub: https://github.com/p8952/bocker
Comments