Aspire Dev Tunnel creates duplicate tunnel name if file paths are the same across developer workstations
- Dominant language
- C#
- Stars
- 6.3k
- Forks
- 991
- Avg merge
- 2d 15h
- Merged PRs (30d)
- 196
Description
### Is there an existing issue for this?
- [x] I have searched the existing issues
### Describe the bug
Confirmed by folks on the discord channel, this bug is related to Dev Tunnels using a `AppHost:Sha256` configuration on start to name the tunnel. If the repo is cloned and run by people with the same path (i.e. `C:\source\repos\MyProject`), then the tunnel names will be identical and the second person to clone will be unable to start the tunnel.
https://github.com/dotnet/aspire/blob/b4fa644d7ce151c0c8e92ebf70054b53c953d726/src/Aspire.Hosting/DistributedApplicationBuilder.cs#L272
### Expected Behavior
Each Dev Tunnel should use a unique name for the tunnel ID.
### Steps To Reproduce
- Create an Aspire project with a Dev Tunnel on `C:\projects\MyProject` on PC1.
- Start the project and observe the tunnel ID.
- Clone the project on PC2 and run the project.
- Observe the tunnel does not start and produces an error indicating the tunnel name already exists.
### Exceptions (if any)
_No response_
### .NET Version info
.NET 10
### Anything else?
_No response_
Contributor guide
Assessment
This issue has not been assessed yet.