Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: UserDataFiles store uploads not proxied through server because of missing setting #32182

Merged
merged 4 commits into from
Apr 29, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions .changeset/lazy-gorilas-shop.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
---
"@rocket.chat/meteor": patch
"@rocket.chat/i18n": patch
---

Fixed an issue with object storage settings that was not allowing admins to decide if files generated via "Export conversation" feature were being proxied through server or not.
21 changes: 21 additions & 0 deletions apps/meteor/server/settings/file-upload.ts
Original file line number Diff line number Diff line change
Expand Up @@ -187,6 +187,13 @@ export const createFileUploadSettings = () =>
value: 'AmazonS3',
},
});
await this.add('FileUpload_S3_Proxy_UserDataFiles', false, {
type: 'boolean',
enableQuery: {
_id: 'FileUpload_Storage_Type',
value: 'AmazonS3',
},
});
});

await this.section('Google Cloud Storage', async function () {
Expand Down Expand Up @@ -244,6 +251,13 @@ export const createFileUploadSettings = () =>
value: 'GoogleCloudStorage',
},
});
await this.add('FileUpload_GoogleStorage_Proxy_UserDataFiles', false, {
type: 'boolean',
enableQuery: {
_id: 'FileUpload_Storage_Type',
value: 'GoogleCloudStorage',
},
});
});

await this.section('File System', async function () {
Expand Down Expand Up @@ -302,6 +316,13 @@ export const createFileUploadSettings = () =>
value: 'Webdav',
},
});
await this.add('FileUpload_Webdav_Proxy_UserDataFiles', false, {
type: 'boolean',
enableQuery: {
_id: 'FileUpload_Storage_Type',
value: 'Webdav',
},
});
});

await this.add('FileUpload_Enabled_Direct', true, {
Expand Down
6 changes: 6 additions & 0 deletions packages/i18n/src/locales/en.i18n.json
Original file line number Diff line number Diff line change
Expand Up @@ -2360,6 +2360,8 @@
"FileUpload_GoogleStorage_Proxy_Uploads": "Proxy Uploads",
"FileUpload_GoogleStorage_Proxy_Uploads_Description": "Proxy upload file transmissions through your server instead of direct access to the asset's URL",
"FileUpload_GoogleStorage_Secret": "Google Storage Secret",
"FileUpload_GoogleStorage_Proxy_UserDataFiles": "Proxy User Data Files",
"FileUpload_GoogleStorage_Proxy_UserDataFiles_Description": "Proxy user data file transmissions through your server instead of direct access to the asset's URL",
"FileUpload_GoogleStorage_Secret_Description": "Please follow [these instructions](https://github.com/CulturalMe/meteor-slingshot#google-cloud) and paste the result here.",
"FileUpload_json_web_token_secret_for_files": "File Upload Json Web Token Secret",
"FileUpload_json_web_token_secret_for_files_description": "File Upload Json Web Token Secret (Used to be able to access uploaded files without authentication)",
Expand Down Expand Up @@ -2390,6 +2392,8 @@
"FileUpload_S3_Proxy_Avatars_Description": "Proxy avatar file transmissions through your server instead of direct access to the asset's URL",
"FileUpload_S3_Proxy_Uploads": "Proxy Uploads",
"FileUpload_S3_Proxy_Uploads_Description": "Proxy upload file transmissions through your server instead of direct access to the asset's URL",
"FileUpload_S3_Proxy_UserDataFiles": "Proxy User Data Files",
"FileUpload_S3_Proxy_UserDataFiles_Description": "Proxy user data file transmissions through your server instead of direct access to the asset's URL",
"Hold_Call_EE_only": "Hold Call (Enterprise Edition only)",
"FileUpload_S3_Region": "Region",
"FileUpload_S3_SignatureVersion": "Signature Version",
Expand All @@ -2401,6 +2405,8 @@
"FileUpload_Webdav_Proxy_Avatars_Description": "Proxy avatar file transmissions through your server instead of direct access to the asset's URL",
"FileUpload_Webdav_Proxy_Uploads": "Proxy Uploads",
"FileUpload_Webdav_Proxy_Uploads_Description": "Proxy upload file transmissions through your server instead of direct access to the asset's URL",
"FileUpload_Webdav_Proxy_UserDataFiles": "Proxy User Data Files",
"FileUpload_Webdav_Proxy_UserDataFiles_Description": "Proxy user data file transmissions through your server instead of direct access to the asset's URL",
"FileUpload_Webdav_Server_URL": "WebDAV Server Access URL",
"FileUpload_Webdav_Upload_Folder_Path": "Upload Folder Path",
"FileUpload_Webdav_Upload_Folder_Path_Description": "WebDAV folder path which the files should be uploaded to",
Expand Down
Loading