AWS Tutorial - AWS CodePipeline Step by Step Tutorial

preview_player
Показать описание
In this video, you will learn
What is AWS Code Pipeline?
How to Create a Pipeline?
How to use pipeline and auto-update the website hosted in S3 Bucket from Git hub?
AWS CodePipeline is a fully managed continuous delivery service that helps you automate your release pipelines for fast and reliable application and infrastructure updates. CodePipeline automates the build, test, and deploy phases of your release process every time there is a code change, based on the release model you define. This enables you to rapidly and reliably deliver features and updates. You can easily integrate AWS CodePipeline with third-party services such as GitHub or with your custom plugin.

The source of the site is on my desktop. Now let me show static site files that we have uploaded in s3 bucket in the cloud. Log in to AWS, I have AWS educate account.

Open the AWS console page
Navigate to s3 and open it
In the bucket you can see 2 buckets which we have created in the last tutorial session.
All the files of the site are uploaded in the first one bucket.
Here are all the static files list

Now let's move to learn code pipeline

Navigate to AWS console page
search code pipeline
To use the pipeline, we need to create it. So click on create pipeline button.

Enter the pipeline name

New service role ok

Role Name will auto-generated

Now click next

Now we need to define the source here.

You can see different sources. We are going to use GitHub for now. Select GitHub

Now, we need to connect to Github to grant AWS code pipeline access to your GitHub repository.

Click Connect GitHub
I'm already login into my git hub account here. Now, Need to authorize AWS code suite

All repository are autoloaded here. Select the Repository

Similarly, Select the Branch

Click Next

Build Optional, for now, skip it

Skip

Another step is to add deploy stage

In Deploy provider, Choose amazon s3

In region
Same as we created the bucket.

Choose the bucket
In our case its first one where our site is running.

Checked extract file before deploy

Click next

Here you can all review the details

Click create pipeline

Great, successfully created pipeline.

Now let’s test it.

I have already added all the files and folders in the git hub.

Let’s confirm if anything changes in the code.

Open terminals
Navigate to the source folder. I have it on my desktop.
Ok here are all the files and folders.

Let’s check the status git status
Ok Nothing updated.

Now let’s change this text master2teach step by step guide to
Welcomes to master2teach

Change the text to welcomes to master2teach

Now Let’s push into git.

Git status
Changes in the index file

Git commit –m “changing to welcomes”
Git push origin master

Now let’s confirm the changes in the git.
Refresh the page

Here are the changes. Ok

Now let’s check on the site.

This text must auto change coz we have made pipeline to our s3 bucket with GitHub,

Here its changes.

Great pipeline works successfully.

Let’s try once more. Changing text again.

From the terminal, let’s add commit and push the changes to git.

Now let’s see the auto changes in the site.
Refresh hum taking the time.
Refresh
Refresh

Here it comes.

The site is auto-updating from git hub.

In this way we can use the code pipeline feature of AWS to auto-update the files and folder in the cloud.

Host Static site in AWS

Рекомендации по теме
Комментарии
Автор

thank you this video was very helpful to understand the overall pipeline usage :)

HeizelGonzalez
Автор

May I know why my deploy stage is failing ?

bhagyashreepatil
join shbcf.ru