 in the previous video I showed you how to create this Docker file and in this video we'll show you how to actually build and run the image. Now I'm gonna be staying on the same branch here you can see down on the bottom of the IDE I'm still on the GitHub branch of Docker base. I'm only gonna be doing demonstration here of the runtime application and I'll be running this right from IntelliJ. IntelliJ does have a terminal that you can bring up and clear that message and here you can see that I am in the root of the project now one very important thing here is the way Docker build command works it will work from the current directory and down so you can't go up that is a security thing and I actually found that out by the hard way and took me a little bit to figure that little bit out so here in the read me you can see that I've got a couple commands here so I got Docker build minus F I'll be putting this in the read me for your reference that you'll have access to this command so here let's go ahead and do just make sure Docker is running so if you do Docker ps you can see that I do have a Postgres image running that is perfectly fine that won't bother us so I'm going to do a Docker build now for this to work you can see that I have my target directory exploded and that the jar is there so you do need to run Maven package before running this otherwise it will not work so I'm going to do Docker build minus F and I'm going to say from here go source main and I'm just hitting the tab key for the auto complete and see the Docker file so that minus F tells the file that we want to build and because I'm running from the root of the project I'll be able to access that because you can see in the Docker file remember I have that relative path so I'm running from this point in the file system so this will be able to traverse down and copy that file in so if I ran from the Docker base folder this would not be happy so important aspect there so that's setting the file and then I want to do minus T I'm going to give this a tag on window and here I am going to do KBE rest like so go ahead and tag that and Docker build and I see my mistake I forgot to say current directory there at the end so now we can see that we went out and we built it actually built fairly quick and the first time you run it I've already built a couple times so the open JDK that image is already there so it's pretty lightweight for this to go ahead and build so we're saying from I didn't have to download that from the internet the actual copy and stuff that went fairly quick now let's go ahead and run that you can see I set up the second man here for running it like clear the screen I can say Docker run and I'm just gonna say minus P 80 80 that's gonna map 80 80 to the local host and we'll do KBE rest and I'm not gonna use the minus D flag I put the minus D flag there in the command because I want to go ahead and observe this the startup log so I'm just gonna be starting this up and we'll go ahead you can see that I am monitoring the logs and that is now coming up we can see that we have the normal spring boot startup so now this applications up and running inside of a Docker context and a Docker image and is running locally on my host port 8080 was exposed so if I wanted to curl from a command line or use postman or something I would be able to exercise the API at this time so I'm not gonna be demonstrating that in this video like we can see that we are up and running and I came up in the console mode interactively here and to shut it down I just do control C and that will terminate the JVM it goes away if I do a Docker PS you can see that now I have just Postgres running and if I went to a second command line while that was running the Docker PS would have shown that image up and running