一键导入
argocd-app-patterns
Use when asking about ArgoCD applications, Helm chart deployment via ArgoCD, sync policies, or typed Helm values patterns.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
菜单
Use when asking about ArgoCD applications, Helm chart deployment via ArgoCD, sync policies, or typed Helm values patterns.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
基于 SOC 职业分类
BuildKite CI/CD pipeline configuration, YAML syntax, dynamic pipelines, and agent management When user works with BuildKite, mentions CI pipelines, .buildkite/ directory, buildkite-agent commands, pipeline YAML, build steps, BuildKite API, or asks about CI configuration, pipeline generation, step dependencies, retry configuration, agent queues, or Kubernetes CI agents
Check PR health status (conflicts, CI, approval) and get actionable next steps
Monitor a PR through reviews and merge conflicts until ready for human review. Use when user says "monitor PR", "watch PR", or wants automated PR workflow. Creates PR if needed, then monitors review comments and merge conflicts. Note: this monorepo's CI runs on Buildkite (`buildkite/monorepo/pr` + `ci/merge-conflict`) per PR — watch it via `bk build view` or the Buildkite web UI, not `gh run`.
Use when asking about generating Helm types, HelmValuesForChart, TypeScript interfaces from Helm charts, or the helm-types CLI.
Talos Linux cluster administration using talosctl When user mentions Talos, talosctl, or Talos cluster operations
Use when asking about version management, Renovate annotations, versions.ts patterns, or pinning image/chart versions.
| name | argocd-app-patterns |
| description | Use when asking about ArgoCD applications, Helm chart deployment via ArgoCD, sync policies, or typed Helm values patterns. |
ArgoCD applications manage Helm charts and sync them to the cluster. All apps use typed Helm values via HelmValuesForChart<"chart-name"> for compile-time safety.
Create src/cdk8s/src/resources/argo-applications/myapp.ts:
import { Chart } from "cdk8s";
import { Application } from "../../generated/imports/argoproj.io.ts";
import versions from "../../versions.ts";
import type { HelmValuesForChart } from "../../misc/typed-helm-parameters.ts";
import { createIngress } from "../../misc/tailscale.ts";
export function createMyAppApp(chart: Chart) {
// Optional: Create Tailscale ingress
createIngress(
chart,
"myapp-ingress",
"myapp",
"myapp-service",
8080,
["myapp"],
false,
);
// Define typed Helm values
const myAppValues: HelmValuesForChart<"myapp"> = {
replicaCount: 1,
service: {
type: "ClusterIP",
port: 8080,
},
persistence: {
enabled: true,
storageClass: "zfs-ssd",
size: "8Gi",
},
};
// Create ArgoCD Application
return new Application(chart, "myapp-app", {
metadata: {
name: "myapp",
},
spec: {
project: "default",
source: {
repoUrl: "https://charts.example.com",
targetRevision: versions["myapp"],
chart: "myapp",
helm: {
valuesObject: myAppValues,
},
},
destination: {
server: "https://kubernetes.default.svc",
namespace: "myapp",
},
syncPolicy: {
automated: {},
syncOptions: ["CreateNamespace=true"],
},
},
});
}
Edit src/cdk8s/src/versions.ts:
const versions = {
// renovate: datasource=helm registryUrl=https://charts.example.com versioning=semver
myapp: "1.2.3",
};
Edit src/cdk8s/src/cdk8s-charts/apps.ts:
import { createMyAppApp } from "../resources/argo-applications/myapp.ts";
export async function createAppsChart(app: App) {
const chart = new Chart(app, "apps", {
namespace: "argocd",
disableResourceNameHashes: true,
});
// ... existing apps
createMyAppApp(chart);
}
syncPolicy: {
automated: {},
syncOptions: ["CreateNamespace=true"],
}
syncPolicy: {
automated: {
prune: true, // Delete removed resources
selfHeal: true, // Revert manual changes
},
syncOptions: ["CreateNamespace=true"],
}
syncPolicy: {
automated: {},
syncOptions: ["CreateNamespace=true", "ServerSideApply=true"],
}
import { Namespace } from "cdk8s-plus-31";
new Namespace(chart, "myapp-namespace", {
metadata: {
name: "myapp",
labels: {
"pod-security.kubernetes.io/enforce": "restricted",
"pod-security.kubernetes.io/audit": "restricted",
"pod-security.kubernetes.io/warn": "restricted",
},
},
});
return new Application(chart, "myapp-app", {
spec: {
// ... source, destination, syncPolicy
ignoreDifferences: [
{
group: "apiextensions.k8s.io",
kind: "CustomResourceDefinition",
jsonPointers: ["/status"],
},
],
},
});
import { createMyAppPostgreSQLDatabase } from "./myapp-postgres.ts";
export function createMyAppApp(chart: Chart) {
// Create PostgreSQL via postgres-operator
createMyAppPostgreSQLDatabase(chart);
const values: HelmValuesForChart<"myapp"> = {
postgresql: {
install: false, // Use external DB
},
global: {
psql: {
password: {
secret: "myapp.myapp-postgresql.credentials.postgresql.acid.zalan.do",
key: "password",
},
main: {
host: "myapp-postgresql",
port: 5432,
database: "myapp",
username: "myapp",
},
},
},
};
// ... create Application
}
export async function createPrometheusApp(chart: Chart) {
const prometheusValues: HelmValuesForChart<"kube-prometheus-stack"> = {
// Disable unavailable components
kubeProxy: { enabled: false },
kubeScheduler: { enabled: false },
// Grafana with external PostgreSQL
grafana: {
"grafana.ini": {
database: {
type: "postgres",
host: "grafana-postgresql:5432",
},
},
persistence: {
enabled: true,
storageClassName: "zfs-ssd",
},
},
// Prometheus with long retention
prometheus: {
prometheusSpec: {
retention: "180d",
storageSpec: {
volumeClaimTemplate: {
spec: {
storageClassName: "zfs-ssd",
resources: {
requests: { storage: "128Gi" },
},
},
},
},
},
},
// Alertmanager with PagerDuty
alertmanager: {
config: {
receivers: [
{
name: "pagerduty",
pagerduty_configs: [{ routing_key_file: "/path/to/key" }],
},
],
},
},
};
return new Application(chart, "prometheus-app", {
metadata: { name: "prometheus" },
spec: {
source: {
repoUrl: "https://prometheus-community.github.io/helm-charts",
chart: "kube-prometheus-stack",
targetRevision: versions["kube-prometheus-stack"],
helm: { valuesObject: prometheusValues },
},
destination: {
server: "https://kubernetes.default.svc",
namespace: "prometheus",
},
syncPolicy: {
automated: {},
syncOptions: ["CreateNamespace=true", "ServerSideApply=true"],
},
},
});
}
src/cdk8s/src/resources/argo-applications/argocd.ts - ArgoCD self-managementsrc/cdk8s/src/resources/argo-applications/prometheus.ts - Complex examplesrc/cdk8s/src/resources/argo-applications/velero.ts - Backup systemsrc/cdk8s/src/resources/argo-applications/gitlab.ts - External DB examplesrc/cdk8s/src/cdk8s-charts/apps.ts - Apps orchestration