Once you have installed Docker, you are just ready to build a Docker image out of your Java or native executable application. For this purpose, we will quickly build another simple application that inspects some environment variables to determine the container ID where the application is running.
The source code for this chapter is located in the Chapter03/hello-okd folder of this book's GitHub repository. We recommend importing the project into your IDE before you continue.
Let's dive into the code by starting with the REST endpoint class (HelloOKD), which returns some information from a Contexts and Dependency Injection (CDI) service:
package com.packt.quarkus.chapter3;
import javax.ws.rs.GET;
import javax.ws.rs.Path;
import javax.ws.rs.Produces;
import javax.ws.rs.core.MediaType;
import javax.inject.Inject;
@Path("...