Restore generic dreadgoad.yaml defaults - #417
Conversation
There was a problem hiding this comment.
Pull request overview
Reverts dreadgoad.yaml back to a generic, non-deployment-specific starter configuration by restoring default environment/provider values and removing the Azure dreadindex-specific environment and variant overrides.
Changes:
- Set default
envtostagingandprovidertoaws, and reverted the pinnedregionto a commented template value. - Reduced
idle_timeoutfrom3600to1200. - Removed the
dreadindexenvironment block andGOAD-dreadindexvariant overrides fromstagingandtest.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
There was a problem hiding this comment.
Pull request overview
Copilot reviewed 1 out of 1 changed files in this pull request and generated no new comments.
Suppressed comments (1)
dreadgoad.yaml:5
instance_profileis hardcoded toWarpgateImageBuilderInstanceProfile, but that identifier isn’t defined or referenced anywhere else in the repo. Sinceami buildpassescfg.InstanceProfilethrough when no flag is set, this template default can cause AWS Image Builder runs to fail for new users unless they happen to have an IAM instance profile with that exact name. Consider leaving it empty (or commented out) so the default matchesviper.SetDefault("instance_profile", "").
instance_profile: WarpgateImageBuilderInstanceProfile # IAM instance profile for EC2 Image Builder
|
Re: the suppressed comment on The name appears nowhere else in the repo except a struct-plumbing assertion in |
PR #344 committed a working dreadgoad.yaml from a one-off deployment: env, provider and region pinned to that deployment, a bespoke environment block, and variant overrides grafted onto the shared staging and test environments. The checked-in config is a template every user starts from, so it should not carry one deployment's state. Restores env: staging, provider: aws, the commented-out region, and idle_timeout: 1200, and drops the deployment-specific variant blocks. Keeps azure in the provider comment list, since that provider support is real. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
The comment described the top-level region as an override defaulting to the inventory. Both halves were wrong: ResolveRegion treats it as the lowest-precedence fallback behind --region/DREADGOAD_REGION and the active environment's region, and the inventory is only consulted by ResolveRegionWithInventory, which just two SSM-adjacent call sites use. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
WarpgateImageBuilderInstanceProfile is a Dreadnode-specific IAM profile that no Terraform in this repo creates, yet the template shipped it as an active default. ami build resolves flag -> cfg.InstanceProfile -> "" and stamps any non-empty value onto every AMI target, and none of the warpgate templates set one themselves, so a new user's build pointed at a profile that does not exist in their account. Commenting it out restores viper's "" default, which lets the instance factory create its own profile. Anyone who needs the named profile can uncomment it or pass --instance-profile. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
33d9cc4 to
b888b93
Compare
dreadgoad.yamlis the template every user starts from, but #344 committed a working copy from a one-off deployment. This reverts the deployment-specific values.Changed
env:back tostagingprovider:back toaws; the hardcoded region is commented out againidle_timeout: 3600→1200Removed
variant/variant_source/variant_target/variant_name) that Variant generator fixes + Azure provisioning support #344 grafted onto the sharedstagingandtestenvironments —stagingisvariant: falseandtestis CIDR-only againFixed
Two pre-existing template bugs, both surfaced in review:
instance_profilewas hardcoded toWarpgateImageBuilderInstanceProfile, an IAM profile no Terraform in this repo creates.ami buildstamps any non-empty value onto every AMI target (ami.go:260-262) and no warpgate template sets one itself, so a new user's build pointed at a profile absent from their account. Now commented out, restoringviper.SetDefault("instance_profile", "")— which is what makes the instance factory create its own profile (iam.tf:37).