Cloud Architect - Guía de Entorno¶
Guía para configurar el entorno de trabajo de Cloud Architect con Claude Code.
Resumen de Capacidades¶
| Capacidad | Herramientas |
|---|---|
| AWS | AWS CLI, SAM, CDK, eksctl |
| Azure | Azure CLI, Bicep, AKS |
| GCP | gcloud CLI, Cloud SDK |
| Multi-cloud | Terraform, Pulumi, Crossplane |
| Containers | Docker, Kubernetes, Helm |
| Diagramas | Diagrams (Python), D2 |
AWS¶
AWS CLI¶
# Windows
winget install Amazon.AWSCLI
# macOS
brew install awscli
# Linux
curl "https://awscli.amazonaws.com/awscli-exe-linux-x86_64.zip" -o "awscliv2.zip"
unzip awscliv2.zip
sudo ./aws/install
# Verificar
aws --version
# Configurar
aws configure
# AWS Access Key ID: AKIA...
# AWS Secret Access Key: ...
# Default region: us-east-1
# Default output format: json
# Perfiles múltiples
aws configure --profile production
aws s3 ls --profile production
AWS SAM (Serverless)¶
# Instalar
brew install aws-sam-cli # macOS
pip install aws-sam-cli # pip
# Verificar
sam --version
# Comandos
sam init
sam build
sam local invoke
sam local start-api
sam deploy --guided
AWS CDK¶
# Instalar
npm install -g aws-cdk
# Verificar
cdk --version
# Comandos
cdk init app --language typescript
cdk synth
cdk diff
cdk deploy
cdk destroy
eksctl (EKS)¶
# Instalar
brew install eksctl # macOS
choco install eksctl # Windows
# Crear cluster
eksctl create cluster --name my-cluster --region us-east-1
# Listar clusters
eksctl get clusters
# Escalar
eksctl scale nodegroup --cluster my-cluster --name ng-1 --nodes 3
Azure¶
Azure CLI¶
# Windows
winget install Microsoft.AzureCLI
# macOS
brew install azure-cli
# Linux
curl -sL https://aka.ms/InstallAzureCLIDeb | sudo bash
# Verificar
az --version
# Login
az login
# Configurar suscripción
az account list
az account set --subscription "My Subscription"
Bicep¶
# Instalar (incluido con Azure CLI)
az bicep install
az bicep upgrade
# Comandos
az bicep build --file main.bicep
az deployment group create --resource-group rg --template-file main.bicep
# VS Code extension
code --install-extension ms-azuretools.vscode-bicep
Azure Developer CLI (azd)¶
# Instalar
winget install Microsoft.Azd # Windows
brew install azure/azd/azd # macOS
# Comandos
azd init
azd up
azd deploy
azd down
Google Cloud Platform¶
gcloud CLI¶
# Windows
(New-Object Net.WebClient).DownloadFile("https://dl.google.com/dl/cloudsdk/channels/rapid/GoogleCloudSDKInstaller.exe", "$env:Temp\GoogleCloudSDKInstaller.exe")
& $env:Temp\GoogleCloudSDKInstaller.exe
# macOS
brew install --cask google-cloud-sdk
# Linux
curl https://sdk.cloud.google.com | bash
# Verificar
gcloud --version
# Login
gcloud auth login
gcloud auth application-default login
# Configurar proyecto
gcloud config set project my-project
gcloud config list
GKE (Kubernetes)¶
# Instalar plugin auth
gcloud components install gke-gcloud-auth-plugin
# Crear cluster
gcloud container clusters create my-cluster \
--zone us-central1-a \
--num-nodes 3
# Obtener credenciales
gcloud container clusters get-credentials my-cluster
Cloud Run¶
Infrastructure as Code¶
Terraform¶
# Instalar
brew install terraform # macOS
winget install Hashicorp.Terraform # Windows
# Verificar
terraform --version
# Comandos
terraform init
terraform plan
terraform apply
terraform destroy
terraform fmt
terraform validate
terraform state list
Ejemplo básico:
# main.tf
terraform {
required_providers {
aws = {
source = "hashicorp/aws"
version = "~> 5.0"
}
}
}
provider "aws" {
region = "us-east-1"
}
resource "aws_s3_bucket" "example" {
bucket = "my-unique-bucket-name"
}
resource "aws_s3_bucket_versioning" "example" {
bucket = aws_s3_bucket.example.id
versioning_configuration {
status = "Enabled"
}
}
Pulumi¶
# Instalar
brew install pulumi # macOS
winget install Pulumi.Pulumi # Windows
# Login
pulumi login
# Nuevo proyecto
pulumi new aws-typescript
# Comandos
pulumi preview
pulumi up
pulumi destroy
pulumi stack ls
OpenTofu (Open-source Terraform)¶
# Instalar
brew install opentofu # macOS
# Comandos (compatible con Terraform)
tofu init
tofu plan
tofu apply
Kubernetes Tools¶
kubectl¶
# Instalar
brew install kubectl # macOS
winget install Kubernetes.kubectl # Windows
# Verificar
kubectl version --client
# Configurar contexto
kubectl config get-contexts
kubectl config use-context my-cluster
kubectl config current-context
Helm¶
# Instalar
brew install helm # macOS
winget install Helm.Helm # Windows
# Repositorios
helm repo add bitnami https://charts.bitnami.com/bitnami
helm repo update
# Instalar chart
helm install my-release bitnami/nginx
helm upgrade my-release bitnami/nginx
helm uninstall my-release
# Crear chart
helm create my-chart
k9s (Terminal UI)¶
Diagramas de Arquitectura¶
Diagrams (Python)¶
# architecture.py
from diagrams import Diagram, Cluster
from diagrams.aws.compute import ECS
from diagrams.aws.database import RDS
from diagrams.aws.network import ELB, Route53
with Diagram("Web Service", show=False):
dns = Route53("dns")
lb = ELB("lb")
with Cluster("Services"):
svc_group = [ECS("web1"),
ECS("web2"),
ECS("web3")]
db = RDS("userdb")
dns >> lb >> svc_group >> db
D2¶
Comandos que Claude Code Ejecutará¶
# AWS
aws s3 ls
aws ec2 describe-instances
sam build && sam deploy
cdk deploy
# Azure
az group list
az deployment group create
azd up
# GCP
gcloud compute instances list
gcloud run deploy
# Terraform
terraform init
terraform plan
terraform apply -auto-approve
# Kubernetes
kubectl get pods
kubectl apply -f manifest.yaml
helm install release chart/
# Diagramas
python architecture.py
d2 diagram.d2 output.svg
VS Code Extensions¶
code --install-extension hashicorp.terraform
code --install-extension ms-azuretools.vscode-azureterraform
code --install-extension amazonwebservices.aws-toolkit-vscode
code --install-extension ms-azuretools.vscode-bicep
code --install-extension googlecloudtools.cloudcode
code --install-extension ms-kubernetes-tools.vscode-kubernetes-tools
Verificación del Entorno¶
#!/bin/bash
echo "=== Verificación Entorno Cloud Architect ==="
echo -e "\n--- AWS ---"
aws --version 2>/dev/null || echo "AWS CLI no instalado"
sam --version 2>/dev/null || echo "SAM CLI no instalado"
cdk --version 2>/dev/null || echo "CDK no instalado"
echo -e "\n--- Azure ---"
az --version 2>/dev/null | head -1 || echo "Azure CLI no instalado"
echo -e "\n--- GCP ---"
gcloud --version 2>/dev/null | head -1 || echo "gcloud no instalado"
echo -e "\n--- IaC ---"
terraform --version 2>/dev/null | head -1 || echo "Terraform no instalado"
pulumi version 2>/dev/null || echo "Pulumi no instalado"
echo -e "\n--- Kubernetes ---"
kubectl version --client 2>/dev/null | head -1 || echo "kubectl no instalado"
helm version 2>/dev/null | head -1 || echo "Helm no instalado"
echo -e "\n=== Verificación Completa ==="