File tree Expand file tree Collapse file tree 4 files changed +30
-1
lines changed
Expand file tree Collapse file tree 4 files changed +30
-1
lines changed Original file line number Diff line number Diff line change @@ -81,3 +81,26 @@ module "secrets" {
8181 depends_on = [module . cognito ]
8282}
8383
84+ # Deploy the endpoint
85+ resource "aws_bedrockagentcore_agent_runtime" "agent_runtime" {
86+ agent_runtime_name = " langgraph_cx_agent"
87+ description = " Example customer service agent for Agentic AI Foundation"
88+ role_arn = module. bedrock_role . role_arn
89+ authorizer_configuration {
90+ custom_jwt_authorizer {
91+ discovery_url = module. cognito . user_pool_discovery_url
92+ allowed_clients = [module . cognito . user_pool_client_id ]
93+ }
94+ }
95+ agent_runtime_artifact {
96+ container_configuration {
97+ container_uri = module. container_image . ecr_image_uri
98+ }
99+ }
100+ network_configuration {
101+ network_mode = " PUBLIC"
102+ }
103+ protocol_configuration {
104+ server_protocol = " HTTP"
105+ }
106+ }
Original file line number Diff line number Diff line change 1+ data "aws_region" "current" {}
2+
13resource "aws_cognito_user_pool" "user_pool" {
24 name = var. user_pool_name
35
Original file line number Diff line number Diff line change @@ -8,6 +8,10 @@ output "user_pool_arn" {
88 value = aws_cognito_user_pool. user_pool . arn
99}
1010
11+ output "user_pool_discovery_url" {
12+ value = " https://cognito-idp.${ data . aws_region . current . name } .amazonaws.com/${ aws_cognito_user_pool . user_pool . id } /.well-known/openid-configuration"
13+ }
14+
1115output "user_pool_client_id" {
1216 description = " ID of the Cognito User Pool Client"
1317 value = aws_cognito_user_pool_client. user_pool_client . id
Original file line number Diff line number Diff line change @@ -7,7 +7,7 @@ terraform {
77
88 required_providers {
99 aws = {
10- source = " hashicorp/aws"
10+ source = " hashicorp/aws"
1111 # v6.18 added support for Bedrock AgentCore Memory
1212 version = " >= 6.18"
1313 }
You can’t perform that action at this time.
0 commit comments