From 1a43898d2d8b17772e747ce490f4707cfcf25373 Mon Sep 17 00:00:00 2001 From: David Pine Date: Wed, 12 Jun 2024 11:24:51 -0500 Subject: [PATCH] Add details about trusting dev-cert (#1087) * Draft to fix #1068 * Be a bit more specific --- docs/get-started/build-your-first-aspire-app.md | 13 ++++++++++++- .../untrusted-localhost-certificate.md | 1 + 2 files changed, 13 insertions(+), 1 deletion(-) diff --git a/docs/get-started/build-your-first-aspire-app.md b/docs/get-started/build-your-first-aspire-app.md index 3bbb39673..637d59a22 100644 --- a/docs/get-started/build-your-first-aspire-app.md +++ b/docs/get-started/build-your-first-aspire-app.md @@ -1,7 +1,7 @@ --- title: Build your first .NET Aspire app description: Learn how to build your first .NET Aspire app using the .NET Aspire Started Application template. -ms.date: 05/13/2024 +ms.date: 06/12/2024 ms.topic: quickstart zone_pivot_groups: dev-environment --- @@ -52,6 +52,17 @@ The sample app is now ready for testing. You want to verify the following: In Visual Studio, set the **AspireSample.AppHost** project as the startup project by right-clicking on the project in the **Solution Explorer** and selecting **Set as Startup Project**. Then, press F5 to run the app. +:::zone-end +:::zone pivot="vscode,dotnet-cli" + +If you haven't already trusted the ASP.NET Core localhost certificate, you will need to trust the certificate before running the app: + +```dotnetcli +dotnet dev-certs https --trust +``` + +For more information, see [Troubleshoot untrusted localhost certificate in .NET Aspire](../troubleshooting/untrusted-localhost-certificate.md). For in-depth details about troubleshooting localhost certificates on Linux, see [ASP.NET Core: GitHub repository issue #32842](https://github.com/dotnet/aspnetcore/issues/32842). + :::zone-end :::zone pivot="vscode" diff --git a/docs/troubleshooting/untrusted-localhost-certificate.md b/docs/troubleshooting/untrusted-localhost-certificate.md index 7540b6cd1..e4de03081 100644 --- a/docs/troubleshooting/untrusted-localhost-certificate.md +++ b/docs/troubleshooting/untrusted-localhost-certificate.md @@ -42,3 +42,4 @@ For more troubleshooting, see [Troubleshoot certificate problems such as certifi - [Trust the ASP.NET Core HTTPS development certificate on Windows and macOS](/aspnet/core/security/enforcing-ssl#trust-the-aspnet-core-https-development-certificate-on-windows-and-macos) - [Trust HTTPS certificate on Linux](/aspnet/core/security/enforcing-ssl##trust-https-certificate-on-linux) - [.NET CLI: dotnet dev-certs](/dotnet/core/tools/dotnet-dev-certs) +- [Trust localhost certificate on Linux](https://github.com/dotnet/aspnetcore/issues/32842)