elastic / elastic/apm-agent-nodejs

the localstack container occasionally fails to start

Open
#4,582 0 comments 0 reactions 0 assignees View on GitHub
flaky-test
Dominant language
JavaScript
Stars
594
Forks
244
Avg merge
1d 8h
Merged PRs (30d)
16

Description

An occasional flaky test issue is that the localstack container (used for AWS SDK tests) fails to start.

A recent example: https://github.com/elastic/apm-agent-nodejs/actions/runs/14646457344/job/41101781884#step:2:672

```
Service container localstack failed.
/usr/bin/docker logs --details ac35d4b8f9c7b300fee2ba0d0baacf06e4bc793be75e857ff661ee279ee5bd12

LocalStack version: 3.0.0
LocalStack build date: 2023-11-16
LocalStack build git hash: 3cd32364

2025-04-24T16:17:07.780 WARN --- [ MainThread] localstack.deprecations : DATA_DIR is deprecated (since 1.0.0) and will be removed in upcoming releases of LocalStack! Please use PERSISTENCE instead. The state will be stored in your LocalStack volume in the state/ directory.
Error: Failed to initialize container localstack/localstack:3.0.0
Error: One or more containers failed to start.
```

(I don't think the `DATA_DIR is deprecated` warning is relevant, though I suppose it might be.)

I think we should consider dropping localstack and using small (nock-based, perhaps) mock tests for aws-sdk testing.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.