Passo-a-passo detalhado do skill, referenciando as fases cognitivas:
1SENSE — Coletar requisitos
Identificar imagem, porta, env vars e volumes da aplicação
Determinar SLOs: disponibilidade (99.9%?), latência p95 (<200ms?)
2CONTEXTUALIZE — Analisar cluster
```bash
kubectl get nodes -o custom-columns='NAME:.metadata.name,CPU:.status.capacity.cpu,MEM:.status.capacity.memory'
kubectl get ingressclass # verificar Ingress controller
kubectl get storageclass # verificar StorageClass disponíveis
kubectl top nodes # verificar utilização atual
```
3RECOMMEND — Gerar Deployment
```yaml
apiVersion: apps/v1
kind: Deployment
metadata:
name: my-app
namespace: production
spec:
replicas: 3
strategy:
type: RollingUpdate
rollingUpdate: { maxUnavailable: 0, maxSurge: 1 }
selector:
matchLabels: { app: my-app }
template:
metadata:
labels: { app: my-app }
spec:
containers:
name: my-app
image: registry.io/my-app:v1.2.3
ports: [{ containerPort: 3000 }]
resources:
requests: { cpu: "100m", memory: "256Mi" }
limits: { cpu: "500m", memory: "512Mi" }
readinessProbe:
httpGet: { path: /health/ready, port: 3000 }
initialDelaySeconds: 15
periodSeconds: 10
failureThreshold: 3
livenessProbe:
httpGet: { path: /health/live, port: 3000 }
initialDelaySeconds: 30
periodSeconds: 20
envFrom:
configMapRef: { name: my-app-config }
secretRef: { name: my-app-secrets }
```
```yaml
apiVersion: autoscaling/v2
kind: HorizontalPodAutoscaler
spec:
scaleTargetRef: { apiVersion: apps/v1, kind: Deployment, name: my-app }
minReplicas: 2
maxReplicas: 20
metrics:
type: Resource
resource: { name: cpu, target: { type: Utilization, averageUtilization: 65 } }
```
5EVALUATE — Validar manifests
```bash
kubectl apply --dry-run=server -f k8s/
kubectl diff -f k8s/
```
6REFLECT — Deploy e monitoramento
```bash
kubectl apply -f k8s/
kubectl rollout status deployment/my-app
kubectl top pods -n production
```
Reportar telemetria via mcp-skillschain