Skip to content

Commit

Permalink
New run-the-app include & trustCert updates (dotnet#15619)
Browse files Browse the repository at this point in the history
* New run-the-app include & trustcert updates

* Removed moniker from metadata since include has monikers

* removed moniker from metadata

* added VS context to run-the-app for alt-cmd-enter

* moved run app section to include run-the-app.md

* corrected date on metadata for razor-pages-start.md

* added bold for Run-Start without debugging to run-the-app.md
  • Loading branch information
wadepickett authored Nov 14, 2019
1 parent c74fc1a commit 1c2c9d2
Show file tree
Hide file tree
Showing 5 changed files with 50 additions and 47 deletions.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
28 changes: 28 additions & 0 deletions aspnetcore/includes/run-the-app.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
# [Visual Studio](#tab/visual-studio)

* Press Ctrl+F5 to run without the debugger.

[!INCLUDE[](~/includes/trustCertVS.md)]

Visual Studio starts [IIS Express](/iis/extensions/introduction-to-iis-express/iis-express-overview) and runs the app. The address bar shows `localhost:port#` and not something like `example.com`. That's because `localhost` is the standard hostname for the local computer. Localhost only serves web requests from the local computer. When Visual Studio creates a web project, a random port is used for the web server.

# [Visual Studio Code](#tab/visual-studio-code)

[!INCLUDE[](~/includes/trustCertVSC.md)]

* Press **Ctrl-F5** to run without the debugger.

Visual Studio Code starts [Kestrel](xref:fundamentals/servers/kestrel), launches a browser, and navigates to `http://localhost:5001`. The address bar shows `localhost:port#` and not something like `example.com`. That's because `localhost` is the standard hostname for local computer. Localhost only serves web requests from the local computer.


# [Visual Studio for Mac](#tab/visual-studio-mac)

[!INCLUDE[](~/includes/trustCertMac.md)]

* From Visual Studio, press **Alt-Cmd-Enter** to run without the debugger. Alternatively, navigate to the menu bar and go to **Run>Start Without Debugging**.

Visual Studio starts [Kestrel](xref:fundamentals/servers/kestrel), launches a browser, and navigates to `http://localhost:5001`.

<!-- End of VS tabs -->

---
19 changes: 18 additions & 1 deletion aspnetcore/includes/trustCertVS.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,20 @@
::: moniker range=">= aspnetcore-3.0"
Visual Studio displays the following dialog:

![This project is configured to use SSL. To avoid SSL warnings in the browser you can choose to trust the self-signed certificate that ASP.NET Core has generated. Would you like to trust the ASP.NET Core SSL certificate?](~/getting-started/_static/trustCert-3x.png)

Select **Yes** if you trust the ASP.NET Core SSL certificate.

The following dialog is displayed:

![Security warning dialog](~/getting-started/_static/cert.png)

Select **Yes** if you agree to trust the development certificate.

See [Trust the ASP.NET Core HTTPS development certificate](xref:security/enforcing-ssl#trust-the-aspnet-core-https-development-certificate-on-windows-and-macos) for more information.
::: moniker-end

::: moniker range="< aspnetcore-3.0"
Visual Studio displays the following dialog:

![This project is configured to use SSL. To avoid SSL warnings in the browser you can choose to trust the self-signed certificate that IIS Express has generated. Would you like to trust the IIS Express SSL certificate?](~/getting-started/_static/trustCert.png)
Expand All @@ -11,4 +27,5 @@ The following dialog is displayed:

Select **Yes** if you agree to trust the development certificate.

See [Trust the ASP.NET Core HTTPS development certificate](xref:security/enforcing-ssl#trust-the-aspnet-core-https-development-certificate-on-windows-and-macos) for more information.
See [Trust the ASP.NET Core HTTPS development certificate](xref:security/enforcing-ssl#trust-the-aspnet-core-https-development-certificate-on-windows-and-macos) for more information.
::: moniker-end
19 changes: 2 additions & 17 deletions aspnetcore/tutorials/grpc/grpc-start.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,8 @@
title: Create a .NET Core gRPC client and server in ASP.NET Core
author: juntaoluo
description: This tutorial shows how to create a gRPC Service and gRPC client on ASP.NET Core. Learn how to create a gRPC Service project, edit a proto file, and add a duplex streaming call.
monikerRange: '>= aspnetcore-3.0'
ms.author: johluo
ms.date: 10/10/2019
ms.date: 11/12/2019
uid: tutorials/grpc/grpc-start
---
# Tutorial: Create a gRPC client and server in ASP.NET Core
Expand Down Expand Up @@ -91,21 +90,7 @@ From Visual Studio, select **File** > **Open**, and then select the *GrpcGreeter

### Run the service

# [Visual Studio](#tab/visual-studio)

* Press `Ctrl+F5` to run the gRPC service without the debugger.

Visual Studio runs the service in a command prompt.

# [Visual Studio Code](#tab/visual-studio-code)

* Run the gRPC Greeter project *GrpcGreeter* from the command line using `dotnet run`.

# [Visual Studio for Mac](#tab/visual-studio-mac)

* Run the gRPC Greeter project *GrpcGreeter* from the command line using `dotnet run`.

---
[!INCLUDE[](~/includes/run-the-app.md)]

The logs show the service listening on `https://localhost:5001`.

Expand Down
31 changes: 2 additions & 29 deletions aspnetcore/tutorials/razor-pages/razor-pages-start.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ title: "Tutorial: Get started with Razor Pages in ASP.NET Core"
author: rick-anderson
description: This series of tutorials shows how to use Razor Pages in ASP.NET Core. Learn how to create a model, generate code for Razor pages, use Entity Framework Core and SQL Server for data access, add search functionality, add input validation, and use migrations to update the model.
ms.author: riande
ms.date: 07/25/2019
ms.date: 11/12/2019
uid: tutorials/razor-pages/razor-pages-start
---

Expand Down Expand Up @@ -114,34 +114,7 @@ From Visual Studio, select **File > Open**, and then select the *RazorPagesMovie

## Run the app

# [Visual Studio](#tab/visual-studio)

* Press Ctrl+F5 to run without the debugger.

[!INCLUDE[](~/includes/trustCertVS.md)]

Visual Studio starts [IIS Express](/iis/extensions/introduction-to-iis-express/iis-express-overview) and runs the app. The address bar shows `localhost:port#` and not something like `example.com`. That's because `localhost` is the standard hostname for the local computer. Localhost only serves web requests from the local computer. When Visual Studio creates a web project, a random port is used for the web server.

# [Visual Studio Code](#tab/visual-studio-code)

[!INCLUDE[](~/includes/trustCertVSC.md)]

* Press **Ctrl-F5** to run without the debugger.

Visual Studio Code starts [Kestrel](xref:fundamentals/servers/kestrel), launches a browser, and navigates to `http://localhost:5001`. The address bar shows `localhost:port#` and not something like `example.com`. That's because `localhost` is the standard hostname for local computer. Localhost only serves web requests from the local computer.


# [Visual Studio for Mac](#tab/visual-studio-mac)

[!INCLUDE[](~/includes/trustCertMac.md)]

* Press **Alt-Cmd-Enter** to run without the debugger. Alternatively, navigate to the menu bar and go to Run>Start Without Debugging.

Visual Studio starts [Kestrel](xref:fundamentals/servers/kestrel), launches a browser, and navigates to `http://localhost:5001`.

<!-- End of VS tabs -->

---
[!INCLUDE[](~/includes/run-the-app.md)]

## Examine the project files

Expand Down

0 comments on commit 1c2c9d2

Please sign in to comment.