मुख्य सामग्री पर जाएँ
Skillpedia
डिप्लॉय और क्लाउड (DevOps)280k · #198

kubernetes-patterns

यह क्या करती है

यह एजेंट आपको Kubernetes पर applications बनाने और manage करने में मदद करता है। Kubernetes एक system है जो computers पर programs को व्यवस्थित करने और चलाने का काम करता है। यह तैयार templates और tips देता है ताकि आपके applications अच्छे और सुरक्षित तरीके से चलें।

कब इस्तेमाल करें

  • ✓जब Kubernetes पर अपने applications के लिए configuration code लिख रहे हों।
  • ✓जब यह तय करना हो कि आपके applications कैसा व्यवहार करें (जैसे, कितना resource इस्तेमाल करें, यह कैसे जांचें कि वे काम कर रहे हैं)।
  • ✓जब यह पता लगाना हो कि कोई application Kubernetes पर काम करना क्यों बंद हो गया।

Skill का लिंक

https://github.com/affaan-m/ECC/blob/main/pi/core/skills/kubernetes-patterns/SKILL.md

इसे कॉपी करके अपने AI (Claude, ChatGPT या Cursor) में पेस्ट करें और निर्देशों का पालन करने को कहें।

कैसे इस्तेमाल करें

सबसे आसान तरीका: मैसेज कॉपी करके अपने AI में पेस्ट करें। वह skill पढ़कर निर्देशों का पालन करेगा।

पेस्ट करने के लिए तैयार मैसेज

इस skill से मेरी मदद करो: https://github.com/affaan-m/ECC/blob/main/pi/core/skills/kubernetes-patterns/SKILL.md इस लिंक की SKILL.md फ़ाइल पढ़ो और मेरे काम में उसके निर्देशों का पालन करो।
क्या आप चाहते हैं कि आपका AI ऐसी skills खुद ढूँढे?मुफ़्त Skillpedia MCP इंस्टॉल करें: बस एक लाइन, और हर काम से पहले यह 15,000+ skills में खोजता है।1 मिनट में इंस्टॉल करें →

AI से क्या माँगें: उदाहरण

“मुझे एक simple web application को Kubernetes पर चलाने के लिए एक configuration template दो, जिसमें security और health checks हों।”

हर हफ़्ते 5 नई skills, 1 मिनट में पढ़ें।

यह कैसे काम करती है

यह code के उदाहरण देकर काम करता है (जिन्हें 'manifests' या 'YAML' कहते हैं) जिन्हें आप copy-paste कर सकते हैं। यह problems ढूंढने और ठीक करने में मदद करने के लिए commands भी देता है।

तकनीकी सामग्री (मूल SKILL.md)

लेखक का मूल टेक्स्ट, अंग्रेज़ी में, सीधे GitHub से।

Kubernetes Patterns

Production-grade Kubernetes patterns for deploying, managing, and debugging workloads reliably.

When to Activate

  • Writing Kubernetes manifests (Deployments, Services, Ingress, Jobs)
  • Configuring resource requests/limits, liveness/readiness probes
  • Setting up RBAC, namespaces, or ServiceAccounts
  • Managing configuration and secrets in K8s
  • Debugging CrashLoopBackOff, OOMKilled, pending pods, or image pull errors
  • Configuring HPA (Horizontal Pod Autoscaler) or PodDisruptionBudgets
  • Reviewing K8s YAML for security or correctness

When to Use

Same as When to Activate above. This alias satisfies repo skill-format conventions. Use this skill any time you are writing, reviewing, or debugging Kubernetes YAML and workloads.

How It Works

This skill provides copy-pasteable, production-grade YAML patterns and kubectl debugging commands organized by task:

  1. Deployment template — A fully configured production Deployment with security context, rolling update strategy, all three probe types, resource limits, and environment injection from ConfigMap/Secret.
  2. Probes — Decision table for startup vs liveness vs readiness, with correct failureThreshold × periodSeconds math.
  3. Services & Ingress — ClusterIP, LoadBalancer, and TLS Ingress patterns with cert-manager annotations.
  4. ConfigMaps & Secrets — envFrom, file-mount, and external secrets guidance.
  5. Resource management — Requests vs limits rules of thumb by workload type (web API, JVM, worker, sidecar).
  6. RBAC — Least-privilege ServiceAccount → Role → RoleBinding chain.
  7. HPA & PDB — Autoscaling and node-drain safety configurations.
  8. Jobs & CronJobs — One-off and scheduled workload patterns with correct restartPolicy.
  9. kubectl cheatsheet — Logs, exec, rollback, port-forward, dry-run, and common error diagnosis commands.
  10. Anti-patterns & checklist — What NOT to do, and a security/reliability/observability checklist.

Examples

See the sections below for complete, runnable examples. Quick references:

Task Jump to
Full production Deployment YAML Core Workload Patterns
Probe configuration Probes
RBAC least-privilege setup RBAC
Debug a CrashLoopBackOff kubectl Debugging Cheatsheet
Autoscaling HPA

Core Workload Patterns

Deployment — Production Template

apiVersion: apps/v1
kind: Deployment
metadata:
  name: my-app
  namespace: my-namespace
  labels:
    app: my-app
    version: "1.0.0"
spec:
  replicas: 3
  selector:
    matchLabels:
      app: my-app
  strategy:
    type: RollingUpdate
    rollingUpdate:
      maxSurge: 1          # Allow 1 extra pod during update
      maxUnavailable: 0    # Never reduce below desired count
  template:
    metadata:
      labels:
        app: my-app
        version: "1.0.0"
    spec:
      # Security context at pod level
      securityContext:
        runAsNonRoot: true
        runAsUser: 1001
        fsGroup: 1001

      # Graceful shutdown
      terminationGracePeriodSeconds: 30

      containers:
        - name: my-app
          image: ghcr.io/org/my-app:1.0.0   # Never use :latest
          imagePullPolicy: IfNotPresent

          ports:
            - containerPort: 8080
              protocol: TCP

          # Resource requests AND limits are both required
          resources:
            requests:
              cpu: "100m"
              memory: "128Mi"
            limits:
              cpu: "500m"
              memory: "256Mi"

          # Container security context
          securityContext:
            allowPrivilegeEscalation: false
            readOnlyRootFilesystem: true
            capabilities:
              drop:
                - ALL

          # Probes (see Probes section below)
          startupProbe:
            httpGet:
              path: /health
              port: 8080
            failureThreshold: 30
            periodSeconds: 5
          livenessProbe:
            httpGet:
              path: /health
              port: 8080
            initialDelaySeconds: 0
            periodSeconds: 30
            failureThreshold: 3
          readinessProbe:
            httpGet:
              path: /ready
              port: 8080
            initialDelaySeconds: 5

…
अक्सर पूछे जाने वाले सवाल

Kubernetes क्या है?

Kubernetes एक system है जो कई computers पर चल रहे applications को manage और व्यवस्थित करने में मदद करता है। इसे आप अपने programs के लिए एक conductor की तरह समझ सकते हैं।

'manifests' या 'YAML' क्या होते हैं?

ये text files होती हैं जो बताती हैं कि आपके applications Kubernetes पर कैसे configure होने चाहिए और कैसे चलने चाहिए। इन्हें Kubernetes के लिए एक निर्देश पुस्तिका समझ सकते हैं।

'probes' (जांच) क्या होते हैं?

ये वे checks हैं जो Kubernetes यह जानने के लिए करता है कि आपका application सही चल रहा है (livenessProbe), traffic लेने के लिए तैयार है (readinessProbe), या शुरू हो चुका है (startupProbe)।

जानकारी

लेखक का मूल विवरण

Kubernetes workload patterns, resource management, RBAC, probes, autoscaling, ConfigMap/Secret handling, and kubectl debugging for production-grade deployments. Use when writing or reviewing Kubernetes manifests, or debugging probes, RBAC, autoscaling, or resource limits.

repo: affaan-m/ECC

लोकप्रियता

GitHub स्टार
280k
रैंकिंग में स्थान
#198
लाइसेंस
MIT
अपडेट की गई
15/10/2026

क्या यह skill काम की है?

0

लॉग इन करें वोट करने के लिए।

कमेंट

  • …

इस repository की और skills

accessibility

280k

यह आपके एजेंट को ऐसे इंटरफ़ेस बनाने में मदद करता है जिन्हें हर कोई इस्तेमाल कर सके। यह पक्का करता है कि वेबसाइट और ऐप दिव्यांग लोगों के लिए भी अच्छे से काम करें, जैसे नेत्रहीन या जिन्हें चलने-फिरने में दिक्कत होती है।

डिज़ाइनइंटरफ़ेस (UI/UX)

agent-architecture-audit

280k

यह आपके एजेंट को जाँचने देता है कि सब कुछ सही से चल रहा है। यह AI सिस्टम में समस्याएँ ढूँढकर ठीक करता है, ताकि वे उम्मीद के मुताबिक काम करें।

AI और एजेंटएजेंट

agent-eval

280k

यह आपके एजेंट को अलग-अलग AI coding tools की तुलना करने में मदद करता है। यह मापता है कि किसी खास काम के लिए कौन सा टूल ज़्यादा तेज़, सस्ता और भरोसेमंद है।

AI और एजेंटएजेंट

agent-harness-construction

280k

यह आपके एजेंट को काम कैसे करना है, यह बेहतर समझने में मदद करता है। यह उन tools और instructions को बेहतर बनाता है जिनका एजेंट इस्तेमाल करता है, ताकि उसकी सफलता की संभावना बढ़े।

AI और एजेंटएजेंट

मिलती-जुलती skills