WEBVTT
Kind: captions
Language: en

00:00:00.030 --> 00:00:08.280
In this video we're going to add a SSH
key pair to AWS the reason we do this is

00:00:08.280 --> 00:00:14.840
so that when we create our server we can
connect to it using ssh authentication

00:00:14.840 --> 00:00:19.350
this is the same method of
authentication that we use to connect to

00:00:19.350 --> 00:00:24.930
github if you remember way back in the
previous videos we created an SSH key

00:00:24.930 --> 00:00:30.380
pair which we added on our local system
and then put the public key pair on

00:00:30.380 --> 00:00:35.910
github we're going to do the same thing
here except we're going to be creating or

00:00:35.910 --> 00:00:42.649
adding the public key pair to AWS
instead of github so let's get started

00:00:42.649 --> 00:00:49.200
we're going to start by outputting the
content of our SSH key pair public file

00:00:49.200 --> 00:00:55.590
so open up the git bash or the terminal
window and we want to get a terminal

00:00:55.590 --> 00:01:01.079
window on our local machine not on the
vagrant server it's very important that

00:01:01.079 --> 00:01:03.780
it's running on our local machine
otherwise you won't be able to access

00:01:03.780 --> 00:01:09.040
the SSH key we need to set up the
authorization

00:01:09.040 --> 00:01:10.380
okay so we're going to output

00:01:10.380 --> 00:01:23.300
it by typing cat then tilde forward slash dot SSH forward slash ID underscore RSA dot pub

00:01:23.300 --> 00:01:24.479
it's very important

00:01:24.479 --> 00:01:29.250
that you add the pub for public because
we want to output the public file for

00:01:29.250 --> 00:01:34.860
our key so hit enter there and then we
can copy the contents right from the

00:01:34.860 --> 00:01:41.700
beginning ssh RSA all the way to the end
where the comment ends let's right-click

00:01:41.700 --> 00:01:48.180
that and copy and then open up the
Google Chrome browser and we want to

00:01:48.180 --> 00:01:54.810
make sure that we are logged in to our
AWS console now AWS modify their

00:01:54.810 --> 00:01:59.700
products all the time so your console
may not look exactly like mine but

00:01:59.700 --> 00:02:04.439
fundamentally you should have the AWS
and the services option here so we're

00:02:04.439 --> 00:02:08.980
going to click on services we're going
to head over to EC2

00:02:08.980 --> 00:02:10.979
EC2 is where the

00:02:10.979 --> 00:02:17.370
key pairs can be added for use on
our server instances so on the left-hand

00:02:17.370 --> 00:02:23.790
side here let's scroll down and find the
bit that says key pairs here underneath

00:02:23.790 --> 00:02:30.720
network and security click on key pairs
to open up the key pair page what we're

00:02:30.720 --> 00:02:35.040
going to do is we're going to import a key
pair because we already have a key pair

00:02:35.040 --> 00:02:39.210
created that is our private key and our
public key and we're just going to click

00:02:39.210 --> 00:02:45.750
import here and we'll give it the name I'm
going to call it mark - desktop I recommend

00:02:45.750 --> 00:02:50.459
you give it a name that matches the
laptop or computer that you are

00:02:50.459 --> 00:02:56.670
authenticating then under the public key
contents box we're going to paste the

00:02:56.670 --> 00:03:01.140
contents of our public key let's just
make sure that the contents are fully

00:03:01.140 --> 00:03:06.700
pasted here ssh RSA and it should end in
the comment

00:03:06.700 --> 00:03:08.250
ok then all we need to do is

00:03:08.250 --> 00:03:14.930
hit import and this will import our
public key into AWS

