From the course: Complete Guide to AWS Software Deployment

Unlock the full course today

Join today to access over 24,400 courses taught by industry experts.

Solution: CodeBuild for Docker ECR pushes

Solution: CodeBuild for Docker ECR pushes

(upbeat instrumental music) - [Instructor] All right, if you said CodeBuild you're absolutely right. We can automate the entire sequence of steps from git push to Docker build to ECR push using CodeBuild and CodePipeline. And automation is not the only reason to do this. I actually found another good reason, and that is controlling the build environment. I recently started using a Mac with an ARM chip rather than an Intel chip, and by default Docker builds images compatible with the local architecture. So, my ARM-built images weren't working on the Intel-based ECS Fargate. So, one great solution was to get the image building not on my computer but on CodeBuild, so let's see how to do it. We're going to start in the IAM section, so let's head to that service. And we're going to create a new role, so click Roles and Create role. Keep AWS service selected and go down and choose use case, and this will be CodeBuild. Click that option, scroll down and click Next. Okay, so the permission…

Contents