CI/CD on AWS extremely slow

0

Hi,

So I've configured CodePipeline: connection to GitHub, CodeBuild (builds a Docker image and pushes it to ECR), and deployment using Amazon ECS on a Fargate cluster via service with task number = 1, minimum healthy=50%, maximum healthy=140%.

It takes astonishing 8 minutes(!) to build and push a simple container, also from the logs it is obvious the Docker layer cache is not used. And then the deployment stage takes ~10 minutes.

This is unreal. Is it supposed to be that slow? Are there any ways to make it faster?

Thank you.

1 réponse
0

Hi!

it is obvious the Docker layer cache is not used

Why not? can you share the Buildspec file?

Please read the article bellow and take a look at the usage of cache-from during docker build.

The basic idea is pull the previous image from ECR and use it as cache from the current build with the cache-from parameter.

https://aws.amazon.com/blogs/devops/reducing-docker-image-build-time-on-aws-codebuild-using-an-external-cache/

répondu il y a 2 ans

Vous n'êtes pas connecté. Se connecter pour publier une réponse.

Une bonne réponse répond clairement à la question, contient des commentaires constructifs et encourage le développement professionnel de la personne qui pose la question.

Instructions pour répondre aux questions