@synapta/skills 0.1.1 → 0.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.js +11 -4
- package/package.json +3 -4
- package/skills/ATTRIBUTION.md +80 -0
- package/skills/accessibility-audit/SKILL.md +325 -0
- package/skills/accessibility-audit/reference/wcag-checklist.md +103 -0
- package/skills/apns-notifier/SKILL.md +86 -0
- package/skills/approval-policy-enforcer/SKILL.md +66 -0
- package/skills/apps-sdk-builder/LICENSE.txt +201 -0
- package/skills/apps-sdk-builder/SKILL.md +328 -0
- package/skills/apps-sdk-builder/agents/openai.yaml +13 -0
- package/skills/apps-sdk-builder/references/app-archetypes.md +132 -0
- package/skills/apps-sdk-builder/references/apps-sdk-docs-workflow.md +135 -0
- package/skills/apps-sdk-builder/references/interactive-state-sync-patterns.md +113 -0
- package/skills/apps-sdk-builder/references/repo-contract-and-validation.md +93 -0
- package/skills/apps-sdk-builder/references/search-fetch-standard.md +67 -0
- package/skills/apps-sdk-builder/references/upstream-example-workflow.md +79 -0
- package/skills/apps-sdk-builder/references/window-openai-patterns.md +79 -0
- package/skills/apps-sdk-builder/scripts/scaffold_node_ext_apps.mjs +606 -0
- package/skills/architecture-selector/SKILL.md +64 -0
- package/skills/backlog-planner/SKILL.md +68 -0
- package/skills/carplay-entitlement-checker/SKILL.md +82 -0
- package/skills/concept-deepener/SKILL.md +86 -0
- package/skills/concept-discovery/SKILL.md +517 -0
- package/skills/concept-discovery/assets/sample-analysis.json +81 -0
- package/skills/concept-discovery/expected_outputs/sample-enum-dictionary.md +25 -0
- package/skills/concept-discovery/expected_outputs/sample-page-user-list.md +83 -0
- package/skills/concept-discovery/expected_outputs/sample-prd-readme.md +43 -0
- package/skills/concept-discovery/references/framework-patterns.md +228 -0
- package/skills/concept-discovery/references/prd-quality-checklist.md +65 -0
- package/skills/concept-discovery/scripts/codebase_analyzer.py +732 -0
- package/skills/concept-discovery/scripts/prd_scaffolder.py +435 -0
- package/skills/dast-zap/SKILL.md +453 -0
- package/skills/dast-zap/assets/.gitkeep +9 -0
- package/skills/dast-zap/assets/github_action.yml +207 -0
- package/skills/dast-zap/assets/gitlab_ci.yml +226 -0
- package/skills/dast-zap/assets/zap_automation.yaml +196 -0
- package/skills/dast-zap/assets/zap_context.xml +192 -0
- package/skills/dast-zap/references/EXAMPLE.md +40 -0
- package/skills/dast-zap/references/api_testing_guide.md +475 -0
- package/skills/dast-zap/references/authentication_guide.md +431 -0
- package/skills/dast-zap/references/false_positive_handling.md +427 -0
- package/skills/dast-zap/references/owasp_mapping.md +255 -0
- package/skills/dep-sbom-scan/SKILL.md +466 -0
- package/skills/deploy-cloudflare/SKILL.md +930 -0
- package/skills/deploy-docker/SKILL.md +55 -0
- package/skills/deploy-fly/SKILL.md +228 -0
- package/skills/deploy-k8s/SKILL.md +108 -0
- package/skills/deploy-k8s/assets/logo.png +0 -0
- package/skills/deploy-k8s/docs/README.md +29 -0
- package/skills/deploy-k8s/docs/SUMMARY.md +56 -0
- package/skills/deploy-k8s/docs/advanced/token-efficiency.md +61 -0
- package/skills/deploy-k8s/docs/architecture/multi-tenancy.md +96 -0
- package/skills/deploy-k8s/docs/architecture/storage-and-state.md +102 -0
- package/skills/deploy-k8s/docs/architecture/workload-patterns.md +87 -0
- package/skills/deploy-k8s/docs/book.json +16 -0
- package/skills/deploy-k8s/docs/community/changelog.md +34 -0
- package/skills/deploy-k8s/docs/community/contributing.md +67 -0
- package/skills/deploy-k8s/docs/core-concepts/failure-modes.md +153 -0
- package/skills/deploy-k8s/docs/core-concepts/philosophy.md +83 -0
- package/skills/deploy-k8s/docs/core-concepts/workflow.md +124 -0
- package/skills/deploy-k8s/docs/examples/bad-patterns.md +47 -0
- package/skills/deploy-k8s/docs/examples/do-dont-checklist.md +37 -0
- package/skills/deploy-k8s/docs/examples/good-patterns.md +49 -0
- package/skills/deploy-k8s/docs/failure-modes/api-drift.md +104 -0
- package/skills/deploy-k8s/docs/failure-modes/fragile-rollouts.md +99 -0
- package/skills/deploy-k8s/docs/failure-modes/insecure-workload-defaults.md +80 -0
- package/skills/deploy-k8s/docs/failure-modes/network-exposure.md +98 -0
- package/skills/deploy-k8s/docs/failure-modes/privilege-sprawl.md +91 -0
- package/skills/deploy-k8s/docs/failure-modes/resource-starvation.md +85 -0
- package/skills/deploy-k8s/docs/getting-started/installation.md +152 -0
- package/skills/deploy-k8s/docs/getting-started/quick-start.md +115 -0
- package/skills/deploy-k8s/docs/guides/helm-patterns.md +71 -0
- package/skills/deploy-k8s/docs/guides/kustomize-patterns.md +65 -0
- package/skills/deploy-k8s/docs/guides/observability.md +67 -0
- package/skills/deploy-k8s/docs/guides/security-hardening.md +59 -0
- package/skills/deploy-k8s/docs/guides/validation-and-policy.md +66 -0
- package/skills/deploy-k8s/docs/integrations/mcp-integration.md +52 -0
- package/skills/deploy-k8s/docs/package-lock.json +2892 -0
- package/skills/deploy-k8s/docs/package.json +13 -0
- package/skills/deploy-k8s/references/api-drift.md +298 -0
- package/skills/deploy-k8s/references/conditional/aks-patterns.md +70 -0
- package/skills/deploy-k8s/references/conditional/eks-patterns.md +79 -0
- package/skills/deploy-k8s/references/conditional/gitops-controllers.md +71 -0
- package/skills/deploy-k8s/references/conditional/gke-patterns.md +74 -0
- package/skills/deploy-k8s/references/conditional/observability-stacks.md +80 -0
- package/skills/deploy-k8s/references/conditional/openshift-patterns.md +67 -0
- package/skills/deploy-k8s/references/daemonset-operator-patterns.md +155 -0
- package/skills/deploy-k8s/references/deployment-patterns.md +146 -0
- package/skills/deploy-k8s/references/do-dont-patterns.md +87 -0
- package/skills/deploy-k8s/references/examples-bad.md +282 -0
- package/skills/deploy-k8s/references/examples-good.md +440 -0
- package/skills/deploy-k8s/references/fragile-rollouts.md +303 -0
- package/skills/deploy-k8s/references/helm-patterns.md +203 -0
- package/skills/deploy-k8s/references/insecure-workload-defaults.md +300 -0
- package/skills/deploy-k8s/references/job-patterns.md +120 -0
- package/skills/deploy-k8s/references/kustomize-patterns.md +239 -0
- package/skills/deploy-k8s/references/multi-tenancy.md +343 -0
- package/skills/deploy-k8s/references/network-exposure.md +481 -0
- package/skills/deploy-k8s/references/observability.md +302 -0
- package/skills/deploy-k8s/references/privilege-sprawl.md +273 -0
- package/skills/deploy-k8s/references/resource-starvation.md +374 -0
- package/skills/deploy-k8s/references/security-hardening.md +209 -0
- package/skills/deploy-k8s/references/stateful-patterns.md +130 -0
- package/skills/deploy-k8s/references/storage-and-state.md +330 -0
- package/skills/deploy-k8s/references/validation-and-policy.md +242 -0
- package/skills/deploy-railway/SKILL.md +235 -0
- package/skills/deploy-railway/references/analyze-db-mongo.md +84 -0
- package/skills/deploy-railway/references/analyze-db-mysql.md +254 -0
- package/skills/deploy-railway/references/analyze-db-postgres.md +479 -0
- package/skills/deploy-railway/references/analyze-db-redis.md +208 -0
- package/skills/deploy-railway/references/analyze-db.md +344 -0
- package/skills/deploy-railway/references/configure.md +309 -0
- package/skills/deploy-railway/references/deploy.md +195 -0
- package/skills/deploy-railway/references/operate.md +214 -0
- package/skills/deploy-railway/references/request.md +248 -0
- package/skills/deploy-railway/references/setup.md +312 -0
- package/skills/deploy-railway/scripts/analyze-mongo.py +1549 -0
- package/skills/deploy-railway/scripts/analyze-mysql.py +1195 -0
- package/skills/deploy-railway/scripts/analyze-postgres.py +3058 -0
- package/skills/deploy-railway/scripts/analyze-redis.py +1090 -0
- package/skills/deploy-railway/scripts/dal.py +671 -0
- package/skills/deploy-railway/scripts/enable-pg-stats.py +170 -0
- package/skills/deploy-railway/scripts/pg-extensions.py +370 -0
- package/skills/deploy-railway/scripts/railway-api.sh +52 -0
- package/skills/deploy-ssh/SKILL.md +91 -0
- package/skills/deploy-vercel/SKILL.md +304 -0
- package/skills/deploy-vercel/resources/deploy-codex.sh +301 -0
- package/skills/deploy-vercel/resources/deploy.sh +301 -0
- package/skills/docs-runbooks/SKILL.md +399 -0
- package/skills/drive-status-renderer/SKILL.md +62 -0
- package/skills/iac-scan/SKILL.md +680 -0
- package/skills/iac-scan/assets/.gitkeep +9 -0
- package/skills/iac-scan/assets/checkov_config.yaml +94 -0
- package/skills/iac-scan/assets/github_actions.yml +199 -0
- package/skills/iac-scan/assets/gitlab_ci.yml +218 -0
- package/skills/iac-scan/assets/pre_commit_config.yaml +92 -0
- package/skills/iac-scan/references/EXAMPLE.md +40 -0
- package/skills/iac-scan/references/compliance_mapping.md +237 -0
- package/skills/iac-scan/references/custom_policies.md +460 -0
- package/skills/iac-scan/references/suppression_guide.md +431 -0
- package/skills/incident-briefing/SKILL.md +66 -0
- package/skills/incident-triage/SKILL.md +481 -0
- package/{LICENSE → skills/mcp-builder/LICENSE.txt} +15 -14
- package/skills/mcp-builder/SKILL.md +244 -0
- package/skills/mcp-builder/reference/evaluation.md +602 -0
- package/skills/mcp-builder/reference/mcp_best_practices.md +249 -0
- package/skills/mcp-builder/reference/node_mcp_server.md +970 -0
- package/skills/mcp-builder/reference/python_mcp_server.md +719 -0
- package/skills/mcp-builder/scripts/connections.py +151 -0
- package/skills/mcp-builder/scripts/evaluation.py +373 -0
- package/skills/mcp-builder/scripts/example_evaluation.xml +22 -0
- package/skills/mcp-builder/scripts/requirements.txt +2 -0
- package/skills/mobile-pairing/SKILL.md +52 -0
- package/skills/ops-sre/SKILL.md +297 -0
- package/skills/playwright-qa/LICENSE.txt +201 -0
- package/skills/playwright-qa/NOTICE.txt +14 -0
- package/skills/playwright-qa/SKILL.md +156 -0
- package/skills/playwright-qa/agents/openai.yaml +6 -0
- package/skills/playwright-qa/assets/playwright-small.svg +3 -0
- package/skills/playwright-qa/assets/playwright.png +0 -0
- package/skills/playwright-qa/references/cli.md +116 -0
- package/skills/playwright-qa/references/workflows.md +95 -0
- package/skills/playwright-qa/scripts/playwright_cli.sh +25 -0
- package/skills/release-publish/SKILL.md +85 -0
- package/skills/repo-bootstrap/SKILL.md +92 -0
- package/skills/repo-bootstrap/assets/example-workflows/validate-agents.yml +89 -0
- package/skills/repo-bootstrap/assets/root-thin.md +141 -0
- package/skills/repo-bootstrap/assets/root-verbose.md +149 -0
- package/skills/repo-bootstrap/assets/scoped/backend-go.md +107 -0
- package/skills/repo-bootstrap/assets/scoped/backend-php.md +94 -0
- package/skills/repo-bootstrap/assets/scoped/backend-python.md +84 -0
- package/skills/repo-bootstrap/assets/scoped/backend-typescript.md +89 -0
- package/skills/repo-bootstrap/assets/scoped/claude-code-skill.md +101 -0
- package/skills/repo-bootstrap/assets/scoped/cli.md +83 -0
- package/skills/repo-bootstrap/assets/scoped/concourse.md +196 -0
- package/skills/repo-bootstrap/assets/scoped/ddev.md +68 -0
- package/skills/repo-bootstrap/assets/scoped/docker.md +160 -0
- package/skills/repo-bootstrap/assets/scoped/documentation.md +98 -0
- package/skills/repo-bootstrap/assets/scoped/examples.md +96 -0
- package/skills/repo-bootstrap/assets/scoped/frontend-typescript.md +88 -0
- package/skills/repo-bootstrap/assets/scoped/github-actions.md +174 -0
- package/skills/repo-bootstrap/assets/scoped/gitlab-ci.md +174 -0
- package/skills/repo-bootstrap/assets/scoped/oro-bundle.md +209 -0
- package/skills/repo-bootstrap/assets/scoped/oro-project.md +170 -0
- package/skills/repo-bootstrap/assets/scoped/python-modern.md +170 -0
- package/skills/repo-bootstrap/assets/scoped/resources.md +96 -0
- package/skills/repo-bootstrap/assets/scoped/skill-repo.md +139 -0
- package/skills/repo-bootstrap/assets/scoped/symfony.md +168 -0
- package/skills/repo-bootstrap/assets/scoped/testing.md +87 -0
- package/skills/repo-bootstrap/assets/scoped/typo3-docs.md +103 -0
- package/skills/repo-bootstrap/assets/scoped/typo3-extension.md +133 -0
- package/skills/repo-bootstrap/assets/scoped/typo3-project.md +137 -0
- package/skills/repo-bootstrap/assets/scoped/typo3-testing.md +80 -0
- package/skills/repo-bootstrap/checkpoints.yaml +279 -0
- package/skills/repo-bootstrap/evals/evals.json +385 -0
- package/skills/repo-bootstrap/references/ai-contribution-guidelines.md +63 -0
- package/skills/repo-bootstrap/references/ai-tool-compatibility.md +223 -0
- package/skills/repo-bootstrap/references/directory-coverage.md +82 -0
- package/skills/repo-bootstrap/references/examples/coding-agent-cli/AGENTS.md +70 -0
- package/skills/repo-bootstrap/references/examples/coding-agent-cli/go.mod +3 -0
- package/skills/repo-bootstrap/references/examples/coding-agent-cli/scripts-AGENTS.md +389 -0
- package/skills/repo-bootstrap/references/examples/express-api-ts/.env.example +13 -0
- package/skills/repo-bootstrap/references/examples/express-api-ts/AGENTS.md +91 -0
- package/skills/repo-bootstrap/references/examples/express-api-ts/package.json +33 -0
- package/skills/repo-bootstrap/references/examples/express-api-ts/pnpm-lock.yaml +3 -0
- package/skills/repo-bootstrap/references/examples/express-api-ts/src/AGENTS.md +91 -0
- package/skills/repo-bootstrap/references/examples/express-api-ts/src/config.ts +28 -0
- package/skills/repo-bootstrap/references/examples/express-api-ts/src/controllers/userController.ts +74 -0
- package/skills/repo-bootstrap/references/examples/express-api-ts/src/index.ts +26 -0
- package/skills/repo-bootstrap/references/examples/express-api-ts/src/middleware/errorHandler.ts +45 -0
- package/skills/repo-bootstrap/references/examples/express-api-ts/src/middleware/requestLogger.ts +18 -0
- package/skills/repo-bootstrap/references/examples/express-api-ts/src/routes/health.ts +18 -0
- package/skills/repo-bootstrap/references/examples/express-api-ts/src/routes/users.ts +13 -0
- package/skills/repo-bootstrap/references/examples/express-api-ts/src/utils/errors.ts +40 -0
- package/skills/repo-bootstrap/references/examples/express-api-ts/src/utils/logger.ts +14 -0
- package/skills/repo-bootstrap/references/examples/express-api-ts/tsconfig.json +24 -0
- package/skills/repo-bootstrap/references/examples/fastapi-app/.env.example +19 -0
- package/skills/repo-bootstrap/references/examples/fastapi-app/AGENTS.md +92 -0
- package/skills/repo-bootstrap/references/examples/fastapi-app/pyproject.toml +88 -0
- package/skills/repo-bootstrap/references/examples/fastapi-app/src/AGENTS.md +85 -0
- package/skills/repo-bootstrap/references/examples/fastapi-app/src/__init__.py +3 -0
- package/skills/repo-bootstrap/references/examples/fastapi-app/src/config.py +49 -0
- package/skills/repo-bootstrap/references/examples/fastapi-app/src/main.py +66 -0
- package/skills/repo-bootstrap/references/examples/fastapi-app/src/models/__init__.py +13 -0
- package/skills/repo-bootstrap/references/examples/fastapi-app/src/models/item.py +43 -0
- package/skills/repo-bootstrap/references/examples/fastapi-app/src/models/user.py +40 -0
- package/skills/repo-bootstrap/references/examples/fastapi-app/src/routes/__init__.py +5 -0
- package/skills/repo-bootstrap/references/examples/fastapi-app/src/routes/health.py +20 -0
- package/skills/repo-bootstrap/references/examples/fastapi-app/src/routes/items.py +61 -0
- package/skills/repo-bootstrap/references/examples/fastapi-app/src/routes/users.py +55 -0
- package/skills/repo-bootstrap/references/examples/fastapi-app/src/services/__init__.py +6 -0
- package/skills/repo-bootstrap/references/examples/fastapi-app/src/services/item_service.py +77 -0
- package/skills/repo-bootstrap/references/examples/fastapi-app/src/services/user_service.py +69 -0
- package/skills/repo-bootstrap/references/examples/fastapi-app/uv.lock +4 -0
- package/skills/repo-bootstrap/references/examples/go-api-with-react-admin/.scopes +3 -0
- package/skills/repo-bootstrap/references/examples/go-api-with-react-admin/AGENTS.md +86 -0
- package/skills/repo-bootstrap/references/examples/go-api-with-react-admin/admin/package.json +20 -0
- package/skills/repo-bootstrap/references/examples/go-api-with-react-admin/admin/src/App.tsx +5 -0
- package/skills/repo-bootstrap/references/examples/go-api-with-react-admin/cmd/api/main.go +7 -0
- package/skills/repo-bootstrap/references/examples/go-api-with-react-admin/go.mod +2 -0
- package/skills/repo-bootstrap/references/examples/go-api-with-react-admin/main.go +7 -0
- package/skills/repo-bootstrap/references/examples/go-with-internal-web-tsx/.scopes +3 -0
- package/skills/repo-bootstrap/references/examples/go-with-internal-web-tsx/AGENTS.md +89 -0
- package/skills/repo-bootstrap/references/examples/go-with-internal-web-tsx/go.mod +2 -0
- package/skills/repo-bootstrap/references/examples/go-with-internal-web-tsx/internal/web/AGENTS.md +90 -0
- package/skills/repo-bootstrap/references/examples/go-with-internal-web-tsx/internal/web/package.json +17 -0
- package/skills/repo-bootstrap/references/examples/go-with-internal-web-tsx/internal/web/src/App.tsx +1 -0
- package/skills/repo-bootstrap/references/examples/go-with-internal-web-tsx/internal/web/src/Button.tsx +1 -0
- package/skills/repo-bootstrap/references/examples/go-with-internal-web-tsx/internal/web/src/Footer.tsx +1 -0
- package/skills/repo-bootstrap/references/examples/go-with-internal-web-tsx/internal/web/src/Header.tsx +1 -0
- package/skills/repo-bootstrap/references/examples/go-with-internal-web-tsx/internal/web/src/Sidebar.tsx +1 -0
- package/skills/repo-bootstrap/references/examples/go-with-internal-web-tsx/main.go +7 -0
- package/skills/repo-bootstrap/references/examples/go-with-internal-web-tsx/package-lock.json +0 -0
- package/skills/repo-bootstrap/references/examples/go-with-internal-web-tsx/package.json +12 -0
- package/skills/repo-bootstrap/references/examples/ldap-selfservice/AGENTS.md +70 -0
- package/skills/repo-bootstrap/references/examples/ldap-selfservice/go.mod +3 -0
- package/skills/repo-bootstrap/references/examples/ldap-selfservice/internal-AGENTS.md +371 -0
- package/skills/repo-bootstrap/references/examples/ldap-selfservice/internal-web-AGENTS.md +448 -0
- package/skills/repo-bootstrap/references/examples/php-with-frontend/.scopes +3 -0
- package/skills/repo-bootstrap/references/examples/php-with-frontend/AGENTS.md +91 -0
- package/skills/repo-bootstrap/references/examples/php-with-frontend/composer.json +8 -0
- package/skills/repo-bootstrap/references/examples/php-with-frontend/package.json +15 -0
- package/skills/repo-bootstrap/references/examples/php-with-frontend/pnpm-lock.yaml +0 -0
- package/skills/repo-bootstrap/references/examples/php-with-frontend/src/Controller.php +3 -0
- package/skills/repo-bootstrap/references/examples/php-with-frontend/web/AGENTS.md +92 -0
- package/skills/repo-bootstrap/references/examples/php-with-frontend/web/package.json +26 -0
- package/skills/repo-bootstrap/references/examples/php-with-frontend/web/src/App.tsx +3 -0
- package/skills/repo-bootstrap/references/examples/php-with-frontend/web/src/Button.tsx +10 -0
- package/skills/repo-bootstrap/references/examples/php-with-frontend/web/src/Footer.tsx +9 -0
- package/skills/repo-bootstrap/references/examples/php-with-frontend/web/src/Header.tsx +9 -0
- package/skills/repo-bootstrap/references/examples/php-with-frontend/web/src/main.tsx +3 -0
- package/skills/repo-bootstrap/references/examples/php-with-frontend/web/tsconfig.json +13 -0
- package/skills/repo-bootstrap/references/examples/pnpm-workspace/AGENTS.md +75 -0
- package/skills/repo-bootstrap/references/examples/pnpm-workspace/package.json +7 -0
- package/skills/repo-bootstrap/references/examples/pnpm-workspace/packages/web/package.json +11 -0
- package/skills/repo-bootstrap/references/examples/pnpm-workspace/packages/web/src/index.ts +11 -0
- package/skills/repo-bootstrap/references/examples/pnpm-workspace/pnpm-lock.yaml +42 -0
- package/skills/repo-bootstrap/references/examples/pnpm-workspace/pnpm-workspace.yaml +2 -0
- package/skills/repo-bootstrap/references/examples/simple-ldap-go/AGENTS.md +70 -0
- package/skills/repo-bootstrap/references/examples/simple-ldap-go/examples-AGENTS.md +45 -0
- package/skills/repo-bootstrap/references/examples/simple-ldap-go/go.mod +3 -0
- package/skills/repo-bootstrap/references/examples/t3x-rte-ckeditor-image/AGENTS.md +70 -0
- package/skills/repo-bootstrap/references/examples/t3x-rte-ckeditor-image/Classes-AGENTS.md +392 -0
- package/skills/repo-bootstrap/references/examples/t3x-rte-ckeditor-image/composer.json +8 -0
- package/skills/repo-bootstrap/references/feedback-memory-schema.md +135 -0
- package/skills/repo-bootstrap/references/git-hooks-setup.md +79 -0
- package/skills/repo-bootstrap/references/output-structure.md +124 -0
- package/skills/repo-bootstrap/references/scripts-guide.md +175 -0
- package/skills/repo-bootstrap/references/verification-guide.md +137 -0
- package/skills/repo-bootstrap/scripts/analyze-git-history.sh +315 -0
- package/skills/repo-bootstrap/scripts/check-freshness.sh +230 -0
- package/skills/repo-bootstrap/scripts/detect-golden-samples.sh +161 -0
- package/skills/repo-bootstrap/scripts/detect-heuristics.sh +93 -0
- package/skills/repo-bootstrap/scripts/detect-project.sh +486 -0
- package/skills/repo-bootstrap/scripts/detect-scopes.sh +330 -0
- package/skills/repo-bootstrap/scripts/detect-utilities.sh +133 -0
- package/skills/repo-bootstrap/scripts/extract-adrs.sh +194 -0
- package/skills/repo-bootstrap/scripts/extract-agent-configs.sh +331 -0
- package/skills/repo-bootstrap/scripts/extract-architecture-rules.sh +522 -0
- package/skills/repo-bootstrap/scripts/extract-ci-commands.sh +385 -0
- package/skills/repo-bootstrap/scripts/extract-ci-rules.sh +384 -0
- package/skills/repo-bootstrap/scripts/extract-commands.sh +358 -0
- package/skills/repo-bootstrap/scripts/extract-documentation.sh +308 -0
- package/skills/repo-bootstrap/scripts/extract-github-rulesets.sh +96 -0
- package/skills/repo-bootstrap/scripts/extract-github-settings.sh +88 -0
- package/skills/repo-bootstrap/scripts/extract-ide-settings.sh +228 -0
- package/skills/repo-bootstrap/scripts/extract-platform-files.sh +290 -0
- package/skills/repo-bootstrap/scripts/extract-quality-configs.sh +442 -0
- package/skills/repo-bootstrap/scripts/generate-agents.sh +2424 -0
- package/skills/repo-bootstrap/scripts/generate-file-map.sh +153 -0
- package/skills/repo-bootstrap/scripts/lib/config-root.sh +211 -0
- package/skills/repo-bootstrap/scripts/lib/summary.sh +244 -0
- package/skills/repo-bootstrap/scripts/lib/template.sh +397 -0
- package/skills/repo-bootstrap/scripts/validate-structure.sh +324 -0
- package/skills/repo-bootstrap/scripts/verify-commands.sh +615 -0
- package/skills/repo-bootstrap/scripts/verify-content.sh +302 -0
- package/skills/schema-api-contracts/SKILL.md +56 -0
- package/skills/secret-hygiene/SKILL.md +511 -0
- package/skills/secret-hygiene/assets/.gitkeep +9 -0
- package/skills/secret-hygiene/assets/config-balanced.toml +81 -0
- package/skills/secret-hygiene/assets/config-custom.toml +178 -0
- package/skills/secret-hygiene/assets/config-strict.toml +48 -0
- package/skills/secret-hygiene/assets/github-action.yml +181 -0
- package/skills/secret-hygiene/assets/gitlab-ci.yml +257 -0
- package/skills/secret-hygiene/assets/precommit-config.yaml +70 -0
- package/skills/secret-hygiene/references/EXAMPLE.md +40 -0
- package/skills/secret-hygiene/references/compliance_mapping.md +538 -0
- package/skills/secret-hygiene/references/detection_rules.md +276 -0
- package/skills/secret-hygiene/references/false_positives.md +598 -0
- package/skills/secret-hygiene/references/remediation_guide.md +530 -0
- package/skills/stack-selector/SKILL.md +56 -0
- package/skills/telegram-control/SKILL.md +110 -0
- package/skills/telegram-control/references/architecture.md +184 -0
- package/skills/telegram-control/references/convex.md +173 -0
- package/skills/telegram-control/references/error_handling.md +212 -0
- package/skills/telegram-control/references/initial_setup.md +165 -0
- package/skills/telegram-control/references/telegram_api.md +156 -0
- package/skills/telegram-control/scripts/cancel_message.ts +53 -0
- package/skills/telegram-control/scripts/list_scheduled.ts +103 -0
- package/skills/telegram-control/scripts/logger.ts +121 -0
- package/skills/telegram-control/scripts/proxy-util.ts +11 -0
- package/skills/telegram-control/scripts/schedule_message.ts +216 -0
- package/skills/telegram-control/scripts/send_message.ts +115 -0
- package/skills/telegram-control/scripts/setup.ts +185 -0
- package/skills/telegram-control/scripts/types.ts +75 -0
- package/skills/telegram-control/scripts/view_history.ts +74 -0
- package/skills/test-strategy/SKILL.md +352 -0
- package/skills/threat-model/SKILL.md +303 -0
- package/skills/threat-model/examples/example-output.md +196 -0
- package/skills/threat-model/template.md +96 -0
- package/skills/ts-lint/SKILL.md +80 -0
- package/skills/ui-flow/SKILL.md +668 -0
- package/skills/voice-command-router/SKILL.md +51 -0
- package/skills/widget-live-activity-sync/SKILL.md +66 -0
|
@@ -0,0 +1,65 @@
|
|
|
1
|
+
# Kustomize Patterns
|
|
2
|
+
|
|
3
|
+
Kustomize provides template-free customization of Kubernetes manifests using overlays and patches. KubeShark follows these conventions when generating or reviewing Kustomize configurations. For full YAML examples and the LLM mistake checklist, see [references/kustomize-patterns.md](https://github.com/LukasNiessen/kubernetes-skill/blob/main/references/kustomize-patterns.md).
|
|
4
|
+
|
|
5
|
+
## Base/Overlay Structure
|
|
6
|
+
|
|
7
|
+
Organize manifests in a standard directory layout:
|
|
8
|
+
|
|
9
|
+
- **base/** -- contains the core `kustomization.yaml`, Deployment, Service, and Namespace manifests shared across all environments
|
|
10
|
+
- **overlays/dev/**, **overlays/staging/**, **overlays/production/** -- environment-specific customizations that reference the base
|
|
11
|
+
- **components/** -- reusable cross-cutting features (e.g., monitoring, network policies) that any overlay can include
|
|
12
|
+
|
|
13
|
+
Every `kustomization.yaml` must declare `apiVersion: kustomize.config.k8s.io/v1beta1`, `kind: Kustomization`, and a `resources` list. Use `resources` (not the deprecated `bases` field) for base references.
|
|
14
|
+
|
|
15
|
+
## Patches
|
|
16
|
+
|
|
17
|
+
**Strategic Merge Patch** -- merge into an existing resource structure. Best for adding or overriding specific fields like replica count or resource limits. The patch must include `metadata.name` to match the target resource.
|
|
18
|
+
|
|
19
|
+
**JSON Patch** -- add, remove, or replace at a specific path. Required for array element manipulation. Use `/-` to append to arrays, explicit indices to target known positions. Applied via inline `patch` blocks with a `target` selector.
|
|
20
|
+
|
|
21
|
+
## Generators
|
|
22
|
+
|
|
23
|
+
`configMapGenerator` and `secretGenerator` create ConfigMaps and Secrets with an automatic content hash appended to the name. This hash-based naming triggers rolling updates when configuration changes -- a significant advantage over manually managed ConfigMaps.
|
|
24
|
+
|
|
25
|
+
When overriding a base generator in an overlay, use `behavior: merge` to extend existing values rather than creating a duplicate resource.
|
|
26
|
+
|
|
27
|
+
## Components
|
|
28
|
+
|
|
29
|
+
Components use `apiVersion: kustomize.config.k8s.io/v1alpha1` and `kind: Component`. They package reusable features (ServiceMonitor resources, Prometheus scrape annotations, sidecar injections) that any overlay can opt into via the `components` field.
|
|
30
|
+
|
|
31
|
+
## Common Transformers
|
|
32
|
+
|
|
33
|
+
Kustomize provides several built-in transformers for cross-cutting modifications:
|
|
34
|
+
|
|
35
|
+
- **`namePrefix` / `nameSuffix`** -- add prefixes or suffixes to all resource names
|
|
36
|
+
- **`commonLabels`** -- add labels to all resources and their selectors (use with caution on mutable resources; see LLM mistakes)
|
|
37
|
+
- **`commonAnnotations`** -- add annotations to all resources
|
|
38
|
+
- **`namespace`** -- set the namespace on all resources in the kustomization
|
|
39
|
+
|
|
40
|
+
## Image Transformer
|
|
41
|
+
|
|
42
|
+
Override image references without patching the Deployment directly:
|
|
43
|
+
|
|
44
|
+
- Use `newTag` for tag overrides during development
|
|
45
|
+
- Use `digest` for immutable production references
|
|
46
|
+
- The image transformer matches on the `name` field in container image references, so the name must match exactly
|
|
47
|
+
|
|
48
|
+
## When to Use Kustomize vs Helm
|
|
49
|
+
|
|
50
|
+
| Scenario | Recommended |
|
|
51
|
+
|---|---|
|
|
52
|
+
| Environment-specific overlays on static manifests | Kustomize |
|
|
53
|
+
| Complex parameterization with many configuration knobs | Helm |
|
|
54
|
+
| Third-party chart consumption | Helm (required) |
|
|
55
|
+
| CRDs and operator-managed resources | Either |
|
|
56
|
+
| Simple internal services with 2-3 environments | Kustomize |
|
|
57
|
+
| Shared library of templates across teams | Helm (library charts) |
|
|
58
|
+
|
|
59
|
+
## Production Overlay Pattern
|
|
60
|
+
|
|
61
|
+
A typical production overlay references the base, sets the namespace, applies production labels, patches resource limits, overrides ConfigMap values with `behavior: merge`, pins image tags, and adds production-only resources like HPAs. See the reference file for a complete example.
|
|
62
|
+
|
|
63
|
+
## Common LLM Mistakes
|
|
64
|
+
|
|
65
|
+
The most frequent Kustomize-specific errors LLMs produce include: using the deprecated `bases` field, omitting `metadata.name` in strategic merge patches, applying `commonLabels` to resources with immutable selectors, forgetting content hashes in resource references, wrong array indices in JSON patches, and using the wrong `apiVersion` for components. See the full checklist in the [reference file](https://github.com/LukasNiessen/kubernetes-skill/blob/main/references/kustomize-patterns.md#llm-mistake-checklist).
|
|
@@ -0,0 +1,67 @@
|
|
|
1
|
+
# Observability
|
|
2
|
+
|
|
3
|
+
Metrics, logging, tracing, and alerting for Kubernetes workloads. KubeShark treats observability as mandatory for production -- if you cannot measure it, you cannot operate it. For full configuration examples and the LLM mistake checklist, see [references/observability.md](https://github.com/LukasNiessen/kubernetes-skill/blob/main/references/observability.md).
|
|
4
|
+
|
|
5
|
+
## Probes as the Foundation
|
|
6
|
+
|
|
7
|
+
Liveness, readiness, and startup probes are the most basic form of observability. They tell Kubernetes whether your application is alive, ready to serve traffic, and initialized. Without correct probes, no amount of metrics or logging prevents cascading failures. See [fragile-rollouts](https://github.com/LukasNiessen/kubernetes-skill/blob/main/references/fragile-rollouts.md) for detailed probe rules.
|
|
8
|
+
|
|
9
|
+
## Prometheus Metrics
|
|
10
|
+
|
|
11
|
+
### Annotations Pattern
|
|
12
|
+
|
|
13
|
+
Add `prometheus.io/scrape: "true"`, `prometheus.io/port`, and `prometheus.io/path` annotations to the Pod template metadata (not the Deployment metadata). This enables Prometheus auto-discovery without the prometheus-operator.
|
|
14
|
+
|
|
15
|
+
### ServiceMonitor Pattern
|
|
16
|
+
|
|
17
|
+
When using prometheus-operator, prefer ServiceMonitor CRDs for type-safe configuration. The ServiceMonitor `selector.matchLabels` must match the Service labels, and the `release` label must match the Prometheus operator selector.
|
|
18
|
+
|
|
19
|
+
### RED Method
|
|
20
|
+
|
|
21
|
+
Every service should expose at minimum:
|
|
22
|
+
|
|
23
|
+
- **Rate** -- request throughput (`http_requests_total` counter)
|
|
24
|
+
- **Errors** -- failed request count (`http_requests_total{status=~"5.."}`)
|
|
25
|
+
- **Duration** -- request latency (`http_request_duration_seconds` histogram)
|
|
26
|
+
|
|
27
|
+
Align histogram buckets to your SLO thresholds, not arbitrary defaults. For resource-oriented services (queues, databases), add saturation metrics like queue depth and connection pool usage.
|
|
28
|
+
|
|
29
|
+
## Structured Logging
|
|
30
|
+
|
|
31
|
+
Applications must log structured JSON to stdout/stderr. Rules:
|
|
32
|
+
|
|
33
|
+
- Use `timestamp`, `level`, `msg` as standard fields
|
|
34
|
+
- Include `trace_id` and `span_id` for correlation with distributed traces
|
|
35
|
+
- Never log secrets, tokens, PII, or full request bodies
|
|
36
|
+
- Never log to files inside the container -- it defeats node-level collection and fills the writable layer
|
|
37
|
+
|
|
38
|
+
Log aggregation uses a DaemonSet pattern (Fluent Bit on every node reading `/var/log/containers/`). Use sidecars only when per-pod log transformation is required.
|
|
39
|
+
|
|
40
|
+
## OpenTelemetry Tracing
|
|
41
|
+
|
|
42
|
+
### Auto-Instrumentation
|
|
43
|
+
|
|
44
|
+
The OpenTelemetry Operator injects instrumentation via pod annotations (e.g., `instrumentation.opentelemetry.io/inject-java: "true"`).
|
|
45
|
+
|
|
46
|
+
### Collector Sidecar
|
|
47
|
+
|
|
48
|
+
For fine-grained control, run the OTel Collector as a sidecar with gRPC (4317) and HTTP (4318) OTLP receivers. Set resource requests and limits on the sidecar to prevent it from starving the main workload.
|
|
49
|
+
|
|
50
|
+
### Context Propagation
|
|
51
|
+
|
|
52
|
+
Propagate trace context (`traceparent` header / W3C Trace Context) across all service boundaries. Without propagation, traces are fragmented and useless.
|
|
53
|
+
|
|
54
|
+
## Alerting Patterns
|
|
55
|
+
|
|
56
|
+
Write symptom-based alerts (what the user experiences), not cause-based alerts (what broke internally):
|
|
57
|
+
|
|
58
|
+
- **HighErrorRate** -- error rate above SLO threshold for a sustained period
|
|
59
|
+
- **HighLatencyP99** -- p99 latency above target for a sustained period
|
|
60
|
+
|
|
61
|
+
Every PrometheusRule alert must include a `runbook_url` annotation pointing to actionable remediation steps. Alerts without runbooks are noise.
|
|
62
|
+
|
|
63
|
+
Use Grafana deployment annotations to correlate metric changes with releases. Integrate annotation creation into your CI/CD pipeline as a post-deploy step.
|
|
64
|
+
|
|
65
|
+
## Common LLM Mistakes
|
|
66
|
+
|
|
67
|
+
Key observability errors LLMs produce include: placing Prometheus annotations on the Deployment metadata instead of the Pod template, not declaring the metrics port in the container ports list, generating file-based logging instead of structured JSON to stdout, omitting trace context propagation, writing cause-based alerts instead of symptom-based ones, and omitting resource limits on sidecar containers. See the full checklist in the [reference file](https://github.com/LukasNiessen/kubernetes-skill/blob/main/references/observability.md#llm-mistake-checklist).
|
|
@@ -0,0 +1,59 @@
|
|
|
1
|
+
# Security Hardening
|
|
2
|
+
|
|
3
|
+
Defense-in-depth security for Kubernetes clusters, covering supply chain, admission, runtime, and network layers. KubeShark defaults to the PSS restricted profile for all generated workloads. For full configuration examples and the LLM mistake checklist, see [references/security-hardening.md](https://github.com/LukasNiessen/kubernetes-skill/blob/main/references/security-hardening.md).
|
|
4
|
+
|
|
5
|
+
## NSA/CISA Kubernetes Hardening Guide
|
|
6
|
+
|
|
7
|
+
Key control areas from the NSA/CISA guidance:
|
|
8
|
+
|
|
9
|
+
- **Pod security** -- use PSS restricted profile, non-root containers, read-only filesystems, drop all capabilities
|
|
10
|
+
- **Network separation** -- default-deny NetworkPolicy per namespace, encrypt traffic with service mesh mTLS
|
|
11
|
+
- **Authentication** -- disable anonymous auth, use short-lived tokens, integrate OIDC for human users
|
|
12
|
+
- **Authorization** -- RBAC with least privilege, no `cluster-admin` for workloads, regular RoleBinding audits
|
|
13
|
+
- **Audit logging** -- API server audit logging at Metadata level minimum, ship logs off-cluster
|
|
14
|
+
- **Threat detection** -- runtime monitoring with Falco or Tetragon for syscall and network anomaly detection
|
|
15
|
+
- **Upgrading** -- keep cluster and nodes within one minor version of latest, patch CVEs promptly
|
|
16
|
+
|
|
17
|
+
## OWASP Kubernetes Top 10
|
|
18
|
+
|
|
19
|
+
KubeShark maps each OWASP K8s risk to a specific reference file: insecure workload configurations (K01), supply chain vulnerabilities (K02), overly permissive RBAC (K03), lack of centralized policy enforcement (K04), inadequate logging (K05), broken authentication (K06), missing network segmentation (K07), secrets management failures (K08), misconfigured cluster components (K09), and outdated components (K10). See the full mapping in the reference file.
|
|
20
|
+
|
|
21
|
+
## CIS Kubernetes Benchmark
|
|
22
|
+
|
|
23
|
+
Critical checks organized by component:
|
|
24
|
+
|
|
25
|
+
- **Control plane** -- API server flags: `--anonymous-auth=false`, `--authorization-mode=RBAC,Node`, `--audit-log-path` set
|
|
26
|
+
- **etcd** -- client cert auth enabled, peer TLS enabled, access limited to API server only
|
|
27
|
+
- **Worker nodes** -- kubelet: `--anonymous-auth=false`, `--authorization-mode=Webhook`, `--read-only-port=0`
|
|
28
|
+
- **Policies** -- PSA enforced, NetworkPolicies present, ResourceQuotas applied
|
|
29
|
+
|
|
30
|
+
## Pod Security Admission (PSA)
|
|
31
|
+
|
|
32
|
+
Label every namespace with `enforce`, `audit`, and `warn` modes set to `restricted`. Using all three modes together catches violations at different stages. For gradual migration, enforce `baseline` while auditing and warning on `restricted`, then promote once compliant.
|
|
33
|
+
|
|
34
|
+
## Image Security and Supply Chain
|
|
35
|
+
|
|
36
|
+
- **Registry restrictions** -- use an admission webhook (Kyverno or Gatekeeper) to restrict image sources to approved registries
|
|
37
|
+
- **Vulnerability scanning** -- scan images in CI with Trivy before pushing, fail on CRITICAL and HIGH severity
|
|
38
|
+
- **Supply chain attestation** -- generate SBOMs with `syft` or `trivy sbom`, sign images with `cosign`, attach SLSA provenance
|
|
39
|
+
|
|
40
|
+
## Runtime Security
|
|
41
|
+
|
|
42
|
+
- **Falco** -- watches syscalls at the kernel level; create rules for shell spawns, sensitive file reads, and unexpected network connections
|
|
43
|
+
- **API server audit policy** -- log at `Metadata` level for secrets and configmaps, `RequestResponse` level for exec and attach operations
|
|
44
|
+
|
|
45
|
+
## etcd Encryption at Rest
|
|
46
|
+
|
|
47
|
+
Configure `EncryptionConfiguration` with `aescbc` or `secretbox` providers (never `identity`, which is plaintext). Pass `--encryption-provider-config` to the API server. After applying, re-encrypt existing Secrets with `kubectl get secrets -A -o json | kubectl replace -f -`.
|
|
48
|
+
|
|
49
|
+
## Network-Level Controls Beyond NetworkPolicy
|
|
50
|
+
|
|
51
|
+
NetworkPolicy provides segmentation but does not encrypt traffic. For in-transit encryption:
|
|
52
|
+
|
|
53
|
+
- **Service mesh mTLS** (Istio, Linkerd) -- encrypts all pod-to-pod traffic and provides identity-based authorization
|
|
54
|
+
- **DNS policies** -- restrict external DNS resolution to prevent data exfiltration
|
|
55
|
+
- **Egress gateways** -- force all outbound traffic through a controlled proxy for inspection and allowlisting
|
|
56
|
+
|
|
57
|
+
## Common LLM Mistakes
|
|
58
|
+
|
|
59
|
+
Key security errors LLMs produce include: setting only `enforce` without `audit` and `warn` PSA labels, using `identity` encryption instead of `aescbc`, omitting audit logging for secrets and exec operations, using cluster-scoped RBAC bindings when namespace-scoped ones suffice, auto-mounting service account tokens on pods that do not call the API, and relying on NetworkPolicy for encryption when mTLS is needed. See the full checklist in the [reference file](https://github.com/LukasNiessen/kubernetes-skill/blob/main/references/security-hardening.md#llm-mistake-checklist).
|
|
@@ -0,0 +1,66 @@
|
|
|
1
|
+
# Validation and Policy Enforcement
|
|
2
|
+
|
|
3
|
+
Manifest validation and policy enforcement for Kubernetes, from offline schema checks to admission-time policy engines. For full configuration examples, CI pipeline templates, and the LLM mistake checklist, see [references/validation-and-policy.md](https://github.com/LukasNiessen/kubernetes-skill/blob/main/references/validation-and-policy.md).
|
|
4
|
+
|
|
5
|
+
## Validation Layers
|
|
6
|
+
|
|
7
|
+
Apply these three layers in order -- each catches different classes of errors:
|
|
8
|
+
|
|
9
|
+
1. **Client-side schema validation** (kubeconform) -- catches structural YAML errors, unknown fields, wrong types
|
|
10
|
+
2. **Policy enforcement** (Kyverno / OPA Gatekeeper) -- catches organizational rule violations
|
|
11
|
+
3. **Server-side dry-run** (`kubectl --dry-run=server`) -- catches admission webhook rejections, quota violations, naming conflicts
|
|
12
|
+
|
|
13
|
+
## kubeconform
|
|
14
|
+
|
|
15
|
+
Fast, offline schema validation against specific Kubernetes versions.
|
|
16
|
+
|
|
17
|
+
- Always use `-strict` to reject unknown or misspelled fields
|
|
18
|
+
- Pin `-kubernetes-version` to the target cluster version
|
|
19
|
+
- Use CRD schema registries for custom resources; without them, CRDs are silently skipped
|
|
20
|
+
- Validate Helm output: `helm template ... | kubeconform -strict`
|
|
21
|
+
- Validate Kustomize output: `kustomize build ... | kubeconform -strict`
|
|
22
|
+
|
|
23
|
+
## kubectl Dry-Run
|
|
24
|
+
|
|
25
|
+
- **`--dry-run=client`** -- basic YAML parsing only, no server contact, catches syntax errors
|
|
26
|
+
- **`--dry-run=server`** -- full admission chain minus persistence, runs through all webhooks and validations
|
|
27
|
+
|
|
28
|
+
Always use the explicit `=client` or `=server` form. Bare `--dry-run` is deprecated.
|
|
29
|
+
|
|
30
|
+
## Kyverno
|
|
31
|
+
|
|
32
|
+
YAML-native policy engine where policies are Kubernetes resources.
|
|
33
|
+
|
|
34
|
+
- `ClusterPolicy` applies cluster-wide; `Policy` is namespace-scoped
|
|
35
|
+
- `validationFailureAction: Enforce` blocks non-compliant resources; `Audit` only logs
|
|
36
|
+
- Supports validate, mutate, generate, and verifyImages rule types
|
|
37
|
+
- Common policies: require resource limits, require standard labels, restrict image registries
|
|
38
|
+
|
|
39
|
+
## OPA Gatekeeper
|
|
40
|
+
|
|
41
|
+
Policy engine using Rego with a two-object model:
|
|
42
|
+
|
|
43
|
+
- **ConstraintTemplate** -- defines reusable policy logic in Rego
|
|
44
|
+
- **Constraint** -- applies the template with specific match criteria and parameters
|
|
45
|
+
- Always check both `containers` and `initContainers` in Rego rules to prevent bypasses
|
|
46
|
+
|
|
47
|
+
## Polaris
|
|
48
|
+
|
|
49
|
+
Score-based configuration auditing, useful for baseline posture assessment:
|
|
50
|
+
|
|
51
|
+
- `polaris audit --audit-path manifests/` for local checks
|
|
52
|
+
- `polaris audit --set-exit-code-on-danger` for CI gating
|
|
53
|
+
|
|
54
|
+
## CI Pipeline Integration
|
|
55
|
+
|
|
56
|
+
Run validations in this order in your CI pipeline:
|
|
57
|
+
|
|
58
|
+
```
|
|
59
|
+
validate (kubeconform) -> lint (helm lint / kustomize build) -> policy-check (kyverno/polaris) -> dry-run (server)
|
|
60
|
+
```
|
|
61
|
+
|
|
62
|
+
A GitHub Actions example that chains these steps is available in the [reference file](https://github.com/LukasNiessen/kubernetes-skill/blob/main/references/validation-and-policy.md#github-actions-example).
|
|
63
|
+
|
|
64
|
+
## Common LLM Mistakes
|
|
65
|
+
|
|
66
|
+
Key validation and policy errors LLMs produce include: using bare `--dry-run` without `=client` or `=server`, omitting CRD schemas in kubeconform (hiding errors), setting Kyverno to `Audit` instead of `Enforce` in production, missing `initContainers` checks in Gatekeeper rules, matching only `Pod` kind (missing workloads created by Deployments), and skipping server-side dry-run in CI. See the full checklist in the [reference file](https://github.com/LukasNiessen/kubernetes-skill/blob/main/references/validation-and-policy.md#llm-mistake-checklist).
|
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
# MCP Integration
|
|
2
|
+
|
|
3
|
+
Guidance for integrating the Kubernetes skill with the Model Context Protocol (MCP). MCP servers can provide live cluster facts, organizational policies, and registry information that improve manifest generation quality.
|
|
4
|
+
|
|
5
|
+
## When to Use MCP
|
|
6
|
+
|
|
7
|
+
MCP integration is valuable when live cluster or organizational context would improve the generated output:
|
|
8
|
+
|
|
9
|
+
- **Cluster facts** -- query the cluster version, available API groups, installed CRDs, or node topology to avoid API drift failures
|
|
10
|
+
- **Organization policies** -- retrieve namespace naming conventions, required labels, approved image registries, or resource quota limits
|
|
11
|
+
- **Registry information** -- look up available image tags, verify image existence, or check signing status before referencing in manifests
|
|
12
|
+
|
|
13
|
+
## What NOT to Do with MCP
|
|
14
|
+
|
|
15
|
+
- **Never retrieve secrets through MCP** -- credentials, tokens, and keys must come from Kubernetes Secrets, ExternalSecrets, or Sealed Secrets, not from MCP context
|
|
16
|
+
- **Never use MCP to bypass authorization** -- MCP data is informational context, not an authorization mechanism; RBAC decisions belong to the cluster
|
|
17
|
+
- **Never treat MCP data as trusted input for security-sensitive fields** -- do not copy MCP-provided values directly into securityContext, RBAC rules, or NetworkPolicy selectors without validation
|
|
18
|
+
|
|
19
|
+
## Safe Integration Pattern
|
|
20
|
+
|
|
21
|
+
Follow this three-step pattern when incorporating MCP data:
|
|
22
|
+
|
|
23
|
+
1. **Query** -- retrieve the specific fact needed (e.g., cluster version, namespace policy)
|
|
24
|
+
2. **Compare** -- validate the MCP response against known constraints (e.g., is the reported version a valid Kubernetes version?)
|
|
25
|
+
3. **Emit assumptions** -- record what MCP data was used and how it influenced the output in the output contract's assumptions section
|
|
26
|
+
|
|
27
|
+
## Output Hygiene
|
|
28
|
+
|
|
29
|
+
Never echo raw MCP data directly into manifests. MCP responses may contain unexpected formatting, stale values, or fields that do not belong in Kubernetes resources. Always:
|
|
30
|
+
|
|
31
|
+
- Extract only the specific values needed
|
|
32
|
+
- Validate format and range before use
|
|
33
|
+
- Document the MCP source in output assumptions
|
|
34
|
+
|
|
35
|
+
## Example Uses
|
|
36
|
+
|
|
37
|
+
**Querying cluster version to select the correct apiVersion:**
|
|
38
|
+
If MCP reports the cluster runs Kubernetes 1.28, use `autoscaling/v2` for HPA (not the removed `v2beta2`). Record the assumption: "Cluster version 1.28 reported via MCP; using autoscaling/v2."
|
|
39
|
+
|
|
40
|
+
**Querying namespace policies:**
|
|
41
|
+
If MCP reports that the `production` namespace enforces PSA restricted and requires the label `cost-center`, include those constraints in generated manifests and note the MCP source.
|
|
42
|
+
|
|
43
|
+
**Querying approved registries:**
|
|
44
|
+
If MCP reports that only `registry.example.com` is allowed, use that registry prefix for all image references and note the source.
|
|
45
|
+
|
|
46
|
+
## Failure Handling
|
|
47
|
+
|
|
48
|
+
If the MCP server is unavailable or returns an error:
|
|
49
|
+
|
|
50
|
+
- **Do not block manifest generation** -- proceed with reasonable defaults
|
|
51
|
+
- **State assumptions explicitly** -- document that MCP was unavailable and list the defaults used (e.g., "MCP unavailable; assuming Kubernetes 1.29, PSS restricted profile, no registry restrictions")
|
|
52
|
+
- **Flag for review** -- note in the output contract that the assumptions should be verified against the actual cluster before applying
|