feat: add VPC network mode to schema [1/3]#424
Merged
Conversation
Fix NetworkModeSchema enum from PUBLIC|PRIVATE to PUBLIC|VPC to match the AWS API. Add NetworkConfigSchema for subnet and security group validation, and networkConfig field to AgentEnvSpec with cross-field validation requiring networkConfig when networkMode is VPC. Changes: - Fix NetworkModeSchema enum: PRIVATE → VPC - Add NetworkConfigSchema (subnet/SG ID regex, min/max array bounds) - Add networkConfig optional field to AgentEnvSpec - Add superRefine cross-field validation - Update LLM-compacted schema documentation - Add 13 new unit tests for VPC schema validation
This was referenced Feb 24, 2026
Contributor
Coverage Report
|
tejaskash
added a commit
that referenced
this pull request
Feb 27, 2026
This reverts commit 4180646.
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
Fix
NetworkModeSchemaenum and add VPC configuration schema support. This is the foundation PR that PR #2 and #3 build on.NetworkModeSchemaenum fromPUBLIC | PRIVATEtoPUBLIC | VPCto match the AWS APINetworkConfigSchemawith subnet ID (subnet-*) and security group ID (sg-*) regex validation, array bounds (1-16)networkConfigoptional field toAgentEnvSpec.superRefine()cross-field validation: VPC mode requiresnetworkConfig, PUBLIC mode rejects itFiles changed (7)
src/schema/constants.tsPRIVATE→VPCsrc/schema/schemas/agent-env.tsNetworkConfigSchema,networkConfigfield,.superRefine()src/schema/llm-compacted/agentcore.tsNetworkConfigtype, updateNetworkModesrc/schema/llm-compacted/mcp.tsNetworkModetypesrc/schema/__tests__/constants.test.tssrc/schema/schemas/__tests__/agent-env.test.tssrc/schema/schemas/__tests__/mcp.test.tsStack
mainmain(includes this PR's commits)main(includes this PR's commits)PRs 2 and 3 can be reviewed in parallel. Merge this first, then 2 and 3 in any order.
Test plan
npm test)