Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove join function which appends region to S3 bucket name. #129

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -46,8 +46,8 @@ The following page guides the user through deployment and configuration of the S
1. In `zappa_settings.json` under `src`, replace `aws_region` with the region this lambda will be deployed.
1. Run `local_build.sh`. If you are working on Mac/Windows, run the script with `REQUIRES_SPEKE_SERVER_LAMBDA_LAYER=true` to generate `speke-libs` lambda layer zip file. Note that Docker is required to build the zip file. See the [sidenote](#sidenote-building-the-lambda-on-macwindows) below for more details about the lambda layer.
1. The script will generate required artifacts under `build` folder.
1. Create a new bucket in S3 (For example: `speke-us-east-1`). Create a folder called `speke` and upload the generated `speke-reference` lambda zip file. If you build with `REQUIRES_SPEKE_SERVER_LAMBDA_LAYER=true`, upload the generated `speke-libs` lambda layer zip file to the same folder too.
1. In the generated `speke_reference.json`, replace `rodeolabz` with the name of your created bucket (`speke` is used in this example).
1. Create a new bucket in S3 (For example: `speke-bucket`). Create a folder called `speke` and upload the generated `speke-reference` lambda zip file. If you build with `REQUIRES_SPEKE_SERVER_LAMBDA_LAYER=true`, upload the generated `speke-libs` lambda layer zip file to the same folder too.
1. In the generated `speke_reference.json`, replace `rodeolabz` with the name of your created bucket (`speke-bucket` is used in this example).
1. Use the `speke_reference.json` template in CloudFormation to deploy the speke reference server following the instructions below.

#### **Sidenote:** Building the lambda on Mac/Windows
Expand Down
24 changes: 3 additions & 21 deletions cloudformation/speke_reference.json
Original file line number Diff line number Diff line change
Expand Up @@ -168,16 +168,7 @@
"Condition": "RequiresSPEKEServerLambdaLayer",
"Properties": {
"Content": {
"S3Bucket" : {
"Fn::Join": [
"-", [
"rodeolabz",
{
"Ref": "AWS::Region"
}
]
]
},
"S3Bucket" : "rodeolabz",
"S3Key": "speke/speke-libs-DEV_0_0_0.zip"
}
}
Expand All @@ -186,16 +177,7 @@
"Type": "AWS::Lambda::Function",
"Properties": {
"Code": {
"S3Bucket": {
"Fn::Join": [
"-", [
"rodeolabz",
{
"Ref": "AWS::Region"
}
]
]
},
"S3Bucket": "rodeolabz",
"S3Key": "speke/speke-reference-lambda-DEV_0_0_0.zip"
},
"Layers": {
Expand Down Expand Up @@ -743,4 +725,4 @@
"Description": "URL for the SPEKE server that is called by MediaPackage"
}
}
}
}