mirror of
https://github.com/Dokploy/dokploy.git
synced 2026-07-08 07:25:22 +02:00
fix(wss): handle cloud version restriction in terminal setup
This commit is contained in:
@@ -97,7 +97,12 @@ export const setupTerminalWebSocketServer = (
|
||||
|
||||
const isLocalServer = serverId === "local";
|
||||
|
||||
if (isLocalServer && !IS_CLOUD) {
|
||||
if (isLocalServer) {
|
||||
if (IS_CLOUD) {
|
||||
ws.send("This feature is not available in the cloud version.");
|
||||
ws.close();
|
||||
return;
|
||||
}
|
||||
const port = Number(url.searchParams.get("port"));
|
||||
const username = url.searchParams.get("username");
|
||||
|
||||
|
||||
@@ -34,7 +34,7 @@ export const isValidShell = (shell: string): boolean => {
|
||||
|
||||
export const getShell = () => {
|
||||
if (IS_CLOUD) {
|
||||
return "CLOUD_VERSION";
|
||||
return "NO_AVAILABLE";
|
||||
}
|
||||
switch (os.platform()) {
|
||||
case "win32":
|
||||
|
||||
Reference in New Issue
Block a user