Skip to main content
⏳ Estimated read time: 5 min read

Windows

This guide provides step-by-step instructions for installing and setting up the Cloud-to-Code CLI on Windows OS using either Docker or a standalone .exe file. It also covers the installation of Terraform.

Docker

Click to view

Follow the steps below to set up the Cloud-to-Code CLI on Windows OS using Docker.

Before You Begin

  • Recommended system requirements: 4 vCPU and 8 GB RAM.
  • Install Docker Desktop on your Windows system. If you have installed Docker already, you can use the CLI directly from the Docker container.

Install Cloud-to-Code CLI

Open your Windows Terminal and run the following command to pull the latest version of the Cloud-to-Code CLI image:

docker pull ghcr.io/stackgenhq/cloud2code

If you do not have Windows Terminal installed, run the command:

winget install --id Microsoft.WindowsTerminal -e

Install Terraform

Check if you’ve installed Terraform by running the following command:

terraform version

To install Terraform, run the following command:

tip

We recommend that you use Chocolatey for installing Terraform on Windows.

If you have Chocolatey installed, run:

choco install terraform

If you don’t have Chocolatey, install it from chocolatey.org.

Using .exe File

Click to view

1. Install Terraform

Check if you’ve installed Terraform by running the following command:

terraform version

To install Terraform, run the following command:

tip

We recommend that you use Chocolatey for installing Terraform on Windows.

If you have Chocolatey installed, run:

choco install terraform

If you don’t have Chocolatey, install it from chocolatey.org.

2. Downlodad cloud2code.exe

  1. To Download the .exe file, click the link https://releases.stackgen.com/binaries/v0.2.9/cloud2code_0.2.9_windows_amd64.zip.

  2. To update your Cloud-to-Code CLI with the latest version, run the following command:

If you have Chocolatey installed, run:

choco upgrade stackgen cloud2code

If you don’t have Chocolatey, install it from chocolatey.org.

3. Set up Cloud-to-Code CLI using .exe

To use the Cloud-to-Code CLI on Windows, add the folder containing the .exe file to your System Environment Variables under the Path variable. This lets you to run the Cloud-to-Code CLI directly from the terminal window.

Follow these steps to set up the Cloud-to-Code CLI:

  1. Extract the contents of the .zip file and save the executable (.exe) files in a folder you want to add to your system PATH.

  2. Open Start and search for Edit the system environment variables, and then open it.

  3. In the System Properties window, click Environment Variables.

  4. Under User variables, find and select the Path variable, then click Edit.

  5. In the Edit Environment Variable window, click New.

  6. Paste the full folder path where the .exe file is stored (e.g., C:\Tools\cloud2code), then click OK to save.

  7. Restart your terminal and run the Cloud-to-Code CLI to confirm it works:

    cloud2code --version

Your Cloud-to-Code installation is complete! To get started, follow the appropriate guide for your cloud provider to generate and deploy your infrastructure.