1
00:00:00,710 --> 00:00:06,410
In the last section we started talking about deployment objects remember a deployment is going to run

2
00:00:06,440 --> 00:00:11,120
and manage a set of identical pots from this point forward throughout this course.

3
00:00:11,150 --> 00:00:14,300
We are no longer going to create pods ourselves manually.

4
00:00:14,360 --> 00:00:18,560
Instead we're going to create deployments that will create pods for us.

5
00:00:18,650 --> 00:00:23,100
So deployments are appropriate for use in both a development and production environment.

6
00:00:23,600 --> 00:00:29,240
We're going to make a deployment that has a pod template that's going to try to create a container using

7
00:00:29,240 --> 00:00:34,040
the image multi client and we're going to make sure that port 3000 is exposed.

8
00:00:34,040 --> 00:00:38,120
Now the reason we're going to make it deployment with multi client and port three thousand open is so

9
00:00:38,120 --> 00:00:40,210
that we can test this out in the browser.

10
00:00:40,220 --> 00:00:42,760
Once a deployment creates our actual pod.

11
00:00:43,250 --> 00:00:48,710
So to make it deployment we're going to use the same process that we use for every other object that

12
00:00:48,710 --> 00:00:50,720
we're ever going to create with Kuber Nettie's.

13
00:00:50,720 --> 00:00:57,020
We're going to make a configuration file and then feed that configuration file into Kube CTO.

14
00:00:57,050 --> 00:01:03,290
So inside of my code editor I'm going to create a new configuration file inside of my project directory

15
00:01:03,800 --> 00:01:08,080
and I'll give this file a name of client Dasch deployment.

16
00:01:08,240 --> 00:01:08,720
YAML

17
00:01:11,690 --> 00:01:16,010
and then inside this file We're going to add all of our configuration to describe this new deployment

18
00:01:16,010 --> 00:01:17,400
that we're making.

19
00:01:17,570 --> 00:01:21,770
We're going to write out all the configuration together right now and we'll talk about the purpose of

20
00:01:21,800 --> 00:01:24,490
every line immediately after that.

21
00:01:24,560 --> 00:01:34,700
So I'll get started by writing out API version and I'll say apps slash V-1 I'll specify kind of deployment.

22
00:01:34,700 --> 00:01:37,310
So these two lines right here I bet you can guess what's going on.

23
00:01:37,340 --> 00:01:44,050
We are saying that we want to use a object that is defined inside the API version of app slash V-1 and

24
00:01:44,060 --> 00:01:48,080
the specific type of object that we want to create is a deployment.

25
00:01:48,080 --> 00:01:55,260
Next up we'll put down our metadata section and we'll give the thing a name of client Dasch deployment

26
00:01:56,900 --> 00:02:05,950
then we'll do our spec after that or the spec will say replicas is one allowed on a selector with matched

27
00:02:05,950 --> 00:02:13,250
labels and a component Web property like so Eildon on intent.

28
00:02:13,250 --> 00:02:15,680
So I now only have one indent right here.

29
00:02:15,890 --> 00:02:22,640
I'll say template I'll put in meta data labels.

30
00:02:24,760 --> 00:02:27,090
Component web.

31
00:02:27,200 --> 00:02:33,480
I'm going to indent again so that I'm on the same indentation layer as metadata.

32
00:02:33,580 --> 00:02:41,280
I'll say spech containers and will define the list of containers that we want created with every pod

33
00:02:41,370 --> 00:02:43,530
that is controlled by this deployment.

34
00:02:43,530 --> 00:02:49,530
So this is a array entry I'll put in my little dash like so and I'll say that I want a pod that has

35
00:02:49,530 --> 00:02:52,600
a name or a container in this pod with the name of client.

36
00:02:52,920 --> 00:03:00,390
I want it to run the image of my doc or ID slash multi client and then finally we'll set up that port

37
00:03:00,390 --> 00:03:00,880
mapping.

38
00:03:00,900 --> 00:03:08,630
So I'll say ports with a container port of 3000 like the OK.

39
00:03:08,650 --> 00:03:11,570
So something's inside this file might look a little bit familiar.

40
00:03:11,570 --> 00:03:12,500
Let's take a quick pause.

41
00:03:12,500 --> 00:03:16,290
We're going to come back the next section and start breaking this thing down line by line.

42
00:03:16,420 --> 00:03:17,740
So I'll see you in just a minute.
