Skip to content

Commit

Permalink
fix: s3 bucket name randomizer (#13510)
Browse files Browse the repository at this point in the history
* fix: s3 bucket name randamizer

* chore: change uuid length to 5 and change deploy

---------

Co-authored-by: 0.618 <o.6180339@gmail.com>
  • Loading branch information
0618 and 0.618 committed Dec 28, 2023
1 parent 413fcea commit 9034f86
Show file tree
Hide file tree
Showing 3 changed files with 2 additions and 6 deletions.
1 change: 0 additions & 1 deletion packages/amplify-provider-awscloudformation/package.json
Expand Up @@ -61,7 +61,6 @@
"jose": "^4.3.7",
"lodash": "^4.17.21",
"lodash.throttle": "^4.1.1",
"moment": "^2.24.0",
"netmask": "^2.0.2",
"node-fetch": "^2.6.7",
"ora": "^4.0.3",
Expand Down
Expand Up @@ -18,7 +18,6 @@ import _ from 'lodash';
import { v4 as uuid } from 'uuid';

import fs from 'fs-extra';
import moment from 'moment';
import path from 'path';
import sequential from 'promise-sequential';
import { getDefaultTemplateDescription } from './template-description-utils';
Expand Down Expand Up @@ -56,10 +55,9 @@ export const run = async (context: $TSContext): Promise<void> => {
context.exeInfo ??= { inputParams: {}, localEnvInfo: {} as unknown as LocalEnvInfo };
const { projectName } = context.exeInfo.projectConfig;
const initTemplateFilePath = path.join(__dirname, '..', 'resources', 'rootStackTemplate.json');
/* eslint-disable-next-line spellcheck/spell-checker */
const timeStamp = process.env.CIRCLECI ? uuid().substring(0, 5) : `${moment().format('Hmmss')}`;
const uuidStamp = uuid().substring(0, 5);
const { envName = '' } = context.exeInfo.localEnvInfo;
let stackName = normalizeStackName(`amplify-${projectName}-${envName}-${timeStamp}`);
let stackName = normalizeStackName(`amplify-${projectName}-${envName}-${uuidStamp}`);
const awsConfigInfo = await configurationManager.getAwsConfig(context);

await configurePermissionsBoundaryForInit(context);
Expand Down
1 change: 0 additions & 1 deletion yarn.lock
Expand Up @@ -837,7 +837,6 @@ __metadata:
jose: ^4.3.7
lodash: ^4.17.21
lodash.throttle: ^4.1.1
moment: ^2.24.0
netmask: ^2.0.2
node-fetch: ^2.6.7
ora: ^4.0.3
Expand Down

0 comments on commit 9034f86

Please sign in to comment.