principle-everything-as-code
/principle-everything-as-code
Apply when Azure, AWS, Terraform or pipeline resources change, including a portal or console edit. Codify the change in the repository and import any drift so the next plan matches what is running.
- Author
- JayCommit ↗
- Repository
- jstack ↗
- Licence
- MIT
- Last repository change
- 04.11.2026
Assessment and security
- Files in this package
- 2
- Scripts
- 0
- HTML comments
- 0
- URLs in SKILL.md
- 0
No signals detected. Repository changed on 04.11.2026, without references to retired models or APIs.
MIT, open: use and modify while retaining author attribution.
What it does and when to use it
Apply when Azure, AWS, Terraform or pipeline resources change, including a portal or console edit. Codify the change in the repository and import any drift so the next plan matches what is running.
Original author description
Apply when Azure, AWS, Terraform or pipeline resources change, including a portal or console edit. Codify the change in the repository and import any drift so the next plan matches what is running.
How it works
- Use when
- Rules
- Red flags
- Done when
SKILL.md preview
---
name: principle-everything-as-code
description: "Apply when Azure, AWS, Terraform or pipeline resources change, including a portal or console edit. Codify the change in the repository and import any drift so the next plan matches what is running."
license: MIT
---
# Everything as code
The repository is the source of truth for Azure, AWS and the pipelines that ship them. A console edit is drift until it is imported and reviewed as code.
## Use when
- Someone changes a resource in the Azure portal or the AWS console.
- Terraform shows a diff nobody authored in this change.
- A resource already exists and is not in state.
- A pipeline setting is changed in the GitHub or Azure DevOps UI.
## Rules
- Make the change in Terraform, or in the pipeline that applies it. If the portal or console was used, open a follow-up the same day to codify that edit.
- Bring an existing resource into state with an `import` block, then plan and apply through review. A one-off `terraform import` leaves no record in git.
- Run a scheduled plan. Pending changes are drift or an edit that has not been applied. Import the drift, revert it, or raise a reviewed change. Plan exit codes are in `principle-change-safety`.
- A click-fix that is left unimported is overwritten or duplicated on the next apply.
- Keep pipeline definitions and environment checks in code where the platform allows it. A UI-only edit still needs a reviewed follow-up.
- Treat `terraform plan -generate-config-out` as a draft. Rename resources, drop unused arguments and strip secret material before you commit it. See `principle-no-static-credentials`.
- Keep the rollback in code as well, so a revert is another reviewed plan. See `principle-rollback-first`.
```hcl
import {
to = azurerm_resource_group.example
id = "/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/example"
}
```
## Red flags
- Production was fixed in the portal and the code was left stale.
- Resources in the subscription or account belong to no state and no owner.
- The next apply would overwrite a live hotfix.
- A scheduled plan reports changes and nobody is assigned to triage them.
- Role assignments exist in the portal and not in Terraform.
## Done when
- The desired change is in reviewed code.
- An imported resource plans with no unexpected diff.
- Console drift has been imported or deliberately reverted.
Files in this package (2)
- SKILL.md 2 KB
- tests/prompts.md 1 KB
Versions
The database has no other skills named principle-everything-as-code.
Database snapshot: 13.11.2026 · package version 651e8455aea8 (SHA-256 digest of the entire package)
Downloads in the last 30 days: 0 · ranking
Report a problem with this skill: harmful content, incorrect descriptions or an author’s removal request.
Similar skills
- 90principle-stop-at-approval
Use when an agent is about to apply, merge, deploy, or grant access for Azure, AWS, Terraform, or a pipeline. Prepare the diff and stop at the human approval that already exists. - 100terraform-drift
Detect and reconcile Terraform drift on Azure and AWS. Use when a scheduled plan exits with changes you did not ship, or Activity Log or CloudTrail shows a change made outside the code. - 86generate-modern-terraform-code-for-azure
Guidelines for generating modern Terraform code for Azure Triggers on: **/*.tf - 100terraform-azure
Provision Azure infrastructure with Terraform. Configure providers, manage state, and deploy resources. Use when implementing IaC for Azure. - 100terraform-azure
Provision Azure infrastructure with Terraform. Configure providers, manage state, and deploy resources. Use when implementing IaC for Azure. - 100cloud-resource-post-provisioning-validation-and-drift-detection
Verifies what actually got provisioned in AWS/Azure/GCP matches declared intent, via terraform plan drift checks, AWS Config conformance packs, and Azure Policy compliance scans, plus tag/policy compliance checks against a resource baseline. Use when a user asks to "check for…