cannot connect to JMX with Spring Boot and Docker

I have a Spring Boot app, containerized, running in Docker Cloud, with the following JAVA_OPTS:

-Xmx512m -XX:+UseConcMarkSweepGC -XX:NativeMemoryTracking=summary -Djava.rmi.server.hostname=

when I try to connect to the host with jmc, I get Unnable to connect. This is the url I’m using:

  • docker - multiple projects on one Dockerfile and docker-compose.yml
  • Why doesn't Docker Toolbox work on Mac 10.10.5?
  • How to add already existing ECS Instance to newly created ECS Cluster
  • Copy files from host to docker container then commit and push
  • syntax error in wercker file when using wercker login command
  • I need to run twice docker-compose to not have errors
  • service:jmx:rmi:///jndi/rmi://

    I also have the port 1099 exposed in the container.
    What else can I try?


    This is how I’m starting the container:


    FROM java:8
    VOLUME /chathub
    COPY target/chathub-backend-1.0.0.jar app.jar
    RUN sh -c 'touch app.jar'
    EXPOSE 8080
    ENTRYPOINT ["java","","", "-jar","/app.jar"]

    and the Stackfile:

      image: 'luizkowalski/chathub:qa'
      deployment_strategy: every_node
        - 'DATABASE_URL=xxx'
        - 'JAVA_OPTS=-Xmx512m -XX:+UseConcMarkSweepGC -XX:NativeMemoryTracking=summary -Djava.rmi.server.hostname='
        - MIXPANEL_TOKEN=xxx
      mem_limit: 258m
        - '1099:1099'
        - '8080:8080'
        - sta

  • Using Ansible docker_service module to deploy service to swarm
  • How to set default docker environment variables
  • docker run -v <dir> vs Dockerfile's VOLUME <dir>
  • docker stop and remove container
  • Docker container can't ping out side of network
  • Meteor build locally or on aws host
  • Docker will be the best open platform for developers and sysadmins to build, ship, and run distributed applications.