CI/CD With AWS ECS + CodePipeline + CodeDeploy + CodeCommit + CodeBuild + Docker

แชร์
ฝัง
  • เผยแพร่เมื่อ 23 ก.ย. 2024
  • DevOps: CI/CD With AWS ECS & AWS Codepipeline
    👨‍💻 ➡️ Pushing codes➡️ GitHub or AWS CodeCommit ➡️ AWS CodePipeline ➡️ AWS CodeBuild ➡️ AWS ECR ➡️ Deploy To AWS ECS
    ▬▬▬▬▬▬ This Video will teach you about: ▬▬▬▬▬▬
    Step 1: Docker basic
    Step 2: AWS ECR Creation
    Step 3: Create ALB
    Step 4: Create an AWS ECS Cluster
    Step 5: AWS Code commit
    Step 6: AWS Code Build
    Step 7: AWS Code Pipeline
    Step 8: Error & resolution
    Step 9: Modify Input Artifacts Settings for Stage
    Step 10: Final Deployment Test and Validation
    Medium: / microservices-ecs-aws-...
    #CodePipeline #CodeBuild #Codecommit #CodeDeploy #ECS #Docker

ความคิดเห็น • 59

  • @AyushChauhan-q9w
    @AyushChauhan-q9w ปีที่แล้ว

    Great guidance

    • @CloudGurus
      @CloudGurus  ปีที่แล้ว

      Thanks for the feedback.

  • @YTvongoladecimo
    @YTvongoladecimo 2 ปีที่แล้ว +1

    Thank you so much, My first time to do CI/CD on AWS and It works.

    • @CloudGurus
      @CloudGurus  2 ปีที่แล้ว

      Thanks for the feedback.

  • @bommakutty
    @bommakutty ปีที่แล้ว

    Thank you so much for your video. Finally, I found a best video for CI/CD pipeline. Can you please share CI/CD pipeline for Devsecops and how the security scan and tools been integrated in the pipe line. I am looking forward to watching your videos. Please continue to teach us.

    • @CloudGurus
      @CloudGurus  ปีที่แล้ว

      Thanks for the feedback.

  • @tushardudhatra3478
    @tushardudhatra3478 ปีที่แล้ว

    Thank you for this video. Disclaimer: On 11th June 2023 I watched this video and I had to make some changes in the commands and had to do some things differently than explained in the video but that is completely acceptable. In-fact I am not going to mention what are the changes because as a developer everyone should be able to figure out such changes by themselves.

    • @CloudGurus
      @CloudGurus  ปีที่แล้ว

      Thanks for the feedback.

  • @souvagya00
    @souvagya00 10 หลายเดือนก่อน

    Very informative. Thank you so much .

    • @CloudGurus
      @CloudGurus  10 หลายเดือนก่อน

      Glad it was helpful!

  • @vijayendralolla
    @vijayendralolla ปีที่แล้ว

    This is Excellent !! Great efforts

  • @chandrachalla6081
    @chandrachalla6081 2 ปีที่แล้ว +1

    Excellent Stuff.

  • @arsepiperv2
    @arsepiperv2 ปีที่แล้ว

    Nice vid, really nice. Only one thing that wasn't covered for me. The purpose of the S3 bucket, if we're not outputting a specific artifact? Thanks

    • @CloudGurus
      @CloudGurus  ปีที่แล้ว

      Thanks for the feedback.

  • @chris0628
    @chris0628 2 ปีที่แล้ว +1

    You don’t need to create a new version of the task and container to deploy the changes. Since you have setup a service which is executing the task with the container pointing to the latest version of the build, all you need to do is stop the running task within the service and the service will automatically deploy a new task and it will be using the latest build.

    • @CloudGurus
      @CloudGurus  2 ปีที่แล้ว

      Yes correct.

    • @japarjarkynbyek8494
      @japarjarkynbyek8494 2 ปีที่แล้ว +1

      Creating the new version of the task can be runs your service continuously, without stop.

    • @itcloudguy
      @itcloudguy ปีที่แล้ว +1

      Initially, it already seems doubtful that just to update the application, you have to create a new set of tasks. Thank you for noticing the mistake and commenting here. The author of the video did not even pay attention to this moment. 👍

  • @dhanwanprajapati83
    @dhanwanprajapati83 ปีที่แล้ว

    awesome work. one question if i want a context based routing on ECS service on alb. how can i archive this
    Example:-
    ecs_service_1 -> ecs_alb/page1
    ecs_service_2 -> ecs_alb/page2

    • @CloudGurus
      @CloudGurus  ปีที่แล้ว

      Will check and get back to you on this.

  • @lequocduan
    @lequocduan 2 ปีที่แล้ว

    Hi, thank you for your presentation, but I don't see where your CodeDeploy steps inject to? And I have a question: when I have been working with CodePipelines to deploy my services to ECS Fargate failed, the new Task Definition actually be generated, and the failures ECS task always start the new one, how to stop the failed task? (I'm using the manually steps: remove ALB target groups + force stop the codepipelines deploy step).
    Pls share us if you are free! thank a lot.

    • @CloudGurus
      @CloudGurus  2 ปีที่แล้ว +1

      Thanks for the feedback. Will check and let you know.

  • @latchus-l5f
    @latchus-l5f ปีที่แล้ว

    I'm facing issue with "exec /usr/sbin/httpd: exec format error" when i updated image in new revision and a service. Then new instances provisioning and immediately de-provisioning. The log seems "exec /usr/sbin/httpd: exec format error". Any advice on this?

    • @CloudGurus
      @CloudGurus  ปีที่แล้ว +1

      Refer these links: stackoverflow.com/questions/73285601/docker-exec-usr-bin-sh-exec-format-error
      beebom.com/how-fix-exec-user-process-caused-exec-format-error-linux/

    • @latchus-l5f
      @latchus-l5f ปีที่แล้ว

      @@CloudGurus Thanks much, I will check and update here

  • @nitink8148
    @nitink8148 3 ปีที่แล้ว

    Best video on CI CD on codepipeline! Covers almost all aspects.

    • @CloudGurus
      @CloudGurus  3 ปีที่แล้ว

      Glad you think so!

  • @syedkausarali2846
    @syedkausarali2846 2 ปีที่แล้ว

    Can we deploy only if a tag is pushed to repo like if we push v1.0.1 then we deploy.
    Have not watched this video yet but just wanted to ask. I am gonna watch this soon insha Allah

  • @undefined6596
    @undefined6596 2 ปีที่แล้ว +1

    such a nice video!!!!!
    thanks so much!!!

    • @CloudGurus
      @CloudGurus  2 ปีที่แล้ว

      Glad you liked it!

  • @josemanuelgutierrez4095
    @josemanuelgutierrez4095 2 ปีที่แล้ว

    pls help me when I tried to clone my repo using ssh this opcion in Codecommit is not enable maybe that's the problem because when i need to clone this message appear ... Please make sure you have the correct access rights
    and the repository exists. ...... can you help me with that pls ... I'd like to present this example at my univsty

    • @CloudGurus
      @CloudGurus  2 ปีที่แล้ว

      Check your permissions, ac;ls, amd roles in all the services used in AWS.

  • @ArunKumar-ru6bl
    @ArunKumar-ru6bl 2 ปีที่แล้ว

    Sir the commands i should use to run on ubuntu can you please share those because i dont know which type of linux you are using

    • @CloudGurus
      @CloudGurus  2 ปีที่แล้ว

      Sure. Will add that in the description.

    • @ArunKumar-ru6bl
      @ArunKumar-ru6bl 2 ปีที่แล้ว

      @@CloudGurus sir if you dont mind please add as soon as possible because its important to me

  • @ashishbhatt5250
    @ashishbhatt5250 ปีที่แล้ว

    Hi, I need help to create ECS cluster, can you please help

  • @jaisrikrishna9525
    @jaisrikrishna9525 2 ปีที่แล้ว

    hi sir how you have created docker image. in video you have specified that it docker image created in 16 months ago. please reply me. thank you in advance

    • @CloudGurus
      @CloudGurus  2 ปีที่แล้ว

      Refer this link: www.sentinelone.com/blog/create-docker-image/

  • @jivanmainali1742
    @jivanmainali1742 2 ปีที่แล้ว

    Hi sir do autoscaling at service level works if we have only one ec2 instance at cluster definition ?

    • @CloudGurus
      @CloudGurus  2 ปีที่แล้ว

      Yes it does

    • @jivanmainali1742
      @jivanmainali1742 2 ปีที่แล้ว

      @@CloudGurus but i thing if our container running at some port then autoscaling assigns 2 container running in same port to 1 ec2 which will raise exceptions

  • @thawzinmyo8114
    @thawzinmyo8114 ปีที่แล้ว

    "COMMAND_EXECUTION_ERROR: Error while executing command: aws ecr-public get-login-password --region us-east-1 | docker login --username AWS --password-stdin my public repository. Reason: exit status 1". When I build, I faced this issue in pre-build phase. Please let me know what I missing. I use public repo in codecommit.

    • @CloudGurus
      @CloudGurus  ปีที่แล้ว

      Refer these links: docs.aws.amazon.com/cli/latest/reference/ecr/get-login-password.html
      docs.aws.amazon.com/AmazonECR/latest/userguide/common-errors-docker.html
      github.com/aws/aws-cli/issues/4962

  • @dillibabu5617
    @dillibabu5617 2 ปีที่แล้ว

    hi sir what type of local server you have used like git bash or putty please reply me

  • @jivanmainali1742
    @jivanmainali1742 3 ปีที่แล้ว

    sir I could not understand cmd array ["/usr/sbin/httpd","-D","FOREGROUND"]

    • @CloudGurus
      @CloudGurus  3 ปีที่แล้ว

      Refer this link: serverfault.com/questions/614348/confused-about-dforeground-with-apache

  • @ogbeisibor3193
    @ogbeisibor3193 ปีที่แล้ว

    Thanks for the free lesson. When i tried to run httpd on a centos6 contiainer in the virtual machine i got this error.
    YumRepo Error: All mirror URLs are not using ftp, http[s] or file.
    Eg. Invalid release/repo/arch combination/
    removing mirrorlist with no valid mirrors: /var/cache/yum/x86_64/6/base/mirrorlist.txt
    Error: Cannot find a valid baseurl for repo: base.
    kindly assist.

    • @CloudGurus
      @CloudGurus  ปีที่แล้ว

      Refer these links: secure.subwayhost.com/knowledgebase/14/How-to-fix-YumRepo-Error-and-Cannot-find-valid-baseurl.html
      www.codesiri.com/2020/12/centos-6-yum-error-cannot-find-valid.html

    • @ogbeisibor3193
      @ogbeisibor3193 ปีที่แล้ว

      @@CloudGurus thanks so much.
      May I know whey you didn’t run the Apache service directly on the virtual machine?

    • @sampath-sam
      @sampath-sam ปีที่แล้ว

      @@CloudGurus similar error with me as well, followed this article resolved my issue

  • @sampath-sam
    @sampath-sam ปีที่แล้ว

    hi bro ! facing this error again when trying to build dockerfile
    [root@ip-172-31-86-48 docker]# docker build -t webserver .
    Sending build context to Docker daemon 3.072kB
    Step 1/6 : FROM centos:centos6
    ---> 5bf9684f4720
    Step 2/6 : MAINTAINER sampath kumar
    ---> Using cache
    ---> 9b2e15360198
    Step 3/6 : RUN yum -y install httpd
    ---> Running in e778c1113193
    Loaded plugins: fastestmirror, ovl
    Setting up Install Process
    Error: Cannot retrieve repository metadata (repomd.xml) for repository: base. Please verify its path and try again
    YumRepo Error: All mirror URLs are not using ftp, http[s] or file.
    Eg. Invalid release/repo/arch combination/
    removing mirrorlist with no valid mirrors: /var/cache/yum/x86_64/6/base/mirrorlist.txt
    The command '/bin/sh -c yum -y install httpd' returned a non-zero code: 1
    plz help

    • @CloudGurus
      @CloudGurus  ปีที่แล้ว

      Refer these links: unix.stackexchange.com/questions/109585/yum-update-fails-error-cannot-retrieve-repository-metadata-repomd-xml-for-re
      www.host-stage.net/client-area/knowledgebase/159/How-to-Fix-YUM-on-CentOS-6-Error-Cannot-retrieve-repository-metadata--.html
      thelinuxcluster.com/2021/01/13/yumrepo-error-all-mirror-urls-are-not-using-ftp-https-or-file/