Minimal & lightweight docker image including Azure and Terraform CLI
Last updated Apr 13, 2026
33
Stars
37
Forks
35
Issues
0
Stars/day
Attention Score
59
Topics
Language breakdown
Dockerfile 59.0%
Shell 41.0%
▸ Files
click to expand
README
Terraform and Azure CLI Docker image
📦 Supported tags and respective Dockerfile links
Available image tags can be found on the Docker Hub registry: zenika/terraform-azure-cliSupported versions are listed in the supported_versions.json file in project root folder.
The following image tag strategy is applied:
zenika/terraform-azure-cli:latest- build from master
supported_versions.json file. zenika/terraform-azure-cli:release-S.Tterraform-UU.VV.WWazcli-XX.YY.ZZ- build from releases
release-S.T is the release tag * terraform-UU.VV.WWW is the included Terraform CLI version * azcli-XX.YY.ZZ is the included Azure CLI version
Please report to the releases page for the changelogs.
Any other tags are not supported even if available.
💡 Motivation
The goal is to create a minimalist and lightweight image with these tools in order to reduce network and storage impact.This image gives you the flexibility to be used either for development or as a base image as you see fits.
🔧 What's inside ?
- Azure CLI:
- Terraform CLI:
- Git
- Python 3
- This image use a non root user with a GID and UID of 1001 to conform with docker security best practices.
🚀 Usage
🐚 Launch the CLI
Simply launch the container and use the CLI as you would on any other platform, for instance using the latest image:docker container run -it --rm --mount type=bind,source="$(pwd)",target=/workspace zenika/terraform-azure-cli:latest
The --rm flag will completely destroy the container and its data on exit.
⚙️ Build the image
You can build the image locally directly from the Dockerfile, using the build script.It will :
- Lint the Dockerfile with Hadolint;
- Build and tag the image
zenika/terraform-azure-cli:dev; - Execute container structure tests on the image.
# launch dev script using latest supported versions for both Azure and Terraform CLI ./dev.sh
Optionally, it is possible to choose the tools desired versions:
# Set desired tool versions
AZURECLIVERSION=2.24.2
TERRAFORM_VERSION=0.15.5
launch dev script with parameters
./dev.sh $AZURECLIVERSION $TERRAFORM_VERSION
🙏 Roadmap & Contributions
Please refer to the github project to track new features.Do not hesitate to contribute by filling an issue or opening a PR !
⬆️ Dependencies upgrades checklist
- Supported versions:
- Dockerfile:
- Github actions:
- Build scripts:
- Readme:
🚩 Similar repositories
- For AWS: zenika-open-source/terraform-aws-cli
📖 License
This project is under the Apache License 2.0🔗 More in this category

