Convert SFTP Client to use local internal docker IPs for connection.
This removes the need for SFTP-Links to be online!
This commit is contained in:
@ -622,10 +622,16 @@ document.addEventListener('DOMContentLoaded', () => {
|
||||
}
|
||||
|
||||
function updateSftpCacheUI(message) {
|
||||
console.log(message)
|
||||
if (message.data?.hostname && message.data?.port && message.data?.user && message.data?.password) {
|
||||
// For testing, this is currently configured to be internally networked to port 22 for the given container.
|
||||
// The IP Address is sent from server side on page load, in theory, this should allow us to always allow
|
||||
// SFTP Client to WORK! Even if SFTP Holesail ports are down!
|
||||
// To Revert, move hostname to message.data.hostname and port to message.data.port
|
||||
// Doing so will configure the connection to the Jump node.
|
||||
sftpCredentials = {
|
||||
hostname: message.data.hostname,
|
||||
port: message.data.port,
|
||||
hostname: message.data.ipAddress,
|
||||
port: 22,
|
||||
user: message.data.user,
|
||||
password: message.data.password
|
||||
};
|
||||
@ -1562,10 +1568,11 @@ document.addEventListener('DOMContentLoaded', () => {
|
||||
}
|
||||
|
||||
async function connectSftp() {
|
||||
if (!isSftpOnline) {
|
||||
showNotification('SFTP is offline. Please try again later.', 'error', 'sftp-offline');
|
||||
return;
|
||||
}
|
||||
// Only enable this if we are using Jump Box based SFTP Connections
|
||||
// if (!isSftpOnline) {
|
||||
// showNotification('SFTP is offline. Please try again later.', 'error', 'sftp-offline');
|
||||
// return;
|
||||
// }
|
||||
|
||||
if (!sftpCredentials) {
|
||||
showNotification('SFTP credentials not available.', 'error', 'sftp-credentials');
|
||||
|
Reference in New Issue
Block a user