Aspire AzureStorage (and others) should allow non-container mode
- 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
### Is your feature request related to a problem? Please describe the problem.
As a developer of ASP.NET Core + Azure Storage + EFCore SQL Server apps, I would like to use Aspire more fully without using containers. I want the rich dev time logging, configuration, etc. of Aspire, but am not ready to adopt containers for Azure Storage Emulator and SQL Server.
### Describe the solution you'd like
I envision being able to do very similar to the existing Storage Emulator and SQL examples, but to allow using non-container options. In AppHost, I would like to have it find and start up azurite executable in-process:
```
var storage = builder.AddAzureStorage("Storage");
if (builder.Environment.IsDevelopment()){ storage.RunLocalEmulator(@"D:\myproject_temp_storage"); }
```
As well as use SQL server already running on my dev machine:
```
var sql = builder.AddSqlServer("sql");
if (builder.Environment.IsDevelopment()){ sql = sql.WithLocalServer(@"(localdb)"); }
```
From then on, expectation would be that the injected resources would work the same as container options.
### Additional context
I was able to launch Azurite using an ExecutableResource, but was unable to work it in such a way that it integrated with the existing Aspire.Azure.Storage code and let me inject connection info into the app. Similarly, we can can of course continue to connect to SQL directly from the ASP.NET app, but in both cases we don't get the rich tracing and logging for those in Aspire.
Our dev team already has Storage Emulator (it ships with VS!) and SQL Server. Containerizing those right now doesn't make sense for us, and our dev vms hosted in Azure don't support Docker.
Our apps are already set up in Azure AppService, Azure SQL, and Storage, and have a CI/CD pipeline for deployment. We're not ready to containerize the production app or automate deployment via bicep. By supporting local non-container flavors of the things that can, Aspire will be a smoother on-ramp for developers who want the rich dev experience of Aspire but are not ready to adopt containers for all the things.
Contributor guide
Assessment
This issue has not been assessed yet.