WEBVTT

00:00.900 --> 00:01.733
-: In the last section,

00:01.733 --> 00:04.140
we made a little change to our Docker run file

00:04.140 --> 00:06.210
and redeployed the application.

00:06.210 --> 00:07.890
I've now sat through the redeployment,

00:07.890 --> 00:10.110
and it looks like everything went through successfully,

00:10.110 --> 00:12.450
and the application should now be working.

00:12.450 --> 00:15.060
Now if you do not see health of OK right here,

00:15.060 --> 00:17.280
or if you see any other errors appearing

00:17.280 --> 00:18.480
in the log down there,

00:18.480 --> 00:21.000
one quick tip that I'll give you for debugging here,

00:21.000 --> 00:22.770
and this is where I recommend you first go to

00:22.770 --> 00:25.200
to figure out exactly what went wrong.

00:25.200 --> 00:28.380
You can click over on the logs tab on the left hand side,

00:28.380 --> 00:29.970
and then on the far right hand side,

00:29.970 --> 00:31.530
click on request logs,

00:31.530 --> 00:34.380
and then last 100 lines.

00:34.380 --> 00:36.840
This will give you the last 100 lines of output

00:36.840 --> 00:38.370
from each of your containers,

00:38.370 --> 00:40.110
along with a couple other services

00:40.110 --> 00:42.270
that are used to host your application.

00:42.270 --> 00:43.890
So you can then look at the log file

00:43.890 --> 00:45.690
by clicking on that download link,

00:45.690 --> 00:50.190
and you'll get a very large, rather consolidated log file.

00:50.190 --> 00:53.250
So this has logs from a bunch of different services,

00:53.250 --> 00:55.920
and they're all placed in these different sections.

00:55.920 --> 00:57.870
So this is one section of logs,

00:57.870 --> 01:02.070
and it contains all the logs from a ECS-init log file.

01:02.070 --> 01:04.200
Remember that when we use Elastic Beanstalk

01:04.200 --> 01:05.730
with a multi container setup,

01:05.730 --> 01:07.050
behind the scenes it's actually using

01:07.050 --> 01:10.290
that ECS, or Elastic Container Service application,

01:10.290 --> 01:12.720
that we had mentioned a little bit ago.

01:12.720 --> 01:16.020
You'll also see some PHP app logs inside of here.

01:16.020 --> 01:17.370
Those are logs that are generated

01:17.370 --> 01:20.490
by the default Elastic Beanstalk application

01:20.490 --> 01:23.550
that was created when we first made our environment.

01:23.550 --> 01:25.590
And then if you go through here, you'll eventually start

01:25.590 --> 01:28.710
to see some logs from say, here we go,

01:28.710 --> 01:31.860
so our container logs from the client container.

01:31.860 --> 01:34.143
Here's from the Nginx container,

01:34.143 --> 01:36.690
here is from a Nginx proxy, which is being used

01:36.690 --> 01:39.930
to route information around our application,

01:39.930 --> 01:42.810
and here's the server logs right here as well.

01:42.810 --> 01:45.030
So again, if you have an error being displayed

01:45.030 --> 01:47.910
on the dashboard back on Elastic Beanstalk,

01:47.910 --> 01:50.640
I encourage you to take a glance at these logs.

01:50.640 --> 01:52.290
Read through them somewhat deeply.

01:52.290 --> 01:54.750
Somewhere inside of here will be a message

01:54.750 --> 01:57.183
telling you exactly what went wrong.

01:58.140 --> 02:00.510
All right, so with that in mind,

02:00.510 --> 02:02.430
if the deployment went successfully,

02:02.430 --> 02:04.530
you can go back over to Elastic Beanstalk

02:04.530 --> 02:08.220
and find the URL to the application up here at the very top.

02:08.220 --> 02:09.480
So you can click on that link,

02:09.480 --> 02:11.910
and it will open up our application.

02:11.910 --> 02:15.660
And so my app is hosted at multi docker slash, excuse me,

02:15.660 --> 02:18.720
multi docker dash n, and then some string,

02:18.720 --> 02:21.570
blah, blah, blah, elasticbeanstalk.com.

02:21.570 --> 02:24.450
I can now enter in some index of a value to calculate

02:24.450 --> 02:26.010
and then click on submit.

02:26.010 --> 02:29.103
And if I refresh the page, I'll see that index up here.

02:29.970 --> 02:31.350
Cool, so that's pretty much it.

02:31.350 --> 02:33.030
We can refresh as much as we want.

02:33.030 --> 02:35.250
We can add in some value,

02:35.250 --> 02:38.070
and it'll just calculate the Fibonacci value

02:38.070 --> 02:39.780
for any given number.

02:39.780 --> 02:41.220
So that's pretty much it.

02:41.220 --> 02:43.200
I hope you've enjoyed this application,

02:43.200 --> 02:44.730
at least the deployment part.

02:44.730 --> 02:46.950
The last thing I wanna show you is in the next section.

02:46.950 --> 02:48.330
I just wanted to go through the process

02:48.330 --> 02:49.920
of redeploying the app

02:49.920 --> 02:52.410
and making sure that we can get some updates

02:52.410 --> 02:53.310
to appear on the screen.

02:53.310 --> 02:56.133
So one last section, and I'll see you in just a minute.
