[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"skill:01M79E22JB2MDKCF1SBQHRA4SQ":3,"skill-same:01M79E22JB2MDKCF1SBQHRA4SQ":60},{"skillNo":4,"name":5,"nameZh":6,"description":7,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":16,"categories":17,"keywords":18,"publishedAt":19,"linkOnly":20,"markdownContent":21,"markdownBody":22,"frontMatter":23,"refName":26,"commitSha":27,"skillDirectory":28,"forksCount":29,"repositoryHtmlUrl":30,"repositoryHomepageUrl":31,"ownerHtmlUrl":32,"ownerBlogUrl":33,"ownerDescription":34,"updatedAt":35,"install":36,"resources":49},"01M79E22JB2MDKCF1SBQHRA4SQ","gke-workload-scaling",null,"Manages scaling for GKE workloads using HPA and VPA. Use when configuring Horizontal Pod Autoscaler (HPA), configuring Vertical Pod Autoscaler (VPA), or applying best practices for GKE workload autoscaling. Do not use for cluster-level autoscaling (Cluster Autoscaler), static cluster sizing, or configuring node-level machine styles directly.","hamzabellouch\u002Fagent-skills","hamzabellouch","https:\u002F\u002Favatars.githubusercontent.com\u002Fu\u002F237856042?v=4","01M79BRYW7XAMK3YDWQEMTWGWS","Hamza Bellouch","01M79BRYWXQV3JK2TGVTX8GN2A",8,"MIT","https:\u002F\u002Fgithub.com\u002Fhamzabellouch\u002Fagent-skills\u002Fblob\u002Fmain\u002FProgramming\u002FCloud_DevOps_and_Infrastructure\u002FGoogle_Cloud_and_GKE\u002Fgke-workload-scaling\u002FSKILL.md",[],[],"2026-11-15 14:19:17",false,"---\nname: gke-workload-scaling\ndescription: >-\n  Manages scaling for GKE workloads using HPA and VPA. Use when configuring\n  Horizontal Pod Autoscaler (HPA), configuring Vertical Pod Autoscaler (VPA),\n  or applying best practices for GKE workload autoscaling. Do not use for\n  cluster-level autoscaling (Cluster Autoscaler), static cluster sizing,\n  or configuring node-level machine styles directly.\nmetadata:\n  category: Containers\n---\n\n# GKE Workload Scaling\n\nThis skill provides workflows and best practices for scaling applications on\nGoogle Kubernetes Engine (GKE). It covers manual scaling, Horizontal Pod\nAutoscaling (HPA), and Vertical Pod Autoscaling (VPA).\n\n## Workflows\n\n### 1. Manual Scaling\n\nScale a deployment to a fixed number of replicas. Useful for immediate manual\nintervention or testing.\n\n**Command:**\n\n```bash\nkubectl scale deployment {deployment_name} --replicas={number} -n {namespace}\n\n# Verify the scale event\nkubectl get deployment {deployment_name} -n {namespace}\n```\n\n### 2. Horizontal Pod Autoscaling (HPA)\n\nAutomatically scale the number of pods based on observed CPU utilization, memory\nutilization, or custom metrics.\n\n**Prerequisites:**\n\n-   Metrics Server must be running (enabled by default on GKE).\n-   Containers clearly define resource requests\u002Flimits.\n\n**Quick Command:**\n\n```bash\nkubectl autoscale deployment {deployment_name} --cpu-percent=50 --min=1 --max=10\n```\n\n**Manifest Approach (Recommended):** Use a YAML manifest for version-controlled\nconfiguration. See [assets\u002Fhpa-example.yaml](assets\u002Fhpa-example.yaml) for a\ntemplate.\n\n```bash\nkubectl apply -f assets\u002Fhpa-example.yaml\n\n# Verify HPA is created and fetching metrics\nkubectl get hpa\n```\n\n**Custom Metrics & External Metrics:** For GKE, the modern and recommended\napproach for scaling based on Cloud Monitoring metrics (e.g., Pub\u002FSub queue\nlength) is to use the **External** metric type, which is natively supported by\nthe GKE control plane without requiring the Custom Metrics Adapter. For\napplication-specific metrics exposed via Prometheus, you can use **Google Cloud\nManaged Service for Prometheus** or the Prometheus Adapter.\n\n### 3. Vertical Pod Autoscaling (VPA)\n\nAutomatically adjust the CPU and memory reservations for your pods to match\nactual usage. This is critical for right-sizing workloads.\n\n**Prerequisites:**\n\n-   VPA must be enabled on the cluster.\n    -   **Autopilot:** Enabled by default.\n    -   **Standard:** Must be enabled manually.\n\n**Enable VPA on Standard Cluster:**\n\n```bash\ngcloud container clusters update {cluster_name} --enable-vertical-pod-autoscaling --zone {zone}\n```\n\n**Update Modes:**\n\n-   `Off`: Calculates recommendations but does not apply them. Good for \"dry\n    run\" analysis.\n-   `Initial`: Assigns resources only at pod creation time.\n-   `Auto`: Updates running pods by restarting them if recommendations differ\n    significantly from requests.\n-   `InPlaceOrRecreate`: Attempts to update Pod resources without recreating the\n    Pod. If in-place update is not possible, it reverts to `Auto` mode (requires\n    GKE 1.34+).\n\n**Example:** See [assets\u002Fvpa-example.yaml](assets\u002Fvpa-example.yaml) for a\nconfiguration template.\n\n## Best Practices\n\n1.  **Define Resource Requests:** HPA and VPA rely on accurate resource\n    requests. Always define them in your container specs.\n2.  **Avoid Metric Conflicts:** Do not configure HPA and VPA to use the same\n    metric (e.g., both CPU). This causes thrashing.\n    -   *Typical Pattern:* HPA on CPU, VPA on Memory.\n3.  **Pod Disruption Budgets (PDBs):** Define PDBs to ensure application\n    availability during scaling events or node upgrades.\n4.  **HPA Lag:** HPA has a stabilization window (default 5 mins) to prevent\n    rapid fluctuation.\n5.  **VPA \"Auto\" Mode Risks:** In \"Auto\" mode, VPA restarts pods to change\n    resources. Ensure your application handles restarts gracefully (e.g.,\n    handles SIGTERM).\n    -   *Note:* By default, VPA requires at least 2 replicas to perform\n        evictions (to prevent a situation where the only running replica is\n        evicted, causing downtime). In GKE 1.22+, you can override this by\n        setting `minReplicas` in `PodUpdatePolicy`.\n\n## Rightsizing Workflow\n\n1.  Deploy VPA in `Off` mode for 24+ hours\n2.  Read recommendations: `kubectl describe vpa {deployment_name}-vpa -n\n    {namespace}`\n3.  Compare `target` values against current `requests`\n4.  Apply with 20% buffer: `new_request = target * 1.2`\n5.  Use patch format or update deployment manifest to apply new resource\n    requests\n\nCondition                     | Recommendation                       | Risk\n----------------------------- | ------------------------------------ | ------\nCPU request >5x P95 actual    | Reduce to `P95 * 1.2`                | Medium\nMemory request >3x P95 actual | Reduce to `P95 * 1.2`                | Medium\nCPU request >2x P95 actual    | Rightsizing with 20% buffer          | Low\nNo resource limits set        | Add limits to prevent noisy-neighbor | Low\n","# GKE Workload Scaling\n\nThis skill provides workflows and best practices for scaling applications on\nGoogle Kubernetes Engine (GKE). It covers manual scaling, Horizontal Pod\nAutoscaling (HPA), and Vertical Pod Autoscaling (VPA).\n\n## Workflows\n\n### 1. Manual Scaling\n\nScale a deployment to a fixed number of replicas. Useful for immediate manual\nintervention or testing.\n\n**Command:**\n\n```bash\nkubectl scale deployment {deployment_name} --replicas={number} -n {namespace}\n\n# Verify the scale event\nkubectl get deployment {deployment_name} -n {namespace}\n```\n\n### 2. Horizontal Pod Autoscaling (HPA)\n\nAutomatically scale the number of pods based on observed CPU utilization, memory\nutilization, or custom metrics.\n\n**Prerequisites:**\n\n-   Metrics Server must be running (enabled by default on GKE).\n-   Containers clearly define resource requests\u002Flimits.\n\n**Quick Command:**\n\n```bash\nkubectl autoscale deployment {deployment_name} --cpu-percent=50 --min=1 --max=10\n```\n\n**Manifest Approach (Recommended):** Use a YAML manifest for version-controlled\nconfiguration. See [assets\u002Fhpa-example.yaml](assets\u002Fhpa-example.yaml) for a\ntemplate.\n\n```bash\nkubectl apply -f assets\u002Fhpa-example.yaml\n\n# Verify HPA is created and fetching metrics\nkubectl get hpa\n```\n\n**Custom Metrics & External Metrics:** For GKE, the modern and recommended\napproach for scaling based on Cloud Monitoring metrics (e.g., Pub\u002FSub queue\nlength) is to use the **External** metric type, which is natively supported by\nthe GKE control plane without requiring the Custom Metrics Adapter. For\napplication-specific metrics exposed via Prometheus, you can use **Google Cloud\nManaged Service for Prometheus** or the Prometheus Adapter.\n\n### 3. Vertical Pod Autoscaling (VPA)\n\nAutomatically adjust the CPU and memory reservations for your pods to match\nactual usage. This is critical for right-sizing workloads.\n\n**Prerequisites:**\n\n-   VPA must be enabled on the cluster.\n    -   **Autopilot:** Enabled by default.\n    -   **Standard:** Must be enabled manually.\n\n**Enable VPA on Standard Cluster:**\n\n```bash\ngcloud container clusters update {cluster_name} --enable-vertical-pod-autoscaling --zone {zone}\n```\n\n**Update Modes:**\n\n-   `Off`: Calculates recommendations but does not apply them. Good for \"dry\n    run\" analysis.\n-   `Initial`: Assigns resources only at pod creation time.\n-   `Auto`: Updates running pods by restarting them if recommendations differ\n    significantly from requests.\n-   `InPlaceOrRecreate`: Attempts to update Pod resources without recreating the\n    Pod. If in-place update is not possible, it reverts to `Auto` mode (requires\n    GKE 1.34+).\n\n**Example:** See [assets\u002Fvpa-example.yaml](assets\u002Fvpa-example.yaml) for a\nconfiguration template.\n\n## Best Practices\n\n1.  **Define Resource Requests:** HPA and VPA rely on accurate resource\n    requests. Always define them in your container specs.\n2.  **Avoid Metric Conflicts:** Do not configure HPA and VPA to use the same\n    metric (e.g., both CPU). This causes thrashing.\n    -   *Typical Pattern:* HPA on CPU, VPA on Memory.\n3.  **Pod Disruption Budgets (PDBs):** Define PDBs to ensure application\n    availability during scaling events or node upgrades.\n4.  **HPA Lag:** HPA has a stabilization window (default 5 mins) to prevent\n    rapid fluctuation.\n5.  **VPA \"Auto\" Mode Risks:** In \"Auto\" mode, VPA restarts pods to change\n    resources. Ensure your application handles restarts gracefully (e.g.,\n    handles SIGTERM).\n    -   *Note:* By default, VPA requires at least 2 replicas to perform\n        evictions (to prevent a situation where the only running replica is\n        evicted, causing downtime). In GKE 1.22+, you can override this by\n        setting `minReplicas` in `PodUpdatePolicy`.\n\n## Rightsizing Workflow\n\n1.  Deploy VPA in `Off` mode for 24+ hours\n2.  Read recommendations: `kubectl describe vpa {deployment_name}-vpa -n\n    {namespace}`\n3.  Compare `target` values against current `requests`\n4.  Apply with 20% buffer: `new_request = target * 1.2`\n5.  Use patch format or update deployment manifest to apply new resource\n    requests\n\nCondition                     | Recommendation                       | Risk\n----------------------------- | ------------------------------------ | ------\nCPU request >5x P95 actual    | Reduce to `P95 * 1.2`                | Medium\nMemory request >3x P95 actual | Reduce to `P95 * 1.2`                | Medium\nCPU request >2x P95 actual    | Rightsizing with 20% buffer          | Low\nNo resource limits set        | Add limits to prevent noisy-neighbor | Low\n",{"name":5,"metadata":24,"description":7},{"category":25},"Containers","main","e905af21e5f1e1c3ca605e9656c3a7930360a84e","Programming\u002FCloud_DevOps_and_Infrastructure\u002FGoogle_Cloud_and_GKE\u002Fgke-workload-scaling",1,"https:\u002F\u002Fgithub.com\u002Fhamzabellouch\u002Fagent-skills","https:\u002F\u002Fhamzabellouch.github.io\u002F","https:\u002F\u002Fgithub.com\u002Fhamzabellouch","hamzabellouch.github.io","CEO & Founder of @tknoglobal | Researcher in Technology & Applied Sciences.","2026-10-17 03:20:19",{"source":8,"skillName":5,"commands":37,"prompt":47,"zipAvailable":48},[38,41,44],{"tool":39,"command":40},"npx","npx skills add hamzabellouch\u002Fagent-skills --skill gke-workload-scaling",{"tool":42,"command":43},"bunx","bunx skills add hamzabellouch\u002Fagent-skills --skill gke-workload-scaling",{"tool":45,"command":46},"pnpm","pnpm dlx skills add hamzabellouch\u002Fagent-skills --skill gke-workload-scaling","安装技能，技能地址：https:\u002F\u002Fgithub.com\u002Fhamzabellouch\u002Fagent-skills\u002Fblob\u002Fmain\u002FProgramming\u002FCloud_DevOps_and_Infrastructure\u002FGoogle_Cloud_and_GKE\u002Fgke-workload-scaling\u002FSKILL.md",true,[50,56],{"path":51,"resourceType":52,"resourceTypeDesc":53,"sizeBytes":54,"sourceHtmlUrl":55},"assets\u002Fhpa-example.yaml","ASSET","资产文件",519,"https:\u002F\u002Fgithub.com\u002Fhamzabellouch\u002Fagent-skills\u002Fblob\u002Fmain\u002FProgramming\u002FCloud_DevOps_and_Infrastructure\u002FGoogle_Cloud_and_GKE\u002Fgke-workload-scaling\u002Fassets\u002Fhpa-example.yaml",{"path":57,"resourceType":52,"resourceTypeDesc":53,"sizeBytes":58,"sourceHtmlUrl":59},"assets\u002Fvpa-example.yaml",437,"https:\u002F\u002Fgithub.com\u002Fhamzabellouch\u002Fagent-skills\u002Fblob\u002Fmain\u002FProgramming\u002FCloud_DevOps_and_Infrastructure\u002FGoogle_Cloud_and_GKE\u002Fgke-workload-scaling\u002Fassets\u002Fvpa-example.yaml",[61,68,75,82,89,96],{"skillNo":62,"name":63,"nameZh":6,"description":64,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":65,"categories":66,"keywords":67,"publishedAt":19},"01M79FHH2H815A9TAP6WNKH4Q8","security-audit","Comprehensive security guidance, source code audit, vulnerability assessment, and penetration test review for codebases, APIs, microservices, CLI tools, libraries, and LLM-backed applications. Triggers on requests to audit a codebase, conduct security reviews, find vulnerabilities or flaws, pen-test source code, or when the user asks in Arabic (فحص أمني، تدقيق الكود أمنياً، مراجعة الثغرات، فحص أمان المشروع). Supports Guidance mode (focused review) and Full Audit mode (deterministic 6-phase harness).","https:\u002F\u002Fgithub.com\u002Fhamzabellouch\u002Fagent-skills\u002Fblob\u002Fmain\u002FSecurity\u002FSecurity_Audit_and_Code_Review\u002Fsecurity-audit\u002FSKILL.md",[],[],{"skillNo":69,"name":70,"nameZh":6,"description":71,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":72,"categories":73,"keywords":74,"publishedAt":19},"01M79FHBGXVBY6VQ1X7ETAZMF1","malware-analysis-reversing","Production malware analysis workflows, reverse engineering methodologies, isolated sandbox triage, static\u002Fdynamic binary analysis, memory forensics, and YARA detection rule authoring.","https:\u002F\u002Fgithub.com\u002Fhamzabellouch\u002Fagent-skills\u002Fblob\u002Fmain\u002FSecurity\u002FOffensive_Security_and_Pentesting\u002Fmalware-analysis-reversing\u002FSKILL.md",[],[],{"skillNo":76,"name":77,"nameZh":6,"description":78,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":79,"categories":80,"keywords":81,"publishedAt":19},"01M79FH6EACDR801TZCE4R8SAC","application-security-pentesting","Production Application Security (AppSec) standards, OWASP Top 10 vulnerability remediation, SAST\u002FDAST pipeline integration, secure code review, threat modeling, and defensive security posture.","https:\u002F\u002Fgithub.com\u002Fhamzabellouch\u002Fagent-skills\u002Fblob\u002Fmain\u002FSecurity\u002FOffensive_Security_and_Pentesting\u002Fapplication-security-pentesting\u002FSKILL.md",[],[],{"skillNo":83,"name":84,"nameZh":6,"description":85,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":86,"categories":87,"keywords":88,"publishedAt":19},"01M79FH0VKVT44FK923K520ZQA","oauth2-oidc-security-flows","Implement enterprise OAuth 2.1 and OpenID Connect (OIDC) authorization code flow with Proof Key for Code Exchange (PKCE), state and nonce verification, refresh token rotation, token revocation, and centralized IdP federation (Keycloak, Auth0, Okta). Trigger when building secure authentication, single sign-on (SSO), or third-party delegated authorization.","https:\u002F\u002Fgithub.com\u002Fhamzabellouch\u002Fagent-skills\u002Fblob\u002Fmain\u002FSecurity\u002FIdentity_and_Access_Management_IAM\u002Foauth2-oidc-security-flows\u002FSKILL.md",[],[],{"skillNo":90,"name":91,"nameZh":6,"description":92,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":93,"categories":94,"keywords":95,"publishedAt":19},"01M79FGVVB3R4T88XXD8FRSV5B","jwt-session-management-hardening","Harden JWT-based authentication and session lifecycles using asymmetric signing (RS256\u002FEdDSA), JWKS rotation, strict claims validation, Redis-backed sliding window sessions, revocation lists, and secure HttpOnly cookie storage. Trigger when implementing token validation, session revocation, or hardening API authentication.","https:\u002F\u002Fgithub.com\u002Fhamzabellouch\u002Fagent-skills\u002Fblob\u002Fmain\u002FSecurity\u002FIdentity_and_Access_Management_IAM\u002Fjwt-session-management-hardening\u002FSKILL.md",[],[],{"skillNo":97,"name":98,"nameZh":6,"description":99,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":100,"categories":101,"keywords":102,"publishedAt":19},"01M79FGNCPZ85CVEY0B3NE4H3B","soc2-compliance-automation","Best practices for implementing SOC 2 Type II compliance controls, continuous evidence collection, infrastructure policy-as-code, and automated security monitoring. Use when automating Trust Services Criteria (Security, Availability, Confidentiality, Processing Integrity, Privacy), audit logging, IAM least privilege, or CI\u002FCD security gates.","https:\u002F\u002Fgithub.com\u002Fhamzabellouch\u002Fagent-skills\u002Fblob\u002Fmain\u002FSecurity\u002FGovernance_Compliance_and_Legal_Tech\u002Fsoc2-compliance-automation\u002FSKILL.md",[],[]]