This repo creates a Docker image for the STM32 Command Line Tools (CLT).
A ubuntu environment is recommended for building. WSL can be used on Windows.
There are a few manual steps involved.
This image contains the STM32CubeCLT package (located at /opt/st) and is based on
Ubuntu 24.04 with CMake installed using KitWare's APT repository and clang and pip3
installed using the standard Ubuntu repository. To use the package, pull
ghcr.io/revrobotics/stm32cubeclt:<version>.
- Download the STM32 CLT installer for Linux (DEB). It must be the DEB version.
- Extract the downloaded file ending in .deb_bundle.sh to this directory
- Update the COPY command in the Dockerfile with the script name
- run docker build -t ghcr.io/<organization name>/stm32cubeclt:<version> .
- run docker run -it ghcr.io/<organization name>/stm32cubeclt:<version> /install.sh
- Accept the license by pressing down arrow until you see the prompt for y/N (You must press down arrow exactly enough times to reach the prompt. It will reject the license if you press the down arrow again)
- run docker ps -ato find the container id
- run docker commit <container id from before> ghcr.io/<organization name>/stm32cubeclt:<version>
- Create a PAT for your GitHub account
- run echo $CR_PAT | docker login ghcr.io -u USERNAME --password-stdinto login to docker
- run docker push ghcr.io/<organization name>/stm32cubeclt:<version>