Skip to content

Commit

Permalink
fix(restful): hide AWS key
Browse files Browse the repository at this point in the history
  • Loading branch information
Cynthia2019 committed Jul 31, 2023
1 parent 026e5e6 commit f3122f4
Showing 1 changed file with 4 additions and 12 deletions.
16 changes: 4 additions & 12 deletions resfulservice/src/s3client.js
Original file line number Diff line number Diff line change
@@ -1,20 +1,12 @@

const { S3Client } = require('@aws-sdk/client-s3');

// const s3Client = new S3Client({
// region: process.env.AWS_S3_REGION || 'us-east-2',
// credentials: {
// accessKeyId: process.env.AWS_S3_ACCESS_KEY,
// secretAccessKey: process.env.AWS_S3_SECRET_KEY,
// },
// });

const s3Client = new S3Client({
region: 'us-east-2',
region: process.env.AWS_S3_REGION || 'us-east-2',
credentials: {
accessKeyId: 'AKIAZCLM5UPUQ6TWICHO',
secretAccessKey: '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'
}
accessKeyId: process.env.AWS_S3_ACCESS_KEY,
secretAccessKey: process.env.AWS_S3_SECRET_KEY,
},
});

module.exports = s3Client;

0 comments on commit f3122f4

Please sign in to comment.