mirror of
https://github.com/lensapp/lens.git
synced 2025-05-20 05:10:56 +00:00
Fix build issue
Signed-off-by: Sebastian Malton <sebastian@malton.name>
This commit is contained in:
parent
b505409289
commit
8755f1330d
@ -16,7 +16,7 @@ interface Dependencies {
|
|||||||
authenticateRequest: (clusterId: ClusterId, tabId: string, shellToken: string | undefined) => boolean;
|
authenticateRequest: (clusterId: ClusterId, tabId: string, shellToken: string | undefined) => boolean;
|
||||||
|
|
||||||
createShellSession: (args: {
|
createShellSession: (args: {
|
||||||
webSocket: WebSocket;
|
websocket: WebSocket;
|
||||||
cluster: Cluster;
|
cluster: Cluster;
|
||||||
tabId: string;
|
tabId: string;
|
||||||
nodeName?: string;
|
nodeName?: string;
|
||||||
@ -37,8 +37,8 @@ export const shellApiRequest = ({ createShellSession, authenticateRequest, clust
|
|||||||
|
|
||||||
const ws = new WebSocketServer({ noServer: true });
|
const ws = new WebSocketServer({ noServer: true });
|
||||||
|
|
||||||
ws.handleUpgrade(req, socket, head, (webSocket) => {
|
ws.handleUpgrade(req, socket, head, (websocket) => {
|
||||||
const shell = createShellSession({ webSocket, cluster, tabId, nodeName });
|
const shell = createShellSession({ websocket, cluster, tabId, nodeName });
|
||||||
|
|
||||||
shell.open()
|
shell.open()
|
||||||
.catch(error => logger.error(`[SHELL-SESSION]: failed to open a ${nodeName ? "node" : "local"} shell`, error));
|
.catch(error => logger.error(`[SHELL-SESSION]: failed to open a ${nodeName ? "node" : "local"} shell`, error));
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user