[CI Failure] Flaky: DockerComposeTests.DeployWithDashboard_PrintsDashboardAndServiceEndpoints fails due to port already in use
- Dominant language
- C#
- Stars
- 6.3k
- Forks
- 991
- Avg merge
- 2d 12h
- Merged PRs (30d)
- 201
Description
## Build Information
Build: https://github.com/microsoft/aspire/actions/runs/29060081150
Build error leg or test failing: Tests / Hosting.Docker / Hosting.Docker (ubuntu-latest) / `Aspire.Hosting.Docker.Tests.DockerComposeTests.DeployWithDashboard_PrintsDashboardAndServiceEndpoints`
Pull request: #18698
## Error Message
```
Error response from daemon: failed to set up container networking: driver failed programming external connectivity on endpoint aspire-env-c0bc8a71-nginx-1: failed to bind host port for 0.0.0.0:54398:172.18.0.2:80/tcp: address already in use
'docker compose up' failed with exit code 1.
Assert.Contains() Failure: Filter not matched in collection
Collection: []
```
## Description
Flaky: DockerComposeTests.DeployWithDashboard_PrintsDashboardAndServiceEndpoints fails due to port already in use
**Type**: flaky-test
## Occurrences
| Date | Build | Job | PR |
|------|-------|-----|----|
| 2026-07-10 | [29060081150](https://github.com/microsoft/aspire/actions/runs/29060081150) | Tests / Hosting.Docker / Hosting.Docker (ubuntu-latest) | #18698 |
| 2026-07-13 | [29220139824](https://github.com/microsoft/aspire/actions/runs/29220139824) | Tests / Hosting.Docker / Hosting.Docker (ubuntu-latest) | #18738 |
| 2026-08-04 | [30869057632](https://github.com/microsoft/aspire/actions/runs/30869057632) | Tests / Hosting.Docker / Hosting.Docker (ubuntu-latest) | #18930 |
| 2026-09-15 | [35023788042](https://github.com/microsoft/aspire/actions/runs/35023788042) | Tests / No-package tests (regular, Aspire.Hosting.Docker.Tests, Hosting.Docker, Hosting.Docker, tests/Asp... / Hosting.Docker (ubuntu-latest) | #20052 |
Contributor guide
Research direction
Start with Aspire.Hosting.Docker.Tests.DockerComposeTests.DeployWithDashboard_PrintsDashboardAndServiceEndpoints and reproduce it in the Hosting.Docker test job. Investigate how the test obtains host port 54398 and how Docker Compose cleanup is handled; done means repeated runs no longer fail with an address-already-in-use error.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- csharp, docker, docker-compose, github-actions
- Domain
- ci-cd, devops, testing
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Quiet
- Clarity
- Needs clarification
- Newbie friendliness
- 48/100