Overview
Dockfield V1 is focused on AWS. It can inspect a configured Primary environment, produce an infrastructure snapshot and recovery plan, report coverage and readiness, and provide an operator-controlled recovery workflow toward a configured Secondary environment.
Begin with the existing AWS V1 Scope and Recovery Strategies pages. Confirm each required resource and dependency is covered for your environment before proceeding.
Prerequisites
- A supported Linux or macOS operator environment with Python 3.11 or later.
- AWS CLI v2 configured with a named source profile or an approved role-based identity. Use temporary credentials or IAM Identity Center where available.
- For export, read-only access to the Primary account and network access to the required AWS APIs and HashiCorp provider registry.
- For recovery planning and recovery, separately configured identities for source and destination accounts, with only the permissions required by the selected resource scope.
- Terraform 1.14 or later and below 2.0 for the reverse-engineering output validation workflow.
- A clean, access-controlled output directory with sufficient disk space. Treat exports and evidence as sensitive because they can contain resource identifiers and configuration details.
- For cross-account recovery, both accounts and Regions must be reachable, required resource materials and quotas must be available, and destination prerequisites must be prepared.
Installation profiles: Normal, Medium and Max
These names describe the customer's failure scope. They are operating profiles, not current CLI flags; the V1 CLI does not accept --profile normal|medium|max.
| Profile | Failure scope | V1 status |
|---|---|---|
| Normal | Primary is the candidate failure domain. Recovery is toward Secondary. | Closest to the current one-way Primary-to-Secondary workflow. Validate the exact resource set and readiness; V1 is not production-certified. |
| Medium | Either Primary or Secondary may be the failed environment. | Bidirectional recovery is not established by the current V1 CLI workflow. Treat the reverse direction as unqualified until independently tested and released. |
| Max | Primary, Secondary and the AWS Organization are considered possible failure domains. | Not a supported V1 installation profile. Organization and Control Tower recovery are outside current V1 scope. |
Choose the intended failure scope before installation. Use independent, protected credentials and a trusted recovery destination for each direction you intend to operate.
Installation
Case 1: Normal
Use for a Primary-to-Secondary recovery design, with Primary as the candidate failure domain. Install the V1 package in an isolated virtual environment:
cd v1 python3 -m venv .venv source .venv/bin/activate python -m pip install --upgrade pip python -m pip install -r requirements.txt python -m pip install -e . cp config/accounts.example.json config/accounts.local.json
Complete the local account configuration using your approved source and destination identity method. Keep that file private. Verify the AWS identity before any discovery:
aws sts get-caller-identity --profile source-readonly aws sts get-caller-identity --profile recovery-operator
Case 2: Medium
Install the same package and configure both directions only for assessment. The current V1 workflow does not certify reciprocal recovery. Do not infer that the first direction's successful planning means the reverse direction is safe.
Case 3: Max
Do not deploy this as an Organization-wide recovery mode in V1. Organization and Control Tower recovery are excluded from the current V1 scope. Wait for a release that explicitly supports and qualifies this scope.
After installation, use the CLI's available commands to inspect its current interface:
dockfield --help
Reverse engineering (export) from Primary (PROD)
Run the exporter from a controlled workstation or runner using a read-only source identity. Substitute your profile, account, Region and a new output path. The destination directory must not already contain files.
cd Presales python3 -m venv .venv source .venv/bin/activate python -m pip install -r requirements.txt aws sts get-caller-identity --profile source-readonly RUN="output/primary-YYYYMMDD-HHMM" TMPDIR=/tmp python reverse_engineering.py --source-profile source-readonly --source-account <primary-account-id> --regions <aws-region> --workers 2 --output "$RUN"
Use an explicit Region list for the environment being inventoried. Keep concurrency conservative and follow AWS API throttling. Review the generated coverage and validation reports; an export can finish while still reporting unsupported or incomplete resources. Exit status 2 can indicate a completed export with coverage gaps.
ARD (optional): how to enable it
ARD is optional. The current V1 CLI does not expose an ARD enablement command or a supported feature flag. Do not add guessed configuration keys or CLI switches.
Until an ARD-enabled release documents its prerequisites and commands, use the existing ARD product page for capability context and treat enablement as unavailable in this V1 operator workflow. Before enabling it in a later release, confirm its supported inputs, permissions, data handling, outputs and operational cost in that release's documentation.
Security scanning
Use the previously scoped open-source security scanning stack. Pin tool versions in your controlled environment and review each tool's license and upstream maintenance status before commercial redistribution.
| Tool | Operator use | Example CLI |
|---|---|---|
| TFLint + AWS rules | Lint Terraform and apply AWS-specific rules. | tflint --init && tflint --recursive |
| OPA / Conftest | Evaluate approved policy rules against Terraform plan JSON. | terraform show -json plan.tfplan > plan.jsonconftest test plan.json --policy policy/ |
| Gitleaks | Check a working tree for accidentally committed secrets. | gitleaks dir . |
| Semgrep CE | Run static analysis rules against source files. | semgrep scan --config auto . |
| Google OSV-Scanner | Check supported dependency manifests and lockfiles for known vulnerabilities. | osv-scanner scan source -r . |
| Grype | Scan a built image, filesystem or SBOM for known vulnerabilities. | grype dir:. |
| Dockfield Security Engine | Dockfield's security assessment layer; follow the command and scope documented by the specific released build. | Use only the documented command shipped with that release. |
Run the checks in CI or an isolated review environment. Save machine-readable reports with the release evidence, set severity thresholds in policy, and investigate findings before approving a plan or image.
Excluded from the agreed stack: Trivy/tfsec, KICS, Checkov and Terrascan.
Recovery to Secondary (DR)
Start with a fresh discovery snapshot, create a recovery plan, inspect coverage, run preflight, then review the complete plan and its hash before any recovery action.
dockfield fidelity-discover --config config/accounts.local.json --output out/primary-fidelity.json dockfield fidelity-plan --config config/accounts.local.json --snapshot out/primary-fidelity.json --target dr-1 --region <recovery-region> --output out/dr-1-fidelity-plan.json dockfield fidelity-coverage --plan out/dr-1-fidelity-plan.json --output out/dr-1-fidelity-coverage.json dockfield fidelity-preflight --config config/accounts.local.json --plan out/dr-1-fidelity-plan.json --output out/preflight.json
Review the plan, coverage and preflight evidence with the service owners. Resolve unsupported resources, missing materials, unresolved references, destination limits and data readiness gaps before considering execution.
dockfield fidelity-recover --config config/accounts.local.json --plan out/dr-1-fidelity-plan.json --approve-plan-hash <reviewed-plan-hash> --journal out/dr-1-fidelity-journal.json dockfield fidelity-coverage --plan out/dr-1-fidelity-plan.json --journal out/dr-1-fidelity-journal.json --output out/dr-1-fidelity-coverage.json
Recovery does not automatically promote application traffic. Validate workloads and data with the responsible service teams, then perform traffic changes through your separately approved operational procedure.
ARC manual failover
AWS Application Recovery Controller (ARC) routing controls are not operated by the current Dockfield V1 recovery command, and ARC is outside the current V1 managed scope. This is a separate AWS operator procedure for applications whose ARC cluster, routing controls, health checks, DNS records and safety rules have already been configured and tested.
How routing-control health checks work
Create one routing control for each application cell or endpoint you want to include in traffic routing, for example Primary and Secondary. In the ARC console, open each routing control and create its associated routing-control health check. Then configure Route 53 DNS records for the application name and associate each record with the matching health-check ID: the Primary record points to the Primary endpoint and uses the Primary control's health check; the Secondary failover record points to the Secondary endpoint and uses the Secondary control's health check.
The ARC routing-control health check is not a probe of the application's live health. ARC changes the health-check state when an operator changes the routing control from On to Off or vice versa. Your application monitoring and readiness checks must independently confirm that the destination is healthy and ready to receive traffic. Configure and test the DNS failover policy, TTL behavior, routing-control safety rules and failback before an incident.
| Desired traffic destination | Primary control | Secondary control |
|---|---|---|
| Primary is serving | On | Off |
| Secondary is serving after failover | Off | On |
Prerequisites
- ARC cluster, control panel, Primary and Secondary routing controls, and their health checks already exist.
- Route 53 records for both endpoints are associated with the correct health checks and failover policy.
- Destination readiness is confirmed outside ARC, including application, data and capacity checks.
- Operator has permission to list and update the controls and has recorded the cluster's regional endpoint URL and its AWS Region.
- Safety rules and an approved incident/change record are in place. Keep a tested failback procedure.
Inspect controls and current state
Use a regional ARC cluster endpoint. Set ARC_ENDPOINT_URL to one of the five endpoint URLs for this cluster and ARC_ENDPOINT_REGION to that endpoint's Region. Replace the ARNs and profile with the values for your environment.
aws route53-recovery-cluster list-routing-controls --control-panel-arn <control-panel-arn> --region "$ARC_ENDPOINT_REGION" --endpoint-url "$ARC_ENDPOINT_URL" --profile <arc-operator-profile> aws route53-recovery-cluster get-routing-control-state --routing-control-arn <primary-routing-control-arn> --region "$ARC_ENDPOINT_REGION" --endpoint-url "$ARC_ENDPOINT_URL" --profile <arc-operator-profile> aws route53-recovery-cluster get-routing-control-state --routing-control-arn <secondary-routing-control-arn> --region "$ARC_ENDPOINT_REGION" --endpoint-url "$ARC_ENDPOINT_URL" --profile <arc-operator-profile>
Fail over traffic from Primary to Secondary
After confirming Secondary readiness and getting the required approval, change the two control states together in one batch: Primary Off, Secondary On. This updates the associated ARC health checks, allowing the configured Route 53 failover records to direct new DNS resolution toward Secondary. The command returns no useful response body; verify both routing-control states afterward and independently check DNS resolution and application health.
aws route53-recovery-cluster update-routing-control-states --update-routing-control-state-entries '[{"RoutingControlArn":"<primary-routing-control-arn>","RoutingControlState":"Off"},{"RoutingControlArn":"<secondary-routing-control-arn>","RoutingControlState":"On"}]' --region "$ARC_ENDPOINT_REGION" --endpoint-url "$ARC_ENDPOINT_URL" --profile <arc-operator-profile>Fail back to Primary
Only after Primary is restored, tested and approved as the destination, reverse the pair in one batch: Primary On, Secondary Off. Then verify both states, DNS and application behavior.
aws route53-recovery-cluster update-routing-control-states --update-routing-control-state-entries '[{"RoutingControlArn":"<primary-routing-control-arn>","RoutingControlState":"On"},{"RoutingControlArn":"<secondary-routing-control-arn>","RoutingControlState":"Off"}]' --region "$ARC_ENDPOINT_REGION" --endpoint-url "$ARC_ENDPOINT_URL" --profile <arc-operator-profile>Support boundaries and related pages
- AWS V1 Scope: current resource-family coverage.
- Recovery Strategies: recovery strategy overview.
- ARD: product capability context; no V1 CLI enablement path is currently documented.
Always check the release notes and the exact package version before using commands in a production change window. Command availability and supported resource coverage can change between releases.