feature-open-with-vscode #1
@@ -92,7 +92,8 @@ export default class RemoteContainer {
|
||||
} else {
|
||||
console.log(`[RemoteContainer] Running in local environment, attempting firstConnect`);
|
||||
try {
|
||||
await this.firstConnect(host, hostname, username, port)
|
||||
//传入真实IP
|
||||
await this.firstConnect(host, '192.168.10.4', username, port)
|
||||
.then((res) => {
|
||||
if (res === 'success') {
|
||||
console.log(`[RemoteContainer] firstConnect succeeded, opening remote folder`);
|
||||
@@ -318,7 +319,7 @@ export default class RemoteContainer {
|
||||
let terminal = vscode.window.activeTerminal || vscode.window.createTerminal(`Ext Terminal`);
|
||||
terminal.show(true);
|
||||
|
||||
const command = `code --remote ssh-remote+${username}@${host}:${port} ${path} --reuse-window`;
|
||||
const command = `code --remote ssh-remote+root@${host}:${port} ${path} --reuse-window`;
|
||||
console.log(`[RemoteContainer] Sending command to terminal: ${command}`);
|
||||
|
||||
// 在原窗口打开
|
||||
|
||||
Reference in New Issue
Block a user