Docker Community Forums

Share and learn in the Docker community.

Java development with Docker

(Jeroenkops) #1

As a Java developer I would like to have hot code deployment to my application server.
How can I connect my IDE (Intellij) to my application server (glassfish) which is running within a docker container?

(Larry Cai) #2

I guess you work in Windows with boot2docker

What we did is you edit the code using Intellij in windows hosts and running the JEE inside docker container (in boot2docker environment).

The code can be shared via shared folder features (default enabled in boot2docker since 1.3)

You can compile the codes in Intellij as before or compile inside docker JEE container.

(Jeroenkops) #3

Thanks for your answer.

  1. Which folder of your applicationserver did you share?
  2. Which applicationserver did you use?

Fortunately I don’t have to work in Windows
I use a Mac with boot2docker.

(Larry Cai) #4
  1. In MacOS, it is home directory /Users/<id> is shared into VM boot2docker server. see detail

  2. we use karaf, it shall be the same.