Skip to content

Commit d18dbc1

Browse files
authored
Fix: s3 endpoint virtual path
Serverless Error --------------------------------------- ServerlessError: S3 error: The bucket you are attempting to access must be addressed using the specified endpoint. Please send all future requests to this endpoint. For more information check http://docs.aws.amazon.com/AmazonS3/latest/API/ErrorResponses.html at /Users/sergio/repo/mt-client-dashboard-api/node_modules/serverless/lib/plugins/aws/provider/awsProvider.js:331:27 at runMicrotasks (<anonymous>) at processTicksAndRejections (internal/process/task_queues.js:97:5) Get Support --------------------------------------------
1 parent f202e4a commit d18dbc1

1 file changed

Lines changed: 3 additions & 4 deletions

File tree

lib/createChangeSet.js

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4,11 +4,10 @@ const _ = require('lodash')
44

55
const createChangeSet = (plugin, stackName, changeSetName, changeSetType) => {
66
const compiledTemplateFileName = 'compiled-cloudformation-template.json'
7-
const templateUrl = `https://s3.amazonaws.com/${plugin.bucketName}/${plugin.serverless.service.package.artifactDirectoryName}/${compiledTemplateFileName}`
7+
const templateUrl = `https://${plugin.bucketName}.s3.${plugin.options.region}.amazonaws.com/${plugin.serverless.service.package.artifactDirectoryName}/${compiledTemplateFileName}`
88

9-
let stackTags = {
10-
STAGE: plugin.options.stage
11-
}
9+
let stackTags = {}
10+
1211
// Merge additional stack tags
1312
if (typeof plugin.serverless.service.provider.stackTags === 'object') {
1413
stackTags = _.extend(stackTags, plugin.serverless.service.provider.stackTags)

0 commit comments

Comments
 (0)