Skip to content
This repository has been archived by the owner on Aug 16, 2024. It is now read-only.

Add debug configuration to node-express devfile #69

Merged
merged 2 commits into from
Aug 6, 2019
Merged
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
33 changes: 33 additions & 0 deletions devfiles/nodejs/devfile.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -23,10 +23,43 @@ components:
port: 3000
mountSources: true
commands:
-
name: download dependencies
actions:
- type: exec
component: nodejs
command: npm install
workdir: ${CHE_PROJECTS_ROOT}/nodejs-web-app/app
-
name: run the web app
actions:
- type: exec
component: nodejs
command: nodemon app.js
workdir: ${CHE_PROJECTS_ROOT}/nodejs-web-app/app
-
name: run the web app (debugging enabled)
actions:
- type: exec
component: nodejs
command: nodemon --inspect app.js
workdir: ${CHE_PROJECTS_ROOT}/nodejs-web-app/app
-
name: Attach remote debugger
actions:
- type: vscode-launch
referenceContent: |
{
"version": "0.2.0",
"configurations": [
{
"type": "node",
"request": "attach",
"name": "Attach to Remote",
"address": "localhost",
"port": 9229,
"localRoot": "${workspaceFolder}",
"remoteRoot": "#{workspaceFolder}"
}
]
}