Docker Compose
Start course
1h 18m

In this course, we will learn the concepts of microservice and spring framework with a focus on Cloud.

Learning Objectives

  • Learn about Cloud

Intended Audience

  • Beginner Java developers
  • Java developers interested in learning how to Build and Deploy RESTful Web Services
  • Java Developers who want to develop web applications using the Spring framework
  • Java Developers who want to develop web applications with microservices
  • Java Developers who wish to develop Spring Boot Microservices with Spring Cloud


  • Basic Java knowledge

Docker compose. Hello dear friends, in this lesson we will talk about Docker Compose and try to start our services using the Docker compose tool. It's a bit similar to a Docker file. It allows you to define your services in a configuration file and start them with your specifications. Let's write our own Docker compose file and start our services. You know, we've already created images of our services using the Docker file. Let's list them. As you see here, first I will create a directory to hold my Docker compose file. Created, located, create Docker compose file. Friends, I want you to keep in mind this file will be in a YAML format and indents are important. Same level property should have the same indentation. 

Give a version number, I write 3.3. Write services tag, I will define my services under it. First, system service, then images system info. You can check the image name by running the docker images command. Under the ports tag, I will define ports that need to be exported. Now, define user service. All right, save the changes. Now, run the command; docker-compose up-d. It seems all is running. Let's check it by the Docker containers command. As you can see, both containers are running. Let's try to open the user interface. Dear friends, it appears that we have successfully deployed our services using the Docker compose tool. Well done. I will see you in the following lesson.


About the Author
Learning Paths

OAK Academy is made up of tech experts who have been in the sector for years and years and are deeply rooted in the tech world. They specialize in critical areas like cybersecurity, coding, IT, game development, app monetization, and mobile development.