Provide healthcheck feature in Docker image
- Dominant language
- TypeScript
- Stars
- 2.3k
- Forks
- 393
- Avg merge
- 1d 20h
- Merged PRs (30d)
- 36
Description
### Which service(blob, file, queue, table) does this issue concern?
Blob.
### Which version of the Azurite was used?
3.19.0
### Where do you get Azurite? (npm, DockerHub, NuGet, Visual Studio Code Extension)
DockerHub
### What's the Node.js version?
In Docker image.
### What problem was encountered?
When running in CI, the sequencing needs to be done correctly. This means the tests with the storage will try to use it at some point where it might or might not have already started.
When running with Docker, the common solution is to provide a [healthcheck](https://docs.docker.com/engine/reference/builder/#healthcheck).
### Steps to reproduce the issue?
Start Azurite in Docker and attempt to use it immediately from another process, the requests have a 50%-50% chance to fail since the process is not fully started yet.
### Have you found a mitigation/solution?
Creating a healthcheck yourself.
Example Docker Compose file with healthcheck:
```yaml
services:
storage:
image: mcr.microsoft.com/azure-storage/azurite:3.19.0
healthcheck:
test: nc 127.0.0.1 10000 -z
interval: 1s
retries: 30
```
Contributor guide
No contributing guide indexed for this repository
Assessment
This issue has not been assessed yet.