From 13c4dfb095631084f94205d11358046c4cac75bf Mon Sep 17 00:00:00 2001 From: JT Smith Date: Mon, 28 Oct 2024 14:17:44 -0500 Subject: [PATCH] Switched S3File bucket url from app.domain.com.s3.amazonaws.com to s3.amazonaws.com/app.domain.com. And the same for the thumbnail bucket. --- ving/docs/change-log.md | 2 +- ving/record/records/S3File.mjs | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/ving/docs/change-log.md b/ving/docs/change-log.md index a6fe6f45..3bc2f235 100644 --- a/ving/docs/change-log.md +++ b/ving/docs/change-log.md @@ -7,7 +7,7 @@ outline: deep ### 2024-10-28 * Switched jobs to use redis from a remote cluster. - * Switched S3File bucket url from app.domain.com.s3.amazonaws.com to s3.amazonaws.com/app.domain.com. + * Switched S3File bucket url from app.domain.com.s3.amazonaws.com to s3.amazonaws.com/app.domain.com. And the same for the thumbnail bucket. ### 2024-10-27 * Added ego behavior to useVingRecord() and useVingKind() to allow disambiguation of multiple copies of the same record with different views. diff --git a/ving/record/records/S3File.mjs b/ving/record/records/S3File.mjs index 8b96a9d8..4600fd5a 100644 --- a/ving/record/records/S3File.mjs +++ b/ving/record/records/S3File.mjs @@ -98,7 +98,7 @@ export class S3FileRecord extends VingRecord { case 'self': return this.fileUrl(); case 'thumbnail': - return `https://${process.env.VING_AWS_THUMBNAILS_BUCKET}.s3.amazonaws.com/${formatS3FolderName(stringifyId(this.get('id')))}.png`; + return `https://s3.amazonaws.com/${process.env.VING_AWS_THUMBNAILS_BUCKET}/${formatS3FolderName(stringifyId(this.get('id')))}.png`; case 'extension': { const image = extensionMap[this.get('extension')] || 'unknown'; return `/img/filetype/${image}.png`;