mirror of
https://github.com/farcasclaudiu/Flowise.git
synced 2026-06-28 23:01:09 +03:00
Merge pull request #1381 from tirongi/bugfix/ElasticClientCustomURL
[BUGFIX/REGRESSION] Fix wrong elastic client setup when use custom URL
This commit is contained in:
@@ -183,13 +183,26 @@ const prepareConnectionOptions = (
|
|||||||
} else if (cloudId) {
|
} else if (cloudId) {
|
||||||
let username = getCredentialParam('username', credentialData, nodeData)
|
let username = getCredentialParam('username', credentialData, nodeData)
|
||||||
let password = getCredentialParam('password', credentialData, nodeData)
|
let password = getCredentialParam('password', credentialData, nodeData)
|
||||||
elasticSearchClientOptions = {
|
if (cloudId.startsWith('http')) {
|
||||||
cloud: {
|
elasticSearchClientOptions = {
|
||||||
id: cloudId
|
node: cloudId,
|
||||||
},
|
auth: {
|
||||||
auth: {
|
username: username,
|
||||||
username: username,
|
password: password
|
||||||
password: password
|
},
|
||||||
|
tls: {
|
||||||
|
rejectUnauthorized: false
|
||||||
|
}
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
elasticSearchClientOptions = {
|
||||||
|
cloud: {
|
||||||
|
id: cloudId
|
||||||
|
},
|
||||||
|
auth: {
|
||||||
|
username: username,
|
||||||
|
password: password
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user