refactor(cloudmock-dns): rename domainConfig.Autotend → Primary#50
Merged
Conversation
Last remaining brand-leak in non-test Go: tools/cloudmock-dns owned the helper that reads domain config from a Pulumi YAML, with the field name "Autotend" even when the value defaulted to cloudmock.app. Rename to Primary to match the rest of the codebase post-#36/#38/#42/#46. - domainConfig.Autotend → Primary; all call sites updated. - parsePulumiConfig accepts "primary" as the canonical YAML key, falls back to "autotend" for backwards compat with existing autotend-infra Pulumi configs that still pass that key. - sortedDomains pair key updated from "cloudmock" (which was duplicated for both rows) to "primary" for the primary entry. - Three new test cases: - TestParsePulumiConfig_LegacyAutotendKey — verifies the alias works. - TestParsePulumiConfig_PrimaryWinsOverLegacy — verifies precedence when both are set. - Existing TestParsePulumiConfig updated to use the new "primary" key. The remaining "autotend" mentions in non-test Go (a parser example comment in pkg/iac and the alias-justification comment in pkg/gateway/proxy.go) are accurate descriptive context for historical input shapes / importers — left as-is. Closes #49 Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Last remaining brand-leak in non-test Go. `tools/cloudmock-dns/main.go` owned a `domainConfig` struct field named `Autotend` (with default value `cloudmock.app`), and `parsePulumiConfig` read the primary domain from a YAML key called `autotend`.
Closes #49.
Out of scope
The remaining `autotend` mentions in non-test Go (a parser example comment in `pkg/iac/pulumi.go` and the alias-justification comment in `pkg/gateway/proxy.go`) are accurate descriptive context — left as-is.
Test plan
🤖 Generated with Claude Code