Official Repository

Last pushed: 14 days ago
Short Description
Busybox base image.
Full Description

Supported tags and respective Dockerfile links

For more information about this image and its history, please see the relevant manifest file (library/busybox). This image is updated via pull requests to the docker-library/official-images GitHub repo.

For detailed information about the virtual/transfer sizes and individual layers of each of the above supported tags, please see the repos/busybox/tag-details.md file in the docker-library/repo-info GitHub repo.

What is BusyBox? The Swiss Army Knife of Embedded Linux

Coming in somewhere between 1 and 5 Mb in on-disk size (depending on the variant), BusyBox is a very good ingredient to craft space-efficient distributions.

BusyBox combines tiny versions of many common UNIX utilities into a single small executable. It provides replacements for most of the utilities you usually find in GNU fileutils, shellutils, etc. The utilities in BusyBox generally have fewer options than their full-featured GNU cousins; however, the options that are included provide the expected functionality and behave very much like their GNU counterparts. BusyBox provides a fairly complete environment for any small or embedded system.

wikipedia.org/wiki/BusyBox

How to use this image

Run BusyBox shell

$ docker run -it --rm busybox

This will drop you into an sh shell to allow you to do what you want inside a BusyBox system.

Create a Dockerfile for a binary

FROM busybox
COPY ./my-static-binary /my-static-binary
CMD ["/my-static-binary"]

This Dockerfile will allow you to create a minimal image for your statically compiled binary. You will have to compile the binary in some other place like another container. For a simpler alternative that's similarly tiny but easier to extend, see alpine.

Image Variants

This image contains BusyBox built against various "libc" variants (for a comparison of "libc" variants, Eta Labs has a very nice chart which lists many similarities and differences).

For more information about the specific particulars of the build process for each variant, see Dockerfile.builder in the same directory as each variant's Dockerfile (see links above).

License

View license information for the software contained in this image.

Supported Docker versions

This image is officially supported on Docker version 17.03.0-ce.

Support for older versions (down to 1.6) is provided on a best-effort basis.

Please see the Docker installation documentation for details on how to upgrade your Docker daemon.

User Feedback

Issues

If you have any problems with or questions about this image, please contact us through a GitHub issue. If the issue is related to a CVE, please check for a cve-tracker issue on the official-images repository first.

You can also reach many of the official image maintainers via the #docker-library IRC channel on Freenode.

Contributing

You are invited to contribute new features, fixes, or updates, large or small; we are always thrilled to receive pull requests, and do our best to process them as fast as we can.

Before you start to code, we recommend discussing your plans through a GitHub issue, especially for more ambitious contributions. This gives other contributors a chance to point you in the right direction, give you feedback on your design, and help you find out if someone else is working on the same thing.

Documentation

Documentation for this image is stored in the busybox/ directory of the docker-library/docs GitHub repo. Be sure to familiarize yourself with the repository's README.md file before attempting a pull request.

Docker Pull Command

Comments (18)
tak9
5 months ago

Where is procedure to create program working with this image?
System, packages,compilers.
Meybe Makefile with all important information?
Simple, small program in C.

jugdog
7 months ago

Really handy, thanks

josefuentes
a year ago

How can I find the Dockerfile that was used to create the official BusyBox image?

https://github.com/docker-library/busybox/blob/de53df881f8a7cad77fe9e2042ee0a8d38402ce3/uclibc/Dockerfile

trevorsullivan
a year ago

How can I find the Dockerfile that was used to create the official BusyBox image?

ychch9
a year ago

dd

turn8888
a year ago

123

jesskay
2 years ago

@hourback

true is a standard unix utility which does nothing except return a success exit code. It's run there so that something other than the default busybox shell runs inside the container.

aleksandrvin
2 years ago

Very impressed, thank you!

docker run --rm busybox du -h -s /
2.6M    /
dreamcat4
2 years ago

For the default latest tag - the version of TAR does not have decompress options. It would be great if you could update this default busybox tag to a newer version. That inlcude z decompression option(s) for the tar program. Many thanks.