@@ -191,6 +191,7 @@ func UploadStaticAssets(ctx context.Context, s3Client *s3.Client, staticAssetsBu
|
||||
"type": "static-email-asset",
|
||||
},
|
||||
ContentType: aws.String(mimeType),
|
||||
CacheControl: aws.String("max-age=3600, public"),
|
||||
},
|
||||
)
|
||||
if err != nil {
|
||||
|
||||
@@ -133,6 +133,7 @@ func (s *Service) PutFile(
|
||||
Key: aws.String(file.GetObjectKey()),
|
||||
Body: content,
|
||||
ContentType: aws.String(file.GetMimeType()),
|
||||
CacheControl: aws.String("private, max-age=3600"),
|
||||
Metadata: metadata,
|
||||
},
|
||||
)
|
||||
|
||||
@@ -351,6 +351,7 @@ func (s AuditService) UploadReport(
|
||||
Key: aws.String(objectKey.String()),
|
||||
Body: req.File.Content,
|
||||
ContentType: aws.String(req.File.ContentType),
|
||||
CacheControl: aws.String("private, max-age=3600"),
|
||||
Metadata: map[string]string{
|
||||
"type": "report",
|
||||
"report-id": reportID.String(),
|
||||
|
||||
@@ -1792,6 +1792,7 @@ func (s *DocumentService) BuildAndUploadExport(ctx context.Context, exportJobID
|
||||
Body: tempFile,
|
||||
ContentLength: ref.Ref(fileInfo.Size()),
|
||||
ContentType: ref.Ref("application/zip"),
|
||||
CacheControl: ref.Ref("private, max-age=3600"),
|
||||
Metadata: map[string]string{
|
||||
"type": "document-export",
|
||||
"export-job-id": exportJob.ID.String(),
|
||||
|
||||
@@ -101,6 +101,7 @@ func (s FileService) UploadAndSaveFile(
|
||||
Body: req.Content,
|
||||
Metadata: s3Metadata,
|
||||
ContentType: aws.String(mimeType),
|
||||
CacheControl: aws.String("private, max-age=3600"),
|
||||
},
|
||||
)
|
||||
if err != nil {
|
||||
|
||||
@@ -729,6 +729,7 @@ func (s *FrameworkService) BuildAndUploadExport(ctx context.Context, exportJobID
|
||||
Body: tempFile,
|
||||
ContentLength: ref.Ref(fileInfo.Size()),
|
||||
ContentType: ref.Ref("application/zip"),
|
||||
CacheControl: ref.Ref("private, max-age=3600"),
|
||||
Metadata: map[string]string{
|
||||
"type": "framework-export",
|
||||
"export-job-id": exportJob.ID.String(),
|
||||
|
||||
@@ -379,6 +379,7 @@ func (s TrustCenterFileService) uploadFile(
|
||||
Key: aws.String(objectKey.String()),
|
||||
Body: fileContent,
|
||||
ContentType: aws.String(contentType),
|
||||
CacheControl: aws.String("private, max-age=3600"),
|
||||
Metadata: map[string]string{
|
||||
"type": "trust-center-file",
|
||||
"trust-center-file-id": trustCenterFileID.String(),
|
||||
|
||||
@@ -399,6 +399,7 @@ func (s TrustCenterReferenceService) uploadLogoFile(
|
||||
Key: aws.String(objectKey.String()),
|
||||
Body: fileContent,
|
||||
ContentType: aws.String(contentType),
|
||||
CacheControl: aws.String("max-age=3600, public"),
|
||||
Metadata: map[string]string{
|
||||
"type": "trust-center-reference-logo",
|
||||
"trust-center-reference-id": referenceID.String(),
|
||||
|
||||
@@ -235,6 +235,7 @@ func (s TrustCenterService) UploadNDA(
|
||||
Key: aws.String(objectKey.String()),
|
||||
Body: req.File,
|
||||
ContentType: &mimeType,
|
||||
CacheControl: aws.String("private, max-age=3600"),
|
||||
Metadata: map[string]string{
|
||||
"type": "trust-center-nda",
|
||||
"trust-center-id": req.TrustCenterID.String(),
|
||||
@@ -412,6 +413,7 @@ func (s TrustCenterService) uploadFile(
|
||||
Key: aws.String(objectKey.String()),
|
||||
Body: fileUpload.Content,
|
||||
ContentType: &mimeType,
|
||||
CacheControl: aws.String("max-age=3600, public"),
|
||||
Metadata: map[string]string{
|
||||
"type": fileType,
|
||||
"trust-center-id": trustCenter.ID.String(),
|
||||
|
||||
@@ -130,6 +130,7 @@ func (s VendorBusinessAssociateAgreementService) Upload(
|
||||
Key: aws.String(objectKey.String()),
|
||||
Body: req.File,
|
||||
ContentType: &mimeType,
|
||||
CacheControl: aws.String("private, max-age=3600"),
|
||||
Metadata: map[string]string{
|
||||
"type": "vendor-business-associate-agreement",
|
||||
"vendor-id": vendorID.String(),
|
||||
|
||||
@@ -130,6 +130,7 @@ func (s VendorDataPrivacyAgreementService) Upload(
|
||||
Key: aws.String(objectKey.String()),
|
||||
Body: req.File,
|
||||
ContentType: &mimeType,
|
||||
CacheControl: aws.String("private, max-age=3600"),
|
||||
Metadata: map[string]string{
|
||||
"type": "vendor-data-privacy-agreement",
|
||||
"vendor-id": vendorID.String(),
|
||||
|
||||
Reference in New Issue
Block a user