Uh oh!
There was an error while loading. Please reload this page.
fix: allow bedrock marketplace auto-subscription for opencode user - #15
Merged
Conversation
First invocation of a model auto-subscribes the account now that the Model access console page is retired; Bedrock performs the subscription via AWS Marketplace on the caller's behalf. Without these actions, invoking a not-yet-subscribed model fails with a marketplace denial. Scoped with aws:CalledViaLast=bedrock.amazonaws.com per AWS docs.
OpenTofu Plan |
Uh oh!
There was an error while loading. Please reload this page.
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 freeto 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
OpenCode failed on first invoke with:
Since the Model access console page was retired, first invocation of a model auto-subscribes the account — performed by Bedrock via AWS Marketplace on the caller's behalf. The
opencode-bedrockuser lacked those actions, so any not-yet-subscribed model failed.Adds the AWS-documented statement to the user policy, scoped with
aws:CalledViaLast = bedrock.amazonaws.comsoSubscribecan only be exercised through Bedrock.Validation
make test— all canonical pre-commit hooks pass (tofu validate-backend=false, tflint, checkov, fmt, terraform-docs, gitleaks)