GitHub Codespaces Dev Environment
AutoCloud includes a ready-to-use dev container configuration so you can start contributing or using the project instantly in GitHub Codespaces (or any dev container-compatible tool like VS Code Dev Containers).
Quick Start​
Option 1: GitHub Codespaces (recommended)​
- Navigate to the AutoCloud repository.
- Click Code → Codespaces → Create codespace on main.
- Wait for the container to build and the post-create setup to finish.
- Sign in to Azure with
az loginwhen prompted.
Option 2: VS Code Dev Containers (local)​
- Install Docker Desktop and the Dev Containers extension.
- Clone the repository and open it in VS Code.
- When prompted, click Reopen in Container (or run the command
Dev Containers: Reopen in Container). - Sign in to Azure with
az login.
What's Included​
Base Image​
mcr.microsoft.com/devcontainers/base:ubuntu — a lightweight Ubuntu image maintained by Microsoft.
Dev Container Features​
| Feature | Version | Purpose |
|---|---|---|
| Azure CLI | latest | Azure resource management and deployments |
| GitHub CLI | latest | PR creation, issue management, workflow dispatch |
| Python | 3.12 | Checkov IaC scanner and scripting |
| Node.js | 20 | Tooling and automation scripts |
| PowerShell | latest | PSRule, ARM-TTK, and Azure PowerShell modules |
| Common utilities | — | Zsh with Oh My Zsh as default shell |
Post-Create Setup​
The post-create.sh script runs automatically after the container is built and installs:
- Checkov — IaC security scanner supporting ARM, Bicep, and Terraform templates.
- PSRule for Azure — WAF-aligned validation rules for ARM and Bicep templates.
- ARM-TTK — Microsoft's ARM Template Test Toolkit for template validation.
VS Code Extensions​
The following extensions are automatically installed in the container:
| Extension | Purpose |
|---|---|
| GitHub Copilot | AI coding assistant |
| GitHub Copilot Chat | Chat-based AI assistance |
| Azure Resource Groups | Browse and manage Azure resource groups |
| Azure Functions | Develop and deploy Azure Functions |
| Azure MCP Server | Azure MCP integration for Copilot agents |
| PSRule | Run PSRule validation from VS Code |
VS Code Settings​
The Azure MCP server is preconfigured with:
azureMcp.serverMode:namespace— organizes tools by Azure service.azureMcp.readOnly:false— allows read and write operations.
After Setup​
Once the environment is ready:
- Sign in to Azure: Run
az loginto authenticate. For Codespaces,az login --use-device-codeworks best. - Verify the setup: Run
az account showto confirm your subscription. - Start using AutoCloud: Open Copilot Chat and try
@autocloud deploy a Python function app.
Customization​
To add features or tools to the dev container:
- Dev container features: Add entries to the
featuresobject in.devcontainer/devcontainer.json. - Post-create tools: Add installation commands to
.devcontainer/post-create.sh. - VS Code extensions: Add extension IDs to
customizations.vscode.extensionsin.devcontainer/devcontainer.json.
Troubleshooting​
| Issue | Solution |
|---|---|
| Codespace build fails | Check the creation log for errors. Common cause: feature version conflicts. |
az login fails in Codespaces | Use az login --use-device-code for browser-based auth. |
| ARM-TTK not found | Run pwsh and verify the profile loaded: Get-Module arm-ttk -ListAvailable. |
| Checkov not found | Run pip install --user checkov manually. |
| Extensions missing | Reload the window (Ctrl+Shift+P → Developer: Reload Window). |