In this video, we are going to deploying our SDK application.
So as you remember that we have a lifecycle, we write our constructs, which is the case construct
under the halo seed case stake.
And now we will use the seed case here like with synthesizing to cloud formation template.
And after that using the seed deploy command will be deployed or add resources to the target environment
are using a cloud formation.
So let's follow these steps into our application.
Open the widget studio.
Now we have one is one Q service into our Halo seed case.
So let me open a new terminal.
And I will start with the running cdcc scene command.
He entered.
So you know that CDK command will be generate or need.
Our new template quote of the edible cloud formation.
Yes, it is returning to response.
And as you can see that under the resource section we have seen the Halo Q record and type is a ESC
SKU.
You can see properties are set in correctly.
C Other properties comes from the default level two definition of the CDCC.
Okay.
Very good.
It is going to create cloud formation template which resource existing or add with the properties of
visible to time out.
And there are lots of other properties you can see in here which we don't define.
Those are comes from the default settings, from the level to construct definition by default that will
apply the CDCC team.
So CDK power comes from here.
If you look at the code you have seen very summarised with it and it breakdowns with to all properties
one extracting to cloud formation template.
So if you look at our code, our code is only one line or line of code but one synthesizing this code,
this becomes is lots of configuration.
Even we don't specify it.
It comes from the default settings and also it is mandatory maybe from the cloud formation template
and you don't bother these all these details and configurations into our CDK application.
So this is one of the powerful features of the CDK and we saw basically the CD case in command executes
your application, which causes the resource defined in it to be translated to the a cloud formation
template.
So we have translate to our CDK application to the cloud formation template.
The template also saved into CDK out folder that you can see in here.
Under this folder you can see extracted JSON format template.
Please click this JSON format and see that we have a resource section, we have a Cdcc Q section and
we are going to create A the Q and properties is here.
There's lots of additional properties and so on.
This is the template file that we are going to deploy with cloud formation.
Okay, very good.
We understand how CDK synthesized work.
Also, we can run Cdcc div command in order to see differences with the actual stack and our code base.
This is compared with our cloud infrastructure and existing code.
So let me run cdk it to enter.
Since we are attempting the first deployment deploy command, we see lots of changes, but it's enough
to see resource section.
If you come to resource differences, you can see that we are going to add one extra SKU which is the
Halo seed queue and it is generated with this name.
Okay.
Very good.
It is optional to synthesize and command before deploying.
You don't need to run.
I'm running this in order to see and show to you the CDK synthesizes your stack before each deployment.
If your code has security implications, you will see the summary of these and need to confirm them
before deployment process.
So it is good practice is to run the cdcc synthesize and dev command to see some security or any problems.
So now we are going to deploying our stakes in order to deploy the stack using the cloud formation.
We are running the Cdcc deploy command, so I'm going to run Cdcc deploy command.
Write the Cdcc deploy and hit enter.
It is going to deploy our infrastructure to the cloud.
So it takes sometimes and we will see the progress with the logs.
So as you can see that it is deploying to Helo CDK sticks, which is indicating under the lib folder
in our class and we basically create a new stake into the cloud formation and deploy the A list Esquire's
Q into this stack with using the cloud formation.
It take some time and we will wait for a while.
Cdcc deploys displays the progress information.
Your deployment is very good for very good to see the progress of the how we can create cloud formation.
As you can see that first of all, it's creating a new stick, which is the halo, stick, halo, stick,
stick.
And after that it is going to create Amazon.
Q Which name is Halo CD?
Q and continue to their operations?
This is the store to create in-progress and create complete for the metadata and it will be create it
for the CDK and the Q you can see the currently in progress CDK stick and CDK Q.
So this is the looks.
This is going to create Amazon skew into our halo seed case tech.
And at the end of these looks, we will see the erosion of our cloud formation.
Cloud formations, tech definition.
We will see and check the management console.
Okay, it is finished.
As you can see, that Halo seed case tech deployed successfully and you can see the stack Aaron in here.
This is going to create this stack, which name is Halo CDK stacked and create a squeeze into this stack.
So let's go and verify this.
I'm going to open.
A console if you come to the cloud formation.
You can go to the cloud formation on the main console and see that.
It is now neve neve stake in here, which is the halo seed stake.
This is directly representing our Visual Studio project, which is the seed application.
You you will also find the Halo Seed K Q into this tech.
Let me click this stake and come to resources.
You will see that we have Halo Seed K.
Q and this number CDK is defined for our application.