|
136 | 136 | .WithEnvironment(envSinkCertPfxBase64, sinkCertPfxBase64) |
137 | 137 | // Server cert path on the host — seeder uses it as client cert to authenticate to RavenDB |
138 | 138 | .WithEnvironment(envServerCertPath, serverCertPath) |
139 | | - .WithEnvironment(envRavenDbClientCertificatePath, serverCertPath); |
| 139 | + .WithEnvironment(envRavenDbClientCertificatePath, serverCertPath) |
| 140 | + // Seeder is a generic Host (not WebApplication), so Aspire doesn't auto-populate |
| 141 | + // ASPNETCORE_ENVIRONMENT for it; without DOTNET_ENVIRONMENT the self-signed cert |
| 142 | + // acceptance in Setup/Program.cs never activates and database creation over the |
| 143 | + // secured RavenDB connection fails the TLS handshake. |
| 144 | + .WithEnvironment("DOTNET_ENVIRONMENT", "Development"); |
140 | 145 |
|
141 | 146 | // Verity App |
142 | 147 | var functions = builder.AddAzureFunctionsProject<RavenDB_Samples_Verity_App>("app") |
|
167 | 172 | .WithEnvironment( |
168 | 173 | envHubServerInternalUrl, |
169 | 174 | ReferenceExpression.Create($"https://localhost:{ravenEndpoint.Property(EndpointProperty.TargetPort)}")) |
170 | | - .WithEnvironment(envRavenDbClientCertificatePath, serverCertPath); |
| 175 | + .WithEnvironment(envRavenDbClientCertificatePath, serverCertPath) |
| 176 | + // Same DOTNET_ENVIRONMENT gap as seeder/subscriptions — needed for the self-signed |
| 177 | + // cert acceptance in App/Program.cs to activate. |
| 178 | + .WithEnvironment("DOTNET_ENVIRONMENT", "Development"); |
171 | 179 |
|
172 | 180 | // DataSubscriptionsApp — interactive Spectre.Console TUI, must run in its own console window |
173 | 181 | // cmd /c start spawns a detached window so Aspire doesn't capture stdin/stdout |
|
200 | 208 | .WithExternalHttpEndpoints() |
201 | 209 | .WithReference(db) |
202 | 210 | .WaitFor(db) |
203 | | - .WithEnvironment(envRavenDbClientCertificatePath, serverCertPath); |
| 211 | + .WithEnvironment(envRavenDbClientCertificatePath, serverCertPath) |
| 212 | + // Same DOTNET_ENVIRONMENT gap as seeder/subscriptions/app — needed for the self-signed |
| 213 | + // cert acceptance in IdentityServer/Program.cs to activate. |
| 214 | + .WithEnvironment("DOTNET_ENVIRONMENT", "Development"); |
204 | 215 | functions.WithEnvironment("Identity__Url", identity.GetEndpoint("http")); |
205 | 216 | // BFF — single entry point for the browser; proxies API (with tokens) + frontend |
206 | 217 | var bff = builder.AddProject<RavenDB_Samples_Verity_Bff>("bff") |
|
0 commit comments