agentleFS
NikoxkxNikoxkx/Agent-Skills/skills/devops/kubernetes-deployment/SKILL.md

kubernetes-deployment

Skill1 starsChanged 5 months agoApache-2.0View on GitHub

Creates Kubernetes manifests for deploying containerized applications with scaling, health checks, and resource limits. Use when deploying to any Kubernetes cluster (GKE, EKS, AKS, local).

1 other project uses a version of this.

Adopted by

Most recently taken up by

The file

We split this skill into the rules it gives an agent

4 rules. About 0 are common, 3 are distinctive, and 1 is very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈3

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 1

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    Run as non-root user.

    line 50
  2. Distinctive:

    Read-only root filesystem where possible.

    line 51
  3. Very specific:

    All YAML manifests in a k8s/ or manifests/ folder.

    line 56
  4. Distinctive:

    Zero-downtime deploys: Use maxSurge/maxUnavailable and proper probes.

    line 68

≈ “Common” is an estimate: at least 1 in 5 of the 350,495 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Overview

Produces complete, production-grade Kubernetes manifests (Deployment, Service, Ingress, ConfigMap, Secret, HorizontalPodAutoscaler, PodDisruptionBudget) with proper resource requests/limits, liveness/readiness probes, rolling update strategy, securityContext (non-root), and a basic Helm chart structure or Kustomize overlay for environment-specific configuration.

When to Use This Skill

  • Deploying a containerized app to Kubernetes for the first time or improving an existing deployment.
  • User mentions "Kubernetes", "k8s", "deploy to cluster", "EKS", "GKE", "AKS", or "Helm".

Prerequisites

  • A container image (built and pushed to a registry).
  • Access to a Kubernetes cluster (kubectl configured).
  • Domain and TLS certificate management (cert-manager recommended).

Steps

  1. Core objects:
    • Deployment with replicas, strategy (RollingUpdate), resources, probes, securityContext.
    • Service (ClusterIP or LoadBalancer).
    • Ingress (with TLS).
  2. Configuration:
    • ConfigMap for non-sensitive config.
    • Secret for sensitive data (or external-secrets operator).
  3. Autoscaling & resilience:
    • HorizontalPodAutoscaler (CPU + memory or custom metrics).
    • PodDisruptionBudget.
    • Pod anti-affinity for high availability.
  4. Probes:
    • livenessProbe (restart if unhealthy).
    • readinessProbe (remove from service if not ready).
    • startupProbe for slow-starting apps.
  5. Security:
    • Run as non-root user.
    • Read-only root filesystem where possible.
    • Drop all capabilities.
    • NetworkPolicy (deny all by default, allow only needed).
  6. Output:
    • All YAML manifests in a k8s/ or manifests/ folder.
    • Basic values.yaml for Helm if appropriate.
    • kubectl apply order and commands.
    • Verification steps (kubectl get, port-forward, logs).

Examples

Full set of manifests for a typical web app (Deployment + Service + Ingress + HPA + ConfigMap + Secret example) with comments and a simple Helm chart skeleton are included.

Edge Cases & Error Handling

  • Image pull secrets: For private registries.
  • Zero-downtime deploys: Use maxSurge/maxUnavailable and proper probes.
  • Stateful apps: Recommend StatefulSet + persistent volumes instead of Deployment.

Verification

  1. kubectl apply -f k8s/ succeeds.
  2. kubectl get pods — all Running and Ready.
  3. kubectl get hpa — scaling works when load is applied.
  4. App is reachable via Ingress.
  5. Rolling update completes without downtime.
  6. Success: App runs reliably, scales, self-heals, and follows security best practices.

References

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.