Skip to content
This repository was archived by the owner on Mar 23, 2026. It is now read-only.
This repository was archived by the owner on Mar 23, 2026. It is now read-only.

Healthcheck when running in docker #1095

Description

@use-strict

I'm running localstack with docker-compose as a dependency for a service that I'm developing. The problem is that my service calls localstack before it's fully initialized. The only solution I could find so far is a hard sleep <seconds> at start-up, but that only works on my specific system and produces unexpected results for other developers. Can localstack expose a healthcheck, so I can have docker-compose start my service after localstack is "healthy"?

A trimmed down version of my docker-compose.yml looks something like this:

myservice:
  command: "sh -c 'sleep 10 && npm run start'" #grrrrr
  depends_on:
    - aws
    # aws:
    #   condition: service_healthy
aws:
  image: localstack/localstack
  environment:
    SERVICES: s3:81,sqs:82,ses:83
    HOSTNAME_EXTERNAL: aws

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions