mirror of
https://github.com/danny-avila/LibreChat.git
synced 2026-01-03 09:08:52 +01:00
Expose forcePathStyle config option with a new AWS_FORCE_PATH_STYLE env var
This commit is contained in:
parent
4186db3ce2
commit
75487ca12a
1 changed files with 2 additions and 0 deletions
|
|
@ -28,9 +28,11 @@ export const initializeS3 = (): S3Client | null => {
|
|||
const endpoint = process.env.AWS_ENDPOINT_URL;
|
||||
const accessKeyId = process.env.AWS_ACCESS_KEY_ID;
|
||||
const secretAccessKey = process.env.AWS_SECRET_ACCESS_KEY;
|
||||
const forcePathStyle = ['1', 'true', 'yes'].includes(process.env.AWS_FORCE_PATH_STYLE?.toLowerCase());
|
||||
|
||||
const config = {
|
||||
region,
|
||||
forcePathStyle: forcePathStyle, // Enable path-style addressing
|
||||
// Conditionally add the endpoint if it is provided
|
||||
...(endpoint ? { endpoint } : {}),
|
||||
};
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue