82 lines
2.0 KiB
JSON
82 lines
2.0 KiB
JSON
{
|
|
"AWSTemplateFormatVersion": "2010-09-09",
|
|
"Description": "The AWS CloudFormation template for this Serverless application",
|
|
"Resources": {
|
|
"ServerlessDeploymentBucket": {
|
|
"Type": "AWS::S3::Bucket",
|
|
"Properties": {
|
|
"BucketEncryption": {
|
|
"ServerSideEncryptionConfiguration": [
|
|
{
|
|
"ServerSideEncryptionByDefault": {
|
|
"SSEAlgorithm": "AES256"
|
|
}
|
|
}
|
|
]
|
|
}
|
|
}
|
|
},
|
|
"ServerlessDeploymentBucketPolicy": {
|
|
"Type": "AWS::S3::BucketPolicy",
|
|
"Properties": {
|
|
"Bucket": {
|
|
"Ref": "ServerlessDeploymentBucket"
|
|
},
|
|
"PolicyDocument": {
|
|
"Statement": [
|
|
{
|
|
"Action": "s3:*",
|
|
"Effect": "Deny",
|
|
"Principal": "*",
|
|
"Resource": [
|
|
{
|
|
"Fn::Join": [
|
|
"",
|
|
[
|
|
"arn:",
|
|
{
|
|
"Ref": "AWS::Partition"
|
|
},
|
|
":s3:::",
|
|
{
|
|
"Ref": "ServerlessDeploymentBucket"
|
|
},
|
|
"/*"
|
|
]
|
|
]
|
|
},
|
|
{
|
|
"Fn::Join": [
|
|
"",
|
|
[
|
|
"arn:",
|
|
{
|
|
"Ref": "AWS::Partition"
|
|
},
|
|
":s3:::",
|
|
{
|
|
"Ref": "ServerlessDeploymentBucket"
|
|
}
|
|
]
|
|
]
|
|
}
|
|
],
|
|
"Condition": {
|
|
"Bool": {
|
|
"aws:SecureTransport": false
|
|
}
|
|
}
|
|
}
|
|
]
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"Outputs": {
|
|
"ServerlessDeploymentBucketName": {
|
|
"Value": {
|
|
"Ref": "ServerlessDeploymentBucket"
|
|
}
|
|
}
|
|
}
|
|
} |