Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion application/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM python:3.10-slim
FROM public.ecr.aws/docker/library/python:3.10-slim

WORKDIR /app

Expand Down
2 changes: 1 addition & 1 deletion application/Dockerfile-api
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM python:3.10-slim
FROM public.ecr.aws/docker/library/python:3.10-slim

WORKDIR /app

Expand Down
3 changes: 0 additions & 3 deletions application/initial_data/README.md
Original file line number Diff line number Diff line change
@@ -1,4 +1 @@
Please download demo data to this folder. For example, run the following command:
```
wget https://github.com/fengxu1211/generative-bi-using-rag/raw/demo_data/application/initial_data/init_mysql_db.sql.zip
```
2 changes: 1 addition & 1 deletion source/resources/lib/aos/aos-stack.ts
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ export class AOSStack extends cdk.Stack {
effect: Effect.ALLOW,
principals: [new AnyPrincipal()],
actions: ["es:*"],
resources: [`arn:aws:es:${cdk.Aws.REGION}:${cdk.Aws.ACCOUNT_ID}:domain/*`]
resources: [`arn:${this.partition}:es:${cdk.Aws.REGION}:${cdk.Aws.ACCOUNT_ID}:domain/*`]
})]
,
vpcSubnets: [
Expand Down
14 changes: 7 additions & 7 deletions source/resources/lib/ecs/ecs-stack.ts
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ constructor(scope: Construct, id: string, props: cdk.StackProps & { cognitoUserP
"es:ESHttpDelete"
],
resources: [
`arn:aws:es:${cdk.Aws.REGION}:${cdk.Aws.ACCOUNT_ID}:domain/*`
`arn:${this.partition}:es:${cdk.Aws.REGION}:${cdk.Aws.ACCOUNT_ID}:domain/*`
]
});
taskRole.addToPolicy(openSearchAccessPolicy);
Expand All @@ -82,7 +82,7 @@ constructor(scope: Construct, id: string, props: cdk.StackProps & { cognitoUserP
"dynamodb:Query"
],
resources: [
`arn:aws:dynamodb:${cdk.Aws.REGION}:${cdk.Aws.ACCOUNT_ID}:table/*`,
`arn:${this.partition}:dynamodb:${cdk.Aws.REGION}:${cdk.Aws.ACCOUNT_ID}:table/*`,
]
});
taskRole.addToPolicy(dynamoDBAccessPolicy);
Expand All @@ -93,8 +93,8 @@ constructor(scope: Construct, id: string, props: cdk.StackProps & { cognitoUserP
"secretsmanager:GetSecretValue"
],
resources: [
`arn:aws:secretsmanager:${cdk.Aws.REGION}:${cdk.Aws.ACCOUNT_ID}:secret:opensearch-host-url*`,
`arn:aws:secretsmanager:${cdk.Aws.REGION}:${cdk.Aws.ACCOUNT_ID}:secret:opensearch-master-user*`
`arn:${this.partition}:secretsmanager:${cdk.Aws.REGION}:${cdk.Aws.ACCOUNT_ID}:secret:opensearch-host-url*`,
`arn:${this.partition}:secretsmanager:${cdk.Aws.REGION}:${cdk.Aws.ACCOUNT_ID}:secret:opensearch-master-user*`
]
});
taskRole.addToPolicy(opensearchHostUrlSecretAccessPolicy);
Expand All @@ -107,7 +107,7 @@ constructor(scope: Construct, id: string, props: cdk.StackProps & { cognitoUserP
"bedrock:InvokeModelWithResponseStream"
],
resources: [
`arn:aws:bedrock:${cdk.Aws.REGION}::foundation-model/*`
`arn:${this.partition}:bedrock:${cdk.Aws.REGION}::foundation-model/*`
]
});
taskRole.addToPolicy(bedrockAccessPolicy);
Expand All @@ -121,8 +121,8 @@ constructor(scope: Construct, id: string, props: cdk.StackProps & { cognitoUserP
"cognito-idp:*"
],
resources: [
`arn:aws:cognito-idp:${cdk.Aws.REGION}:${cdk.Aws.ACCOUNT_ID}:userpool/*`,
`arn:aws:cognito-identity:${cdk.Aws.REGION}:${cdk.Aws.ACCOUNT_ID}:identitypool/*`
`arn:${this.partition}:cognito-idp:${cdk.Aws.REGION}:${cdk.Aws.ACCOUNT_ID}:userpool/*`,
`arn:${this.partition}:cognito-identity:${cdk.Aws.REGION}:${cdk.Aws.ACCOUNT_ID}:identitypool/*`
]
});
taskRole.addToPolicy(cognitoAccessPolicy);
Expand Down