A.1 Build the Docker Image

Your application may consist of multiple microservices. Build the source code for each microservice, so that you create an image for each microservice. For each microservice, run the command discussed in this section from the root folder of the microservice for building the Docker image.

  1. Build the application source code to create a container image.
    Use the following command to create a container image with the tag local_image_tag.
    docker build -t local_image_tag .

    When you run this command in your environment, you can specify any tag that you want after the -t option.

  2. Note down the tag that you have associated with this image. You will need to specify this tag later.
The container image that you have created is available in your local Docker container registry.