Skip to content
Search Fedora

    Browse this documentation

    Isolated development with Toolbox

    On Fedora, the usual answer to “install a pile of development tools without dirtying the host” is Toolbx: it provides a development environment through a container, yet feels almost like an ordinary command-line login. This page covers its scope and boundaries — especially the one the docs keep repeating: it is not a sandbox.

    Toolbx provides a development environment through a container: on Fedora Atomic Desktops, designed around a read-only root filesystem, it offers an environment where you can install tools and libraries like on a regular system; it also works on package-managed systems — isolation for development is not limited to immutable desktops.

    It brings four direct benefits:

    • The host stays clean and stable, instead of getting messy from a pile of development tools;
    • You can get a distribution environment different from the host for compatibility testing;
    • Dependencies of different projects are separated by the container boundary;
    • The environment is disposable: break it and rebuild, cheaper than repairing a polluted host.

    On a package-managed Fedora, installing Toolbx is one command: sudo dnf install toolbox; then toolbox create makes a container and toolbox enter goes into it, and exit or Ctrl+D leaves.

    • Atomic Desktops: Toolbx is preinstalled, so you can start with creating a container;
    • Name your containers: without arguments it names them automatically; with several projects, name them explicitly so you know later which ones are safe to remove;
    • Create once, enter many times: creation happens when needed; day to day you enter and leave.

    Where the image comes from: officially maintained Fedora images

    Section titled “Where the image comes from: officially maintained Fedora images”

    The official download page lists Fedora Container Toolbox as one of Fedora’s container images; Toolbx creates containers from officially maintained Fedora images, and inside you can install tools with dnf directly.

    • Why not grab any image: minimal distribution images contain almost no tools or documentation; the Fedora images maintained by the Toolbx team fill that gap so the environment is usable out of the box;
    • Defaults match the host: by default it uses the image matching the host release, falling back to the Fedora image when the host has none;
    • Choose release, distribution and image separately: when you need another release or distribution, specify it at creation time rather than changing it afterwards.

    Mounts and permissions: why it is not a sandbox

    Section titled “Mounts and permissions: why it is not a sandbox”

    The official docs make this an explicit warning: Toolbx containers are integrated with the host — what they provide is not just an isolated filesystem but an environment close to a regular Linux command line. Because of that integration, it loses some of the security that container technology could otherwise provide, and therefore should not be used as a sandbox.

    The test reduces to one sentence: you trust the code and just do not want it to mess up the host — use Toolbx; you do not trust the code — do not use Toolbx.

    Graphics and devices: what works, and what decides

    Section titled “Graphics and devices: what works, and what decides”

    Toolbx targets command-line workflows: once inside you have a shell with a package manager, and toolchains, compilation, testing and scripts are safest here. For graphical interfaces and devices:

    • Confirm the boundary first: how the container integrates with the host decides which resources are visible; follow the official docs and do not assume “container = isolated”;
    • Do not treat device passthrough as a default capability: cameras, serial ports and GPUs must be verified first; if verification fails, change the approach;
    • Use another tool when it is out of scope: whole-machine experiments, different kernels or drivers, or strong isolation belong in a VM or a separate machine, not forced into a development container.
    OptionGood forNot for
    Toolbxday-to-day development, trying toolchains, per-project dependency isolationrunning untrusted code, strong isolation
    General containersbuild pipelines, reproducible environments, deployment shape validationlong-lived hands-on debugging environments
    Virtual machineskernel and driver experiments, strong isolationlightweight environments rebuilt frequently

    The three can coexist: keep only the editor and version control on the host, put development in Toolbx, and describe builds and delivery with images. More container practice is in Fedora containers and rootless.

    • “A container is a sandbox”: the official docs explicitly reject that inference, for the reasons in the mounts and permissions section above;
    • “Toolbx is only for immutable desktops”: it was designed for read-only root systems, but it works on regular package-managed Fedora too;
    • “One container is enough”: when projects need different environments, separate containers by name are less work than upgrading and downgrading one container repeatedly;
    • “Uninstalling means deleting the container”: both containers and images can be cleaned up; confirm no other container depends on an image before removing it.

    F45 ships toolbox version 0.3. Cloud and Server images do not preinstall it:

    Terminal window
    sudo dnf install toolbox
    toolbox version
    toolbox version 0.3

    On the first create, if the image is not local yet, Toolbx asks first:

    Terminal window
    toolbox create --container t1
    Error: image required to create Toolbx container.
    Use option '--assumeyes' to download the image.

    Add --assumeyes (mandatory in automation, otherwise it blocks on the prompt):

    Terminal window
    toolbox create --container t1 --assumeyes
    Created container: t1
    Enter with: toolbox enter t1

    Confirm container and image:

    Terminal window
    toolbox list
    IMAGE ID IMAGE NAME CREATED
    e8a7b34fa61c registry.fedoraproject.org/fedora-toolbox:45 7 hours ago
    CONTAINER ID CONTAINER NAME CREATED STATUS IMAGE NAME
    41231b2a4455 t1 2 seconds ago created registry.fedoraproject.org/fedora-toolbox:45

    Run without entering:

    Terminal window
    toolbox run --container t1 cat /etc/fedora-release
    toolbox run --container t1 which dnf
    Fedora release 45 (Forty Five)
    /usr/bin/dnf

    Clean up:

    Terminal window
    toolbox rm t1
    toolbox rmi registry.fedoraproject.org/fedora-toolbox:45