Skip to content

Commit

Permalink
Add the deployment region to OAC Name property (#368)
Browse files Browse the repository at this point in the history
* Add the deployment region to OAC Name property

This fixes an issue introduced in
995f9d9 that affected users who have
multiple S3F2 instances deployed within the same AWS account, using the
same ResourcePrefix parameter, but in different regions.

The issue prevented the stack from deploying because CloudFront
resources are global (not namespaced to a region), and the name must be
unique within an AWS account.

Note, for multiple deployments within an account we'd recommend using
a different ResourcePrefix, but we are fixing this as it worked in
previous releases.

* Update changelog

* Docs: Add when to change ResourcePrefix parameter

* Release v0.61
  • Loading branch information
ctd authored Jul 6, 2023
1 parent 8bb9d99 commit efc6889
Show file tree
Hide file tree
Showing 4 changed files with 12 additions and 4 deletions.
7 changes: 7 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,12 @@
# Change Log

## v0.61

- [#368](https://github.com/awslabs/amazon-s3-find-and-forget/issues/368): Fix
an issue that prevented deployments for users who have multiple S3F2 instances
deployed within the same AWS account, using the same ResourcePrefix parameter,
but in different regions.

## v0.60

- [#367](https://github.com/awslabs/amazon-s3-find-and-forget/pull/367): Fix
Expand Down
3 changes: 2 additions & 1 deletion docs/USER_GUIDE.md
Original file line number Diff line number Diff line change
Expand Up @@ -261,7 +261,8 @@ resources.
Bucket containing Front-end and Back-end pre-built artefacts. Use this if
you are using a customised version of these artefacts.
- **ResourcePrefix:** (Default: S3F2) Resource prefix to apply to resource
names when creating statically named resources.
names when creating statically named resources. Change this when deploying
multiple instances of the solution within an AWS account.
- **KMSKeyArns** (Default: "") Comma-delimited list of KMS Key Arns used for
Client-side Encryption. Leave empty if data is not client-side encrypted
with KMS.
Expand Down
4 changes: 2 additions & 2 deletions templates/template.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
AWSTemplateFormatVersion: "2010-09-09"
Transform: AWS::Serverless-2016-10-31
Description: Amazon S3 Find and Forget (uksb-1q2j8beb0) (version:v0.60)
Description: Amazon S3 Find and Forget (uksb-1q2j8beb0) (version:v0.61)

Parameters:
AccessControlAllowOriginOverride:
Expand Down Expand Up @@ -206,7 +206,7 @@ Conditions:
Mappings:
Solution:
Constants:
Version: 'v0.60'
Version: 'v0.61'

Resources:
TempBucket:
Expand Down
2 changes: 1 addition & 1 deletion templates/web_ui.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,7 @@ Resources:
Properties:
OriginAccessControlConfig:
Description: S3F2 Web UI
Name: !Sub "${ResourcePrefix}-WebUI-OAC"
Name: !Sub "${ResourcePrefix}-${AWS::Region}-WebUI-OAC"
OriginAccessControlOriginType: s3
SigningBehavior: always
SigningProtocol: sigv4
Expand Down

0 comments on commit efc6889

Please sign in to comment.