mirror of
https://github.com/serverless/serverless.git
synced 2026-01-18 14:58:43 +00:00
resources: add s3 project bucket
This commit is contained in:
parent
ab18ff0fc0
commit
3a4d4e4acd
@ -9,6 +9,10 @@
|
||||
"Type": "String",
|
||||
"Default": "myapp.com"
|
||||
},
|
||||
"aaProjectBucket": {
|
||||
"Type": "String",
|
||||
"Default": "myapp.com"
|
||||
},
|
||||
"aaStage": {
|
||||
"Type": "String"
|
||||
},
|
||||
@ -204,6 +208,16 @@
|
||||
}
|
||||
]
|
||||
}
|
||||
},
|
||||
"ProjectS3Bucket" : {
|
||||
"Type" : "AWS::S3::Bucket",
|
||||
"Properties" : {
|
||||
"AccessControl" : "Private",
|
||||
"BucketName" : {
|
||||
"Ref": "aaProjectBucket"
|
||||
}
|
||||
},
|
||||
"DeletionPolicy" : "Retain"
|
||||
}
|
||||
},
|
||||
"Outputs": {
|
||||
|
||||
@ -488,6 +488,10 @@ exports.cfCreateResourcesStack = function(awsProfile, awsRegion, projRootPath, p
|
||||
ParameterKey: 'aaStage',
|
||||
ParameterValue: projStage,
|
||||
UsePreviousValue: false,
|
||||
}, {
|
||||
ParameterKey: 'aaProjectBucket',
|
||||
ParameterValue: projStage,
|
||||
UsePreviousValue: false,
|
||||
}, {
|
||||
ParameterKey: 'aaDataModelPrefix',
|
||||
ParameterValue: projStage,
|
||||
|
||||
@ -214,6 +214,22 @@ exports.generateLambdaName = function(awsmJson) {
|
||||
});
|
||||
};
|
||||
|
||||
/**
|
||||
* Generate ProjectBucket Name
|
||||
* @param stage
|
||||
* @param region
|
||||
* @param projectDomain
|
||||
* @returns {string}
|
||||
*/
|
||||
|
||||
exports.generateProjectBucketName = function(stage, region, projectDomain) {
|
||||
|
||||
// Sanitize
|
||||
stage = stage.trim().toLowerCase;
|
||||
|
||||
|
||||
};
|
||||
|
||||
/**
|
||||
* Gets all lambda functionName's
|
||||
*
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user