Skip to content
Latchkey

Elastic Beanstalk "eb deploy" environment is not Ready in CI

Elastic Beanstalk only accepts a deploy when the environment status is Ready. The environment was still Updating or Launching from a previous operation, so the CLI refuses the new deploy.

What this error means

eb deploy aborts with "ERROR: Environment <name> is not in the Ready state. Cannot apply the update." or "is not Ready" without starting the deployment.

eb
ERROR: Environment named myapp-prod is not in the Ready state.
Cannot apply the update. The environment is currently in the Updating state.

Common causes

A concurrent or unfinished prior deploy

An earlier deploy, scaling event, or config change is still in progress, so the environment is Updating and rejects a second operation.

The environment is stuck recovering

A failed prior deploy left the environment mid-update; it must reach Ready (or be aborted) before another deploy is allowed.

How to fix it

Wait for Ready before deploying

  1. Poll the environment status until it returns Ready.
  2. Serialize deploys so only one runs against an environment at a time.
  3. Then re-run eb deploy.
Terminal
aws elasticbeanstalk wait environment-updated \
  --environment-name myapp-prod

Abort a stuck update

If the environment is wedged in Updating, abort the current operation, let it return to Ready, then deploy.

Terminal
aws elasticbeanstalk abort-environment-update \
  --environment-name myapp-prod

How to prevent it

  • Gate deploys so only one runs per environment concurrently.
  • Wait on environment-updated between operations in CI.
  • Avoid overlapping config changes and code deploys.

Frequently asked questions

What causes ""Environment ... is not Ready""?
An earlier deploy, scaling event, or config change is still in progress, so the environment is Updating and rejects a second operation.
How do I fix "Environment ... is not Ready"?
Wait for Ready before deploying

Related guides

References

Latchkey auto-heals failures like this one - detected, fixed, and retried without you. Start free → 30-day trial · No credit card