0

I have flume, hdfs container running in boot2docker. I have java code under my /c/users/ directory which is automatically mounted by boot2docker[According to docs].

I copied required jars into running container instead mounting the volume using -v flag. Now i want to debug my code inside the running container.

How do i achieve this? Do i need to mount this and then run the container with debug mode? how do i do this? If any steps or example, then it would be really helpful

Any suggestions?

Gibbs
  • 21,904
  • 13
  • 74
  • 138

1 Answers1

2

Use docker exec -ti container /bin/bash to open a terminal in your container, check the dock https://docs.docker.com/reference/commandline/cli/#exec

user2915097
  • 30,758
  • 6
  • 57
  • 59
  • After running like this, then i copied code. I want to know how to debu step by step like we do IDE – Gibbs Mar 21 '15 at 08:31
  • define a DISPLAY and install your IDE in your container, by debugging, I understood launching some commands in a terminal – user2915097 Mar 21 '15 at 08:40
  • No man. I am pretty sure there is a way to link eclipse with docker by running here we can debug step by step. If i am wrong, please correct me – Gibbs Mar 21 '15 at 08:42
  • Yes you have 31 conatiners with eclipse at https://registry.hub.docker.com/search?q=eclipse&searchfield= but you are back to what I said, install Eclipse in your container, or get a container with Eclipse and install your stuff – user2915097 Mar 21 '15 at 09:01