1 00:00:02,120 --> 00:00:02,420 ‫All right. 2 00:00:02,420 --> 00:00:03,080 ‫So first up. 3 00:00:03,080 --> 00:00:08,780 ‫Is there a way to build and run containers from get Mono repo. 4 00:00:08,780 --> 00:00:15,580 ‫I mean multiple containers I am writing multiple services and go in and do that in a mongo mono repo. 5 00:00:15,710 --> 00:00:18,680 ‫And now it's time to incorporate some automation. 6 00:00:19,070 --> 00:00:20,170 ‫Yeah absolutely. 7 00:00:20,210 --> 00:00:23,660 ‫And I think that you have other people there also answering your questions Alexandra. 8 00:00:25,140 --> 00:00:26,330 ‫Yes definitely. 9 00:00:26,330 --> 00:00:27,250 ‫You can do that. 10 00:00:27,410 --> 00:00:33,620 ‫You basically could just clone a repo down move to the directory where you want that Docker file and 11 00:00:33,620 --> 00:00:39,620 ‫then do a docker build your Docker files don't have to be called Docker file the default name that Docker 12 00:00:39,620 --> 00:00:44,210 ‫will use when you do a docker build is looking for a file called Docker file. 13 00:00:44,210 --> 00:00:50,500 ‫But you can call it you know container file you can tell it whatever you want container build. 14 00:00:50,520 --> 00:00:52,520 ‫You know you can make your own standard. 15 00:00:52,530 --> 00:00:57,960 ‫And then when you do a docker build you're going to specify a dash F to find the file that you wanted 16 00:00:57,990 --> 00:00:58,710 ‫to call. 17 00:00:58,710 --> 00:01:02,750 ‫This is also true of Docker compose if Docker compose has a default file name. 18 00:01:02,910 --> 00:01:06,190 ‫But you can always use dash F to specify whatever file you want. 19 00:01:06,480 --> 00:01:12,570 ‫And with Docker files remember the thing about Docker files is the con the the directory that you're 20 00:01:12,570 --> 00:01:18,430 ‫in for the context which is that last little thing that you do in a doc or build command. 21 00:01:18,480 --> 00:01:22,800 ‫For instance if you do a c it's just zoom in 22 00:01:25,750 --> 00:01:30,330 ‫if you do a docker build and look at the help 23 00:01:33,440 --> 00:01:36,350 ‫the last little thing there is the path. 24 00:01:36,380 --> 00:01:43,700 ‫So ideally you whatever the path is or the context for where you're building it that's where the docker 25 00:01:43,700 --> 00:01:45,620 ‫file will start doing its work from. 26 00:01:45,620 --> 00:01:51,890 ‫And so sometimes I get a question where people say I want to include files in my Docker image that are 27 00:01:51,950 --> 00:01:56,900 ‫in a completely different path like up my directory chain and that's not something that Docker Build 28 00:01:56,900 --> 00:02:03,260 ‫does because when you specify that path or location for where you're going to start building Docker 29 00:02:03,260 --> 00:02:08,450 ‫will you see if you see at the beginning of a docker build it will take all the files in that directory 30 00:02:08,450 --> 00:02:14,450 ‫and all sub directories and put them into a tar ball and then push them to the doctor engine wherever 31 00:02:14,450 --> 00:02:17,990 ‫that is if that might be your local machine that might be a server that's remote. 32 00:02:17,990 --> 00:02:23,030 ‫And so if there's a file you're trying to copy in from somewhere else it's never going to get that file. 33 00:02:23,030 --> 00:02:27,470 ‫So make sure that when you're doing this that you're always building that context from the directory 34 00:02:27,920 --> 00:02:31,890 ‫you want like if you're go apps or in their own sub directories that's fine. 35 00:02:31,910 --> 00:02:38,090 ‫Just do a docker build specify the file name and it specify that directory as the build path at the 36 00:02:38,090 --> 00:02:39,890 ‫end there and you'll be good. 37 00:02:39,920 --> 00:02:40,510 ‫Good question.