Skip to content

aiskillstore/marketplace / skills/abdelstark/infrastructure

infrastructure

Verified

Infrastructure as Code patterns for deploying Guts nodes using Terraform, Docker, and Kubernetes

Infrastructure Skill for Guts

You are managing infrastructure for a decentralized application with multiple node types.

Deployment Targets

  1. Local Development: Docker Compose
  2. Testing: Kubernetes (k3s/kind)
  3. Production: Cloud-agnostic Kubernetes + Terraform

Terraform Patterns

Module Structure

infra/
├── terraform/
│   ├── modules/
│   │   ├── network/
│   │   ├── compute/
│   │   └── storage/
│   ├── environments/
│   │   ├── dev/
│   │   ├── staging/
│   │   └── prod/
│   └── main.tf

Example Module

# modules/guts-node/main.tf
variable "node_count" {
  type        = number
  description = "Number of Guts nodes to deploy"
  default     = 3
}

variable "instance_type" {
  type        = string
  description = "Instance type for nodes"
  default     = "t3.medium"
}

resource "aws_instance" "guts_node" {
  count         = var.node_count
  ami           = data.aws_ami.ubuntu.id
  instance_type = var.instance_type

  tags = {
    Name        = "guts-node-${count.index}"
    Environment = var.environment
    Project     = "guts"
  }
}

Docker Best Practices

Multi-stage Builds

# Build stage
FROM rust:1.75-slim as builder
WORKDIR /app
COPY . .
RUN cargo build --release --bin guts-node

# Runtime stage
FROM debian:bookworm-slim
RUN apt-get update && apt-get install -y ca-certificates && rm -rf /var/lib/apt/lists/*
COPY --from=builder /app/target/release/guts-node /usr/local/bin/
EXPOSE 8080 9000
ENTRYPOINT ["guts-node"]

Docker Compose for Development

version: '3.8'

services:
  node1:
    build: .
    ports:
      - "8081:8080"
    environment:
      - GUTS_NODE_ID=node1
      - GUTS_PEERS=node2:9000,node3:9000
    volumes:
      - node1-data:/data

  node2:
    build: .
    ports:
      - "8082:8080"
    environment:
      - GUTS_NODE_ID=node2
      - GUTS_PEERS=node1:9000,node3:9000
    volumes:
      - node2-data:/data

  node3:
    build: .
    ports:
      - "8083:8080"
    environment:
      - GUTS_NODE_ID=node3
      - GUTS_PEERS=node1:9000,node2:9000
    volumes:
      - node3-data:/data

volumes:
  node1-data:
  node2-data:
  node3-data:

Kubernetes Patterns

StatefulSet for Nodes

apiVersion: apps/v1
kind: StatefulSet
metadata:
  name: guts-node
spec:
  serviceName: guts-nodes
  replicas: 3
  selector:
    matchLabels:
      app: guts-node
  template:
    metadata:
      labels:
        app: guts-node
    spec:
      containers:
      - name: guts-node
        image: guts/node:latest
        ports:
        - containerPort: 8080
          name: api
        - containerPort: 9000
          name: p2p
        volumeMounts:
        - name: data
          mountPath: /data
  volumeClaimTemplates:
  - metadata:
      name: data
    spec:
      accessModes: ["ReadWriteOnce"]
      resources:
        requests:
          storage: 100Gi

Monitoring Stack

  • Metrics: Prometheus with custom Rust metrics
  • Logs: Loki + Grafana
  • Tracing: Jaeger with OpenTelemetry

Security Checklist

  • TLS certificates via cert-manager
  • Network policies for pod isolation
  • Secrets management with external-secrets
  • Regular security scanning with Trivy
  • RBAC for Kubernetes access
writing-skillsobra/superpowersUse when creating new skills, editing existing skills, or verifying skills work before deploymentStars: 322kUpdated Claude CodeCodexVerifiedInstall
xlsxanthropics/skillsUse this skill any time a spreadsheet file is the primary input or output. This means any task where the user wants to: open, read, edit, or fix an existing .xlsx, .xlsm, .xltx, .csv, or .tsv file (e.g., adding columns, computing formulas, formatting, charting, cleaning messy data); create a new spreadsheet from scratch or from other data sources; or convert between tabular file formats. Trigger especially when the user references a spreadsheet file by name or path — even casually (like "the xlsx in my downloads") — and wants something done to it or produced from it. Also trigger for cleaning or restructuring messy tabular data files (malformed rows, misplaced headers, junk data) into proper spreadsheets. The deliverable must be a spreadsheet file. Do NOT trigger when the primary deliverable is a Word document, HTML report, standalone Python script, database pipeline, or Google Sheets API integration, even if tabular data is involved.Stars: 197kUpdated Claude CodeCodexVerifiedInstall
shipping-and-launchaddyosmani/agent-skillsPrepares production launches. Use when preparing to deploy to production, or when asking what needs to be in place before shipping. Use when you need a pre-launch checklist, when setting up monitoring, when planning a staged rollout, or when you need a rollback strategy.Stars: 119kUpdated Claude CodeCodexVerifiedInstall
childhoodthedotmack/claude-memBabysit a shipped release after merge, publication, or deployment. Verify published packages, production behavior, installed plugins, and late CI or user reports until the observation window is clean; use babysit for PR readiness before release.Stars: 118kUpdated Claude CodeCodexVerifiedInstall