Search code examples
deploymentamazon-elastic-beanstalk

Elastic Beanstalk Deploy - Slow Zip


I've been using AWS Elastic Beanstalk for about 2 years now. In the past, eb deploy has taken more time as the project grew, but never more than 5-10 minutes.

With my latest project, I am using NextJS 13.0.3. When I use eb deploy --verbose, the archive creation with system zip takes 30+ minutes.

My question is: is there a reason why the ZIP is so slow? I understand the archive upload to S3 is time-heavy, but when I zip the files with the zip command or through the Mac Finder, it only takes 1 minute at most.

I am not including node_modules or any large images in the eb deploy.

Here are the first few lines of eb deploy ---verbose if it helps. Thanks in advance.

INFO: Deploying code to [ebs environment] in region us-east-2
INFO: Getting version label from git with git-describe
Creating application version archive "app-26c2-230321_101028812043".
INFO: Found .ebignore, using system zip.
INFO: Zipping up folder at location: [folder location]
INFO:  +adding: .//

Solution

  • Update: This has now been fixed in the latest version (3.20.6) eb --version

    You can update using pip install awsebcli --upgrade --user