[jbosstools-issues] [JBoss JIRA] (JBIDE-22225) Debugging for node.js applications on Openshift

Ilya Buziuk (JIRA) issues at jboss.org
Wed Jun 15 14:45:00 EDT 2016


    [ https://issues.jboss.org/browse/JBIDE-22225?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13253110#comment-13253110 ] 

Ilya Buziuk commented on JBIDE-22225:
-------------------------------------

This issue is trickier than I expected, due to the fact that the app is running inside the docker container. What I tried so far:
- created a docker image with simple node.js app via s2i - https://github.com/sclorg/s2i-nodejs-container
- run the image in a DEV_MODE for debugging

{code}
docker run -p 5858:5858 -p 8080:8080 --env DEV_MODE=true ibuziuk/my-node-app
{code}
- When I now try to debug the app I'm getting null message on handshake (I guess this is because of bridging network adapter)
- The only solution I have found so far for debugging node.js inside docker is to run it with *--net="host"* parameter. 
{code}
docker run --net="host" --env DEV_MODE=true ibuziuk/my-node-app
{code}


Running docker this way allows to perform handshake and makes debugger work.
*--net="host"* gives the container full access to local system services + container will share the host’s network stack and all interfaces from the host will be available to the container.

[~adietish], [~fbricon] Do you happen to know if it is possible / allowed to run image with this option ? According to the documentation:
{code}
Note: --net="host" gives the container full access to local system services such as D-bus and is therefore considered insecure.
{code}

> Debugging for node.js applications on Openshift
> -----------------------------------------------
>
>                 Key: JBIDE-22225
>                 URL: https://issues.jboss.org/browse/JBIDE-22225
>             Project: Tools (JBoss Tools)
>          Issue Type: Feature Request
>          Components: javascript, openshift
>            Reporter: Gorkem Ercan
>            Assignee: Ilya Buziuk
>              Labels: debugging, openshift_v3
>             Fix For: 4.4.x
>
>
> We should be able to start and connect the new debugger to a node.js application running on Openshift.



--
This message was sent by Atlassian JIRA
(v6.4.11#64026)



More information about the jbosstools-issues mailing list