Chapter 4. Container images with Rust Toolset

Rust Toolset is available as container images for RHEL 7 and RHEL 8. It can be downloaded from the Red Hat Container Registry.

4.1. Image contents

The RHEL 7 and RHEL 8 container images provide content corresponding to the following package:





4.2. Accessing the images

To pull the image, run the following command as root:

# podman pull
# podman pull

4.3. Using as builder images with Source-to-Image

Rust Toolset container image is prepared for use as a Source-to-Image (S2I) builder image.

Example 4.1. Building a Rust application image using Source-to-Image

To build the rust-test-app from its GitHub repository, complete the following steps.


  • Run the following commands to prepare the builder image:
 $ git clone
 $ cd s2i-rust
 $ make build


Use the s2i tool to build the rust-test-app by running the following command:

s2i build ./examples/test-app/ devtools/rust-toolset-rhel7 rust-test-app

To run the image, type the following into the command line:

$ docker run rust-test-app

A locally available application image rust-test-app is built using the rust-toolset container image.

To fully leverage the Rust as a S2I builder image, build custom images based on it, with modified S2I assemble scripts and further modifications to accomodate the particular application being built.

A detailed description of the Rust usage with Source-to-Image is beyond the scope of this document. For more information about Source-to-Image, see:

4.4. Additional resources