map-deployment
C4 deployment view of committed infrastructure: which containers sit on which declared nodes, per environment, and what differs between two environments. Use when 'map deployment', 'deployment diagram', 'what is different in production', 'IaC topology', or 'where does this container run'. Skip when the question is a live cloud inventory, cost, or runtime health.
- License 许可
- MIT
- 最近更新
- 2026-11-15
- Stars
- ★ 30
- Forks
- 7
01 前言 Front Matter
- shell
- bash
- metadata
- { "summary": "Chart IaC deployment topology per environment, with a diff", "workflow-stage": "explore" }
- description
- C4 deployment view of committed infrastructure: which containers sit on which declared nodes, per environment, and what differs between two environments. Use when 'map deployment', 'deployment diagram', 'what is different in production', 'IaC topology', or 'where does this container run'. Skip when the question is a live cloud inventory, cost, or runtime health.
- argument-hint
- [environment] [--diff <env-a> <env-b>] [--dialect likec4|c4-plantuml] [--out <dir>]
- user-invocable
- true
- disable-model-invocation
- false
02 资源文件 10
- 参考文档evals/evals.json13.4 KB
- 脚本scripts/azure-reader.awk27.4 KB
- 脚本scripts/cloudformation-reader.awk6.1 KB
- 脚本scripts/collect-deployment.sh39.5 KB
- 脚本scripts/collect-deployment.test.sh153.5 KB
- 脚本scripts/deployment-diff.awk4.4 KB
- 脚本scripts/pulumi-reader.awk5.1 KB
- 脚本scripts/render-deployment.sh23.1 KB
- 脚本scripts/terraform-reader.awk24.0 KB
- 脚本scripts/yaml-rows.awk18.0 KB
03 SKILL.md 正文
Repository context
The current repository is both the CONSUMER, whose convention home declares where artifacts land, and the DEFAULT SUBJECT, whose tracked IaC declares the topology.
Collect with an individual Bash call, one command per call: the project root,
git rev-parse --show-toplevel. Treat a failure (not a repository, git unavailable) as an unknown
value and carry on; ${CLAUDE_PROJECT_DIR} is the resolver's --root either way.
Purpose
Answer "where does this run, and what is different about that environment" from committed infrastructure as code. Every node traces to a named file. The scripts collect and render. Do not draw a node the script did not emit, and do not describe a live cloud. This is the C4 deployment view; each environment is its own deployment environment in the diagram.
Resolve home and dialect
Read ${CLAUDE_PLUGIN_ROOT}/reference/config.md first. This skill writes into architecture_dir.
It does not read landscape_dialect and adds no dialect key: the diagram dialect is
diagram_dialect.system from the authoring-formats topic doc. likec4 writes deployment.md with
one fenced likec4 block, c4-plantuml with one fenced plantuml block. Mermaid is not offered.
Run bash "${CLAUDE_PLUGIN_ROOT}/lib/resolve-convention-home.sh" --root "${CLAUDE_PROJECT_DIR}" and
follow the exit code; never parse the root instruction file yourself. Exit 0: read
<home>/architecture/README.md for architecture_dir. Exit 1, 2, or 3: no declared home.
Per key, in order: --out <dir> wins for this run alone, then a declared architecture_dir, then
one question. architecture_dir has NO default. An undeclared and unconfirmed home, including
every non-interactive run, STOPS and points at /architecture:setup. Do not invent a directory.
Resolve diagram_dialect.system by restating this ladder, then running the resolver rather than
parsing the topic doc yourself. The ladder is a resolution order, not a task list:
1. Anchor at the repository root: `${CLAUDE_PROJECT_DIR}` when set, otherwise
`git rev-parse --show-toplevel`. Never a CWD-relative read.
2. Resolve the convention home `<home>` with the bundled resolver above. Never hand-parse the root
file.
3. The printed home is repo-relative: join it to the root, then pass
`<root>/<home>/authoring-formats/README.md` to the resolver.
4. Layer order is one layer deep: an explicit `--dialect` argument, then the team convention doc.
There is no personal override.
5. `diagram_dialect.system` has NO default. Allowed values are `likec4` and `c4-plantuml`. When it
is unset, emit no C4 deployment view. The record is still written.
6. Degrade soft, and say so. No pointer, no doc, no key, or an unrecognized value (mermaid
included) each resolve to emitting nothing. The resolver names the cause on stderr. Do not
hard-fail and do not ask the operator to create the surface mid-task.
7. Report provenance: the key, the value, and the layer (`argument`,
`team convention doc <path>`, or `unset (no C4 view emitted)`).
bash "${CLAUDE_PLUGIN_ROOT}/lib/resolve-diagram-dialect.sh" --kind system \
--formats "<root>/<home>/authoring-formats/README.md"
Omit --formats when no convention home resolved. Stdout is likec4, c4-plantuml, or none.
An explicit --dialect likec4|c4-plantuml on the invocation wins and the resolver is not required.
This skill never writes the consumer's root instruction file or its topic doc.
Build the record
"${CLAUDE_SKILL_DIR}/scripts/collect-deployment.sh" \
--repo "<subject-repo>" --out "<architecture_dir>/deployment.json" \
--generated-on "<YYYY-MM-DD|unknown>" \
--containers "<architecture_dir>/containers.json"
Pass --generated-on from git -C <root> log -1 --format=%cs, or unknown when that fails.
Omit --containers when containers.json is not already in the architecture directory; when
present it must be schema_version 1, and an unreadable catalog refuses the run. Pass --live only
when the invocation asked for live state. The script does not call a cloud API.
Shipped readers, every one that is present:
- Docker Compose (
compose.yaml,docker-compose.yml, andcompose.<env>.yaml). The environment is the filename suffix ofcompose.<env>.yaml, otherwise the parent directory name (deploy/<env>/compose.yaml), anddefaultfor a file at the repository root. A base file and itscompose.override.yaml, or the files a tracked.envCOMPOSE_FILElists, merge in Compose merge order into one environment named for the directory: scalars (image,replicas) are overridden,portsandnetworksappend without duplicates,environmentmerges by key. Any other file beside them (a variant with no listed order, an override with no base, a second base) or a!resetor!overridetag is refused by name ascompose-not-mergeable:<file>, never guessed. Environment-per-directory layouts are unaffected. Each service is a compute node, and its placement names it incompute. - Kubernetes manifests whose
kindis Deployment, StatefulSet, DaemonSet, Service, or Ingress. Each container of a workload, a sidecar included, is its own placement, and every container of a workload runs on that workload's one compute node. The environment is the namespace, otherwise the parent directory. A Service selects the containers of each workload in its namespace whose pod template labels hold the whole selector; an Ingress routes to the containers behind each Service its backends name. Each is arelationshipsentry from the Service or Ingress node to a container. A selector that matches no pod template labels draws nothing. - Terraform (
.tf,.tf.json,.tfvars,.tfvars.json), read as text: noterraformbinary, state, or credentials. A root is a directory of configuration that no local module source names. Its environments are the<env>of anenvs/<env>/orenvironments/<env>/path, else one per<env>.tfvarsat or above it, else the directory name (defaultat the repository root).terraform.tfvarsand*.auto.tfvarsapply to every environment of their root and are not environments themselves. Containers come fromaws_ecs_task_definitioncontainer_definitions(jsonencode([...])or heredoc JSON),azurerm_container_app,google_cloud_run_v2_service, andkubernetes_deployment,kubernetes_stateful_set, andkubernetes_daemonset(with or without_v1). Compute nodes areaws_ecs_cluster,aws_eks_cluster,azurerm_container_app_environment,azurerm_kubernetes_cluster,google_container_cluster, and each Kubernetes workload. An ECS container runs on the cluster itsaws_ecs_servicenames, with the service'sdesired_count. A container app runs on the environment itscontainer_app_environment_idnames. A Cloud Run container sits directly in the environment. A module-only root follows local module sources, each resource addressedmodule.<name>.<type>.<name>. A remote module source, or a local one with no tracked configuration, refuses the record asterraform-module-unread:<file>:module.<name>, and the source itself is never printed. A file that does not parse isterraform-unreadable:<file>. A tfvars file with no configuration at or above it isterraform-orphan-tfvars:<file>. - Bicep (
.bicep,.bicepparam) and ARM templates (JSON whose$schemanamesdeploymentTemplate, any scope), read as text: nobiceporazbinary, no registry restore. A root is a template that no module names, or one a parameters file names. Its environments are one per.bicepparamwhoseusingnames it (main.prod.bicepparamisprod) and one per JSON parameters file ($schemanamesdeploymentParameters):<name>.parameters.<env>.jsonbeside<name>.bicepor<name>.json, orparameters.<env>.jsonbeside the directory's only template. With none, the environment is the directory name (defaultat the repository root). Containers come fromMicrosoft.App/containerApps(template.containers,scale.minReplicas,ingress.targetPort),Microsoft.ContainerInstance/containerGroups(each group is the compute node of its containers), andMicrosoft.Web/siteswhoselinuxFxVersionorwindowsFxVersionisDOCKER|<image>(appSettingsare its parameters). Compute nodes areMicrosoft.App/managedEnvironmentsandconnectedEnvironments,Microsoft.Web/serverfarms, andMicrosoft.ContainerService/managedClusters. A container app runs on the environment itsmanagedEnvironmentIdorenvironmentIdnames, a site on itsserverFarmId: a Bicep<symbol>.id, or an ARMresourceId('<type>', <name>)whose name matches a declared resource. A local module (Bicep or ARM) is followed, each resource addressedmodule.<name>.<symbol>. A registry or template-spec module, or a local one that is not a tracked template, refuses the record asbicep-module-unread:<file>:module.<name>, and the source is never printed. A file that does not parse isbicep-unreadable:<file>orarm-unreadable:<file>. A.bicepparamwithusing none,extends, or an untrackedusingtarget isbicep-param-unread:<file>. A JSON parameters file with no template to pair isarm-parameters-unpaired:<file>. A nestedMicrosoft.Resources/deploymentsresource is<bicep|arm>-deployment-unread:<file>:<symbol>. - CloudFormation (YAML or JSON), read as text: no
awsbinary, stack, or credentials. A template namesAWSTemplateFormatVersion, or holds a top-levelResourcessection withAWS::types (Resourcesat the left margin in YAML). The short tags (!Ref,!Sub,!GetAtt,!Join,!If) read the same asRefandFn::*in JSON. Containers come fromAWS::ECS::TaskDefinitionContainerDefinitions(Name,Image,PortMappings,Environment,Secrets), and compute nodes fromAWS::ECS::Cluster. AnAWS::ECS::Servicenames the task definition and cluster it runs (!Refor!GetAtt) and givesDesiredCount. Environments come from parameter files, one per environment, in either JSON shape (theParameterKey/ParameterValuearray, or{"Parameters": {}}):<stem>.<env>.jsonor<stem>.parameters.<env>.jsonbeside<stem>.<ext>, else, when the repository holds exactly one template,<env>.jsonorparameters.<env>.jsonanywhere. With no parameter file the environment is the directory name (defaultat the repository root). ARefto a template parameter and aSubover parameters resolve, from the parameter file and then the parameterDefault. ATransform(SAM, a macro) refuses ascloudformation-transform-unread:<file>, a nestedAWS::CloudFormation::Stackascloudformation-stack-unread:<file>:<id>(itsTemplateURLis never printed), a parameter file that pairs with no template ascloudformation-parameters-unpaired:<file>, and a file that does not parse ascloudformation-unreadable:<file>. - Pulumi YAML: a
Pulumi.yamlwhoseruntimeisyamland that holds its own program (nomain, no runtime options). Its environments are thePulumi.<stack>.yamlfiles beside it, else the directory name. The mapped resources areaws:ecs:Cluster,aws:ecs:TaskDefinition(withcontainerDefinitionsasfn::toJSON), andaws:ecs:Service, in the short or theaws:ecs/<type>:<Type>form.${pulumi.stack}and${pulumi.project}resolve.${key}resolves from the stack file'sconfig(<project>:<key>or<key>), then the project'sconfigdefault.${resource.attr}links a service to its cluster and task definition. A file that does not parse ispulumi-unreadable:<file>. - Both YAML readers refuse anchors, aliases, the
<<merge key, duplicate keys, a tab in the indentation, and more than one document. TheircontainerDefinitionsgiven as anything but a non-empty list (absent, empty, a JSON string, a function) places one container whose image isunresolved:containerDefinitions. - A task definition that two or more ECS services run, in the Terraform, CloudFormation or Pulumi
YAML reader, is placed once per service: each service puts every container on its own cluster
with its own desired count, named
<container>@<service>. The service part is the resource's address in the file (the Terraform label, the CloudFormation logical ID, the Pulumi resource name), not itsnameproperty, so the placement keeps one name in every environment and is diffed like any other container. A task definition one service runs keeps the plain container name. Acontainers.jsonname matches its@<service>placements.
A Pulumi project of any other runtime (nodejs, python, go, dotnet, ...), Helm (a
Chart.yaml, a Terraform helm_release, or a kubernetes:helm.sh/ resource in a Pulumi YAML
program), and Kustomize are recognized and named, never read. If any of them is present, the
record is refused, including when a shipped reader also matches, because a diagram of only the
shipped tool would be a partial read. Shipped readers beside each other (Terraform, Bicep,
CloudFormation, or Pulumi YAML beside Compose) are all read. A repository whose only IaC is a
declined tool is refused as adapter-not-shipped, not drawn empty. The declined Pulumi projects are
the tool pulumi with the runtime in the evidence (Pulumi.yaml (runtime nodejs)); the shipped
reader is the tool pulumi-yaml. Files under CI directories such as .github/ are not IaC and are
skipped.
A resource the Terraform, Bicep, ARM, CloudFormation, or Pulumi YAML reader parses and has no
mapping for is listed in the record's unmapped array (tool, resource type, file) and in the
## Unmapped resources table of deployment.md, never dropped without a trace. When no container
is placed and unmapped is not empty (a Terraform root of only aws_lambda_function and
aws_s3_bucket), the record is refused as no-mapped-container and keeps the list, rather than
drawn as an empty environment. A repository that also places containers is drawn with the list
beside it. The Compose reader adds nothing to the list. The Kubernetes reader lists a CronJob and
a Job (tool kubernetes, the kind, the file) and places none of their containers or parameters,
so a repository of only those is refused as no-mapped-container. They add no environment, and
their kind: must come before spec: for their env entries to stay out of the record. A double-brace expression in
a Compose or Kubernetes value (a Go template in a healthcheck) reads normally; one in a name,
image, namespace, replicas, or kind field refuses the file as unreadable.
Every value the collector writes and the renderer prints passes through
${CLAUDE_PLUGIN_ROOT}/lib/redact-connection.awk. A parameter whose key names a credential, or
whose value carries one (a connection-string password or key, a SAS signature, a GitHub token, a
cloud access key, a private key, URL userinfo, or an HTTP Basic or Bearer credential), is recorded
with an empty value and "redacted":"yes". So is a value resolved from a Terraform variable, a
Bicep, ARM or CloudFormation parameter, or a Pulumi config key whose name names a credential,
whatever the name of the env var it lands in and with or without a native secret marker. Any other
emitted field that carries one prints as [redacted]. A secret must not appear in the record, the
diagram, the diff, or stdout. A diff of two secret values says that the parameter differs and
prints neither value.
A diff compares two environments of one tool over these kinds, for every shipped reader: a
container present in one environment only, image, replicas, ports, a parameter present in one
environment only, a plain parameter value, a secret parameter that differs, a network (a Compose
network or a Kubernetes Service) or an Ingress present in one environment only, and a network
exposure or port or an Ingress host that differs. A compute node (a cluster, service plan or node
pool) of the Terraform, Bicep, ARM, CloudFormation and Pulumi readers is compared too: present in
one environment only (compute-added, compute-removed), or, for Bicep, CloudFormation and
Pulumi, at one address with a different resource type (compute). It is matched by resource
address, not name, since a name usually differs per environment, so a changed name alone is not a
difference. An ARM resource has no stable address, so it is matched by type and its order among
nodes of that type. A Terraform Kubernetes workload and an Azure container group are compute nodes
too. A Kubernetes
container port (containerPort) is the placement's ports. A Kubernetes valueFrom reference
counts as a secret parameter whose presence is compared; envFrom is not read. The report's diff
section lists these kinds, and an empty diff reads No differences of these kinds: ... so a clean
diff is never mistaken for a full comparison.
When <architecture_dir>/containers.json exists, container names that the IaC does not place are
listed. When it does not exist, the artifact says container names came from the IaC.
Render
"${CLAUDE_SKILL_DIR}/scripts/render-deployment.sh" \
--record "<architecture_dir>/deployment.json" --out "<architecture_dir>" \
--dialect "<likec4|c4-plantuml|none>" --env "<environment>" --diff "<env-a>" "<env-b>"
Pass the resolved dialect. With none the script still writes deployment.md with the tools,
environments, diff, and container tables, and draws no diagram block. Omit --env to draw every
collected environment, one deployment environment each inside the one fenced block. Omit --diff
when the invocation did not ask for a comparison. The unmapped resources, when there are any, and
then the diff table follow the tools. An unknown --env or --diff name writes a refusal that
lists the environments and exits 3. In a non-interactive run, stop there.
The script prints one summary line. Keep it:
deployment: status=<drawn|refused> reason=<reason|none> tools=<list> environments=<n> placements=<n> diffs=<n> dialect=<likec4|c4-plantuml|none> unmapped=<n>
Exit 1 means the record is unreadable or not schema_version 1 in the one-object-per-line layout; nothing was written. Do not reformat the record by hand.
Close with the report
End every run with this block, in this order:
- Artifacts: each path written, or
none writtenwhen the run stopped before a home existed. - Status:
drawnorrefused, and the reason when it is a refusal. - Tools: which IaC tools were shipped readers and which were recognized and declined.
- Not drawn: the summary's
unmapped=count and each resource type listed under## Unmapped resourceswith its file, or that none were listed. - Environment: the one drawn, or each environment, and the file that declared it.
- Diff: the summary's
diffs=count, or that--diffwas not requested. - Dialect:
diagram_dialect.system, the value, and the layer (argument,team convention doc <path>, orunset (no C4 view emitted)). - Containers:
map-containersoutput was used, or it was absent and names came from the IaC. - Secrets: redacted. No secret value was written.
- Live: not requested, or requested and refused. No cloud API was called.
Interactive view
After the report, offer an interactive view of deployment.json in one sentence. The markdown and
the record stay authoritative. Build it only with
${CLAUDE_PLUGIN_ROOT}/scripts/build-view.mjs deployment, never hand-written; the shared medium
resolver decides the destination, with this plugin's medium option ${user_config.medium}, or ""
when that reads empty or unsubstituted (never put a ${user_config.*} string in a shell command), and
its report line is printed. Procedure:
${CLAUDE_PLUGIN_ROOT}/reference/rendered-view.md.
What this skill does NOT do
- Call a cloud API, use credentials, or compare live state to the declaration.
- Run
terraform, read Terraform state, or fetch a remote module. - Run
biceporaz, restore a registry module, or evaluate an ARM function. - Run
awsorpulumi, expand a CloudFormationTransform, or evaluateFn::If,Fn::FindInMap,Fn::Join, or a Pulumifn::*function. - Cost, scaling, capacity, or runtime health.
- Apply Helm templates or Kustomize. Those tools are a refusal, not a guessed render.
- Add a dialect key, read
landscape_dialect, or emit mermaid. The dialect is the existingdiagram_dialect.system. - Invent a home, a network, or a node the script did not emit.
Next
- The topology settles a decision worth keeping:
/architecture:record-decision. - The topology needs a deployment change decided:
/planning:design system. - The question is which systems the repository sits among:
/architecture:map-landscape.
Gotchas
- C4 scopes a deployment diagram to one environment. This skill writes one fenced block with
every environment inside it as its own deployment environment;
--envnarrows the block to one. The diff is a table, not a picture. Pointer: when checking a deployment view's scope or elements, fetch C4 deployment diagram § Scope and § Primary and supporting elements live. - C4-PlantUML deployment syntax: read against the README, never run. The renderer writes the
macros. The
C4_Deploymentinclude name is our inference from the README's container example. No PlantUML run has parsed this output.Relis drawn from a container to a network node its placement names, and from a Kubernetes Service or Ingress node to a container in the record'srelationships. Pointer: when checking the macros or the include the renderer writes, fetch C4-PlantUML README § Deployment diagram and § Including the C4-PlantUML library live. - LikeC4 deployment syntax: parsed by the CLI. The record is a probe:
likec4@1.59.4 validateexits 0 on the golden blocks in${CLAUDE_PLUGIN_ROOT}/lib/likec4-golden/(deployment-compose.c4,deployment-kubernetes.c4,deployment-ecs-shared.c4), whichcollect-deployment.test.shdiffs against. Pointer: when checking the syntax the collector writes, fetch LikeC4 deployment model § Deployment nodes, § Deployed instances, § Deployment relationships and deployment views § View definition live. As of: 2026-11-10. Recheck trigger: any of those sections changes that syntax, or a newerlikec4release ships: setLIKEC4_VALIDATE=1when running the test to re-run the CLI. - Labels cannot leave the block. Quotes, backticks, backslashes, and line breaks are stripped
from labels,
@prints as(at), and every identifier is prefixed and numbered, so a hostile name cannot close the fence, end the diagram, or collide with a keyword. - Compose without a
networksentry joins the default network. A service that declares none is recorded ondefault; a service that names a network is recorded on that network. - A required secret is not a topology fact. The value is dropped. The diff can say the parameter differs. It cannot show the value.
- CloudFormation and Pulumi values are resolved, never evaluated. A parameter or config value
resolves only through the sources listed above. Every other function (
Fn::If,Fn::FindInMap,Fn::Join,GetAtt, a pseudo parameter such asAWS::Region,fn::join, a Pulumi variable) is recorded asunresolved:<text>. A resourceCondition,Mappings, andFn::ForEachare not applied, so a conditional resource is drawn in every environment. Only the ECS types above are mapped: an EKS cluster, a Lambda, or anaws:eksorkubernetes:Pulumi resource is not drawn, and its type is listed under## Unmapped resources. A service whose task definition is not declared in the same template is placed as one container whose image isunresolved:taskDefinition. YAML parameter files and CloudFormation git-sync deployment files are not read. - CloudFormation and Pulumi secrets. A parameter with
NoEcho: true, any value holding a{{resolve:...}}dynamic reference, every containerSecretsentry, a Pulumiconfigkey withsecret: true, asecure:stack value, afn::secretwrapper, and a parameter or config key whose name names a credential are redacted wherever they land, including in a name, image or port. A secret that differs between two environments is reported as differing, and neither value is printed. - CloudFormation template shape. Claim: the YAML short form
!Ref nameequalsRef: name, and JSON writes{ "Ref": "name" }. Basis: https://docs.aws.amazon.com/AWSCloudFormation/latest/TemplateReference/intrinsic-function-reference-ref.html. Claim:Fn::Sub,Fn::GetAtt, and the other functions take the same!Nameshort form andFn::Namelong form;Refto a parameter returns its value. Basis: the same reference index, https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/intrinsic-function-reference.html. Claim:AWS::ECS::ServicetakesCluster,DesiredCount,ServiceName, andTaskDefinition. Basis: https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-ecs-service.html. As of: 2026-09-30. Recheck when any of those pages changes a form or property name. - CloudFormation parameters and secrets. The redaction and resolution rules above read
NoEcho,Defaultand the{{resolve:...}}forms. Pointer: when checking what those mean or how a dynamic reference is written, fetch Parameters § Properties and Dynamic references live. Claim: a parameter file is either theParameterKey/ParameterValuearray or a template configuration file with a top-levelParametersobject. Basis: https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/cfn-using-cli-parameters.html. No document names a per-environment file convention, so the pairing rules above are this skill's own. As of: 2026-09-30. Recheck when those pages change the syntax or add a parameter file shape. - Pulumi YAML program and stack shape. The reader maps the project file's
runtime, the program'sresources,variablesandoutputs,configitems,${...}interpolation and thefn::toJSON,fn::secretandfn::joinforms. Pointer: when checking those forms, fetch project file § Attributes, § Runtime options, and the YAML language reference's § Config, § Interpolation, § Built-in variables, § fn::toJSON, § fn::secret and § fn::join live. Claim:Pulumi.<stack>.yamlholds aconfigmap keyed[<namespace>:]<key>, the project name is the default namespace, and an encrypted value issecure: <ciphertext>. Basis: https://www.pulumi.com/docs/concepts/config/ and https://www.pulumi.com/docs/iac/concepts/secrets/. Claim:aws:ecs:Servicetakescluster,taskDefinition,desiredCount, andname, andaws:ecs:TaskDefinitiontakescontainerDefinitionsasfn::toJSONover a list ofname,image,portMappings(containerPort). Basis: https://www.pulumi.com/registry/packages/aws/api-docs/ecs/service/ and https://www.pulumi.com/registry/packages/aws/api-docs/ecs/taskdefinition/. As of: 2026-09-30. Recheck when any of those pages changes a key, thesecure:form, or theruntimeforms. - Bicep and ARM values are resolved, never evaluated. A parameter resolves from a module
paramsargument, then the environment's parameters file, then its default, and${name}inside a Bicep string the same way. An ARM value resolves only when it is exactly[parameters('<name>')];[[opens a literal. A parameter marked@secure(), typedsecurestringorsecureobject, given a Key Vaultreference, or named for a credential is redacted wherever it lands, as is asecretReforsecureValueenv entry. Every var, function, and conditional is recorded asunresolved:<expression>. Afororcopyloop is placed once, aniforconditionis ignored, aresourceIdwith scope arguments matches nothing, andMicrosoft.App/jobsis not mapped. A child resource nested in its parent (a Bicepresourceinside a body, an ARMresourcesarray inside a resource) is listed under its full type, such asMicrosoft.Storage/storageAccounts/blobServices. AMicrosoft.Web/sites/slotsnested in its site, or naming it as its Bicepparent, whose fx version readsDOCKER|is the exception: it places the container<site>/<slot>, its full resource name, on the site'sserverFarmId, with its ownappSettings. Any other slot, including a top-level ARM one, is listed. A container app or container group whose containers are an expression, an empty list, or absent places one container named for the resource, its imageunresolved:<expression>orunresolved:containers. Every other resource type, and a site whose fx version does not readDOCKER|(listed asMicrosoft.Web/sites), is listed under## Unmapped resources. - Bicep module and parameter file forms. The reader tells a local module path from a registry
or template-spec source, and pairs a
.bicepparamfile with its template through itsusingline. Pointer: when checking which module paths are local or how a parameters file names its template, fetch Bicep modules § Path to a module (§ Local file, § File in registry, § File in template spec) and parameter files § Define parameters file and § Extendable parameters file live. - ARM expressions are bracketed strings. The reader resolves only
[parameters('<name>')]and reads[[as a literal. Pointer: when checking the expression and escape rules, fetch template expressions § Escape characters live. - A nested child resource carries one type segment. The reader lists a child nested in its
parent under the parent's full type plus the child's segment (
Microsoft.Web/sites/slots). Pointer: when checking how a nested child writes its type, fetch Bicep child resource name and type § Within parent resource and ARM child resource name and type § Within parent resource live. - A slot with its own image is placed on its site's plan. A
DOCKER|slot places as<site>/<slot>on the site's App Service plan, naming it by its full resource name, whether it is nested in the site or names it with a Bicepparent. Pointer: when deciding how a child's full name is written, or where a slot runs, fetch Bicep child resource name and type § Full resource name outside parent, ARM child resource name and type § Outside parent resource and App Service plans § Considerations for running and scaling an app live. - Terraform values are resolved, never evaluated.
var.Xresolves from a module call argument, then the root's tfvars files, then the variabledefault, and${var.X}inside a string the same way. A variable declaredsensitive = true, or named for a credential, is redacted wherever it lands. Everything else, such as locals, functions other thanjsonencode, conditionals, for-expressions,file(), andtemplatefile(), is recorded asunresolved:<expression>.countandfor_eachare not expanded (the resource is placed once), adynamicblock is not read, and an env list built by an expression records no parameters. A container app, Cloud Run service, or Kubernetes workload whose containers are adynamicblock or an expression places one container named for the resource, its imageunresolved:dynamic container(containersfor Cloud Run) orunresolved:container; adynamicblock beside plain ones adds a second,<name>.dynamic. An ECS task definition with nocontainer_definitionsplaces one container, its imageunresolved:container_definitions. A resource with an empty body (resource "aws_s3_bucket" "b" {}) is placed or listed as unmapped like any other. A.tf.jsonblock type or label written as an array of objects ("resource": [{...}]) reads like the object form. - Only
./and../sources are local. The reader treats only those module sources as local. Pointer: when checking how a local module path is written, fetch module block § Local paths live. - Auto-loaded tfvars rank below the environment's file. The reader ranks the environment's
<env>.tfvarsabove the auto-loaded tfvars files, and a variabledefaultlowest. Pointer: when checking Terraform's precedence, fetch input variables § Assign values to variables live. - A
.tf.jsonblock may be an array of objects at any level. Claim: each label level of a block (a resource's type and name) and its body may be a JSON object or a JSON array of objects, so"resource": [{"aws_s3_bucket": {"b": {}}}]declares the same resource as the object form. Basis: https://raw.githubusercontent.com/hashicorp/hcl/main/json/spec.md (Blocks). As of: 2026-09-30. Recheck when that spec changes where an array may stand in for an object. - One task definition, several services. Each service that runs a shared task definition places
the task definition's containers on its own cluster with its own desired count, named
<container>@<service>. The@separates the two parts, and a label prints it as(at), like any other. Pointer: when deciding whether the cluster and the count belong to the service, or whether@can appear in a container or service name, fetch task definitions, services,nameandserviceNamelive. - Helm reached through IaC is still Helm. Claim: the Terraform Helm provider declares a release
as
resource "helm_release", and the Pulumi Kubernetes provider as the typekubernetes:helm.sh/v3:Release. Basis: https://raw.githubusercontent.com/hashicorp/terraform-provider-helm/main/docs/resources/release.md and https://www.pulumi.com/registry/packages/kubernetes/api-docs/helm/v3/release/. As of: 2026-09-30. Recheck when either page renames the type. Either one declines Helm, which refuses the whole record aspartial-read, because the chart's workloads are not read.kubernetes_manifestand thekubernetes_*types the Terraform reader does not map appear under## Unmapped resources, since the Kubernetes tool itself is a shipped reader. --liveis a refusal. Committed files are not silently substituted for a live comparison.- A reformatted record is refused. Render exits 1 and writes nothing.
- Tracked files only.
git ls-filesis the source list. A tracked symlink is skipped, so it cannot pull in an untracked file.
04 同仓库更多 Skills
track
Backlog reads through the bound tracker: search open and closed items, view one item with its comments and state history. Use when another skill searches or reads tracker items.
reviewer-media
Reviewer media for one pull request: decides whether it needs a narrated walkthrough, builds the storyboard from /review:explain-change's digest, has /explainer-video:produce render it and hands the manifest to /source-control:pull-request media. Use when asked for 'reviewer media', 'a walkthrough video for this PR', 'a produced video of this change', or when pull-request ready or monitor hands a PR over.
route
Model and effort per agent role (orchestrator, worker, verifier, retrieval) for a multi-agent run, resolved through the bundled defaults and the user, team and personal override config layers into fenced JSON with single-agent and fan-out variants and the layer behind each value. Use when asked 'which model for the subagents', 'route the roles' or 'model routing', or before a skill passes a role's model on a spawn.
route
Model and effort per agent role (orchestrator, worker, verifier, retrieval) for a multi-agent run, resolved through the bundled defaults and the user, team and personal override config layers into fenced JSON with single-agent and fan-out variants and the layer behind each value. Use when asked 'which model for the subagents', 'route the roles' or 'model routing', or before a skill passes a role's model on a spawn.
principles
Module-design vocabulary for architecture findings, and the checks built on it. Use when: 'what is a deep module', 'what is a seam', 'deep vs shallow module', 'what is the deletion test', 'leverage and locality', 'module design vocabulary', 'which word do we use for X in architecture findings'. Scanning a codebase for friction is /architecture:improve.
write
Structured five-field bug report (title, steps to reproduce, expected vs actual, justified severity, suggested fix location) from an informal description, read-only. Use when the user names a defect they observed, or asks for one written up ('report a bug', 'file a bug', 'write this up as a bug').