Skip to content

Set Up a Linux CLI Environment on Windows

How-to · Updated Jun 2026

Set up a Linux CLI environment on Windows

The CLI examples throughout this documentation use bash, the default shell on Linux and macOS. If your local machine runs Windows, you need a Linux-compatible shell environment before following CLI, API, or Terraform guides.

This page covers four approaches. Pick the one that fits your workflow, then return to the guide you were reading.

Quick comparison#

ApproachBest forSetup timeLimitations
WSL 2Most users: full Linux on Windows5–10 minRequires Windows 10 1903+ or Windows 11
Git BashQuick CLI tasks when Git is already installed2–5 minNo package manager, limited GNU tools
Docker DesktopTeams standardizing on containers10–15 minLicensing requirements for large organizations
Quake AI VMExisting customers who want a persistent remote environment5 minRequires a Quake AI account and internet connection

Windows Subsystem for Linux (WSL 2) runs a full Linux kernel inside Windows. After setup, you open a terminal and work in Ubuntu exactly as the docs describe: bash, apt, curl, ssh, pip, and brew all work natively.

Install WSL#

Open PowerShell as Administrator and run:

bash
wsl --install

This installs WSL 2 with Ubuntu as the default distribution. Restart your machine when prompted.

For detailed instructions and troubleshooting, see the Microsoft WSL installation guide.

Open your Linux shell#

After restarting, open the Ubuntu app from the Start menu (or type wsl in any terminal). You are now in a bash shell.

Install CLI tools#

From inside your WSL terminal, install the tools used in Quake AI guides:

bash
sudo apt update && sudo apt install -y python3 python3-pip curl

Install the OpenStack CLI:

bash
pip3 install python-openstackclient

Install OpenTofu (for IaC guides):

bash
curl -fsSL https://get.opentofu.org/install-opentofu.sh | sh -s -- --install-method standalone

Verify#

bash
bash --version
openstack --version
tofu --version

Git bash#

Git for Windows bundles Git Bash, a minimal bash environment with curl, ssh, grep, awk, and other common Unix utilities. If you already have Git installed, Git Bash is ready to use.

Install#

Download and run the installer from gitforwindows.org. Accept the defaults.

Limitations#

Git Bash does not include a package manager (apt, brew). You cannot install the OpenStack CLI or OpenTofu directly inside Git Bash. Use Git Bash for guides that only require bash, curl, ssh, or git. For anything that needs package installation, use WSL 2 instead.

Verify (git bash)#

Open Git Bash from the Start menu and run:

bash
bash --version
curl --version
ssh -V

Docker desktop#

If you already use Docker, you can run CLI tools inside a Linux container without modifying your Windows environment.

Install (Docker desktop)#

Download Docker Desktop for Windows and complete the installation. Docker Desktop requires WSL 2 as its backend on modern Windows; the installer enables it automatically.

Run a Linux shell with CLI tools#

Start an Ubuntu container with your project files mounted:

bash
docker run -it --rm -v "%cd%":/work -w /work ubuntu:24.04 bash

Inside the container, install the tools you need:

bash
apt update && apt install -y python3 python3-pip curl
pip3 install python-openstackclient

Verify (Docker desktop)#

bash
bash --version
openstack --version

When you exit the container, installed tools are lost. To avoid reinstalling each time, create a Dockerfile with your tools pre-installed, or use a named volume.

SSH into a Quake AI VM#

If you have a Quake AI account, you can create a Linux VM and SSH into it from Windows. This gives you a full native Linux environment with no local setup beyond an SSH client (built into Windows 10+).

Create a VM#

Follow the Quickstart to create an Ubuntu instance on the Developer plan.

Connect via SSH#

Open PowerShell or Windows Terminal and connect:

bash
ssh ubuntu@YOUR_VM_IP

Replace YOUR_VM_IP with the floating IP assigned to your instance.

Install CLI tools (SSH into a Quake AI VM)#

Once connected, you are on a standard Ubuntu machine. Install tools as described in the WSL 2 section above:

bash
sudo apt update && sudo apt install -y python3 python3-pip curl
pip3 install python-openstackclient
curl -fsSL https://get.opentofu.org/install-opentofu.sh | sh -s -- --install-method standalone

Verify (SSH into a Quake AI VM)#

bash
openstack --version
tofu --version

Next steps#

Usage Guidelines

The sample code, software libraries, command line tools, proofs of concept, templates, and other related technology on this page (including any of the foregoing that is provided by Quake AI personnel) is provided to you as Quake AI Content under the Quake AI Customer Agreement, or the relevant written agreement between you and Quake AI (whichever applies). Do not use this Quake AI Content in your production accounts, or on production or other critical data. You are responsible for testing, securing, and optimizing the Quake AI Content (such as sample code) as appropriate for production grade use based on your specific quality control practices and standards. Deploying Quake AI Content may incur Quake AI charges for creating or using Quake AI chargeable resources, such as running Compute instances or storing data in Object Storage. Your use is also subject to the Acceptable Use Policy.

For the full policy, see Usage Guidelines.

Last validated: 04.06.2026

Was this page helpful?