Skip to content

Commit

Permalink
log retention
Browse files Browse the repository at this point in the history
  • Loading branch information
docwho2 committed Nov 18, 2023
1 parent d8f155d commit 28ea98e
Show file tree
Hide file tree
Showing 2 changed files with 48 additions and 2 deletions.
7 changes: 7 additions & 0 deletions Examples/template.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,13 @@ Resources:
SnapStart:
ApplyOn: PublishedVersions

ChimeSMALogGroup:
Type: AWS::Logs::LogGroup
UpdateReplacePolicy: Retain
DeletionPolicy: Delete
Properties:
LogGroupName: !Sub '/aws/lambda/${ChimeSMA}'
RetentionInDays: 90

ChimeSMAPerm:
Type: AWS::Lambda::Permission
Expand Down
43 changes: 41 additions & 2 deletions template.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -120,6 +120,15 @@ Resources:
- S3CrudPolicy:
BucketName: !Ref PromptBucket

PromptCopierLogGroup:
Type: AWS::Logs::LogGroup
UpdateReplacePolicy: Retain
DeletionPolicy: RetainExceptOnCreate
Properties:
LogGroupName: !Sub '/aws/lambda/${PromptCopier}'
RetentionInDays: 30


StaticPrompts:
Type: Custom::PromptCopier
Properties:
Expand Down Expand Up @@ -170,7 +179,14 @@ Resources:
Action:
- polly:SynthesizeSpeech
Resource: '*'


PromptCreatorLogGroup:
Type: AWS::Logs::LogGroup
UpdateReplacePolicy: Retain
DeletionPolicy: RetainExceptOnCreate
Properties:
LogGroupName: !Sub '/aws/lambda/${PromptCreator}'
RetentionInDays: 30

MainPromptEast:
Type: Custom::PromptCreator
Expand Down Expand Up @@ -303,6 +319,13 @@ Resources:
SnapStart:
ApplyOn: PublishedVersions

ChimeSMALogGroup:
Type: AWS::Logs::LogGroup
UpdateReplacePolicy: Retain
DeletionPolicy: Delete
Properties:
LogGroupName: !Sub '/aws/lambda/${ChimeSMA}'
RetentionInDays: 90

ChimeSMAPerm:
Type: AWS::Lambda::Permission
Expand Down Expand Up @@ -397,6 +420,14 @@ Resources:
console.log(JSON.stringify(cresponse));
return {status: 'OK'};
};
TransferCallLogGroup:
Type: AWS::Logs::LogGroup
UpdateReplacePolicy: Retain
DeletionPolicy: Delete
Properties:
LogGroupName: !Sub '/aws/lambda/${TransferCall}'
RetentionInDays: 90

TransferCallConnectIntegration:
Type: AWS::Connect::IntegrationAssociation
Expand Down Expand Up @@ -600,7 +631,15 @@ Resources:
- DynamoDBWritePolicy:
TableName: !Ref SessionTable


ChatGPTLogGroup:
Type: AWS::Logs::LogGroup
UpdateReplacePolicy: Retain
DeletionPolicy: Delete
Properties:
LogGroupName: !Sub '/aws/lambda/${ChatGPT}'
RetentionInDays: 90


LexToChatGPTPerm:
Type: AWS::Lambda::Permission
Properties:
Expand Down

0 comments on commit 28ea98e

Please sign in to comment.