Open Allann opened 6 months ago
You can connect to an existing server by adding a connection string to your app model using builder.AddConnectionString
. The challenge with making a sample for that is that of course it will actually require a connection string to be set in configuration (likely user secrets given it often contains a password) and then to work will need a server instance available.
Wondering if it's even a thing anymore, it used to be the standard, but a simple example of an Aspire orchestration utilizing an existing OnPrem sql server database that can't be changed via migrations, accessed via EF and referenced in many projects.
The reason I ask is that the current SQL implementation utilises a container image with no other options. Whilst I understand that this is to empower the Dev Experience, many of us don't work on green field apps or demos, but instead need to hook to existing infrastructure.
Even the SqlServerEndToEnd project doesn't show how.