$ docker build -t spring-boot-docker.jar . In the run command, we have specified that the port 8080 on the container should be mapped to the port 9090 on the Host OS.