Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 7 additions & 13 deletions configureWorkspace/configDebugProvider.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,23 +6,17 @@
'use strict';

import * as vscode from 'vscode';
export class DockerDebugConfigProvider implements vscode.DebugConfigurationProvider {
import { ext } from '../extensionVariables';

public provideDebugConfigurations(folder: vscode.WorkspaceFolder | undefined, token?: vscode.CancellationToken): vscode.ProviderResult<vscode.DebugConfiguration[]> {
export class DockerDebugConfigProvider implements vscode.DebugConfigurationProvider {

const config: vscode.DebugConfiguration = {
public async provideDebugConfigurations(folder: vscode.WorkspaceFolder | undefined, token?: vscode.CancellationToken): Promise<vscode.DebugConfiguration[]> {
const remoteRoot = await ext.ui.showInputBox({ value: '/usr/src/app', prompt: 'Please enter your Docker remote root' });
return [{
name: 'Docker: Attach to Node',
type: 'node',
request: 'attach',
port: 9229,
address: 'localhost',
localRoot: '\${workspaceFolder}',
remoteRoot: '/usr/src/app',
protocol: 'inspector'
};

return [config];

remoteRoot
}];
}

}
6 changes: 1 addition & 5 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -287,11 +287,7 @@
"type": "node",
"request": "attach",
"name": "Docker: Attach to Node",
"port": 9229,
"address": "localhost",
"localRoot": "^\"\\${workspaceFolder}\"",
"remoteRoot": "/usr/src/app",
"protocol": "inspector"
"remoteRoot": "/usr/src/app"
}
}
]
Expand Down