You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: aspnetcore/fundamentals/servers/yarp/getting-started.md
+25-23Lines changed: 25 additions & 23 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -12,43 +12,43 @@ ai-usage: ai-assisted
12
12
13
13
# Getting Started with YARP
14
14
15
-
YARP is designed as a library that provides the core proxy functionality which you can then customize by adding or replacing modules.
16
-
YARP is currently provided as a NuGet package and code snippets.
17
-
We plan on providing a project template and pre-built exe in the future.
15
+
YARP is designed as a library that provides the core proxy functionality which you can then customize by adding or replacing modules. YARP is currently provided as a NuGet package and code snippets. We plan on providing a project template and prebuilt executable (`.exe`) in the future.
18
16
19
-
YARP is implemented on top of .NET Core infrastructure and is usable on Windows, Linux or MacOS.
20
-
Development can be done with the SDK and your favorite editor, [Microsoft Visual Studio](https://visualstudio.microsoft.com/vs/) or [Visual Studio Code](https://code.visualstudio.com/).
17
+
YARP is implemented on top of .NET Core infrastructure and is usable on Windows, Linux or MacOS. Development can be done with the SDK and your favorite editor, [Microsoft Visual Studio](https://visualstudio.microsoft.com/vs/) or [Visual Studio Code](https://code.visualstudio.com/).
18
+
19
+
YARP 2.3.0 supports ASP.NET Core 8.0 and newer.
21
20
22
-
YARP 2.1.0 supports ASP.NET Core 6.0 and newer, including ASP.NET Core 8.0.
23
21
You can download the .NET SDK from https://dotnet.microsoft.com/download/dotnet/.
24
22
25
23
Visual Studio support for .NET 8 is included in Visual Studio 2022 17.8.
26
24
27
-
###Create a new project
25
+
## Create a new project
28
26
29
27
A complete version of the project built using the steps below can be found at [Basic YARP Sample](https://github.com/microsoft/reverse-proxy/tree/release/latest/samples/BasicYarpSample).
30
28
31
29
Start by creating an "Empty" ASP.NET Core application using the command line:
32
30
33
-
```Console
31
+
```dotnetcli
34
32
dotnet new web -n MyProxy -f net8.0
35
33
```
36
34
37
-
Or create a new ASP.NET Core web application in Visual Studio 2022, and choose "Empty" for the project template.
35
+
Alternatively, create a new ASP.NET Core web application in Visual Studio 2022, choosing "Empty" for the project template.
36
+
37
+
## Add the package reference
38
38
39
-
### Add the project reference
39
+
Add a package reference for [`Yarp.ReverseProxy`](https://www.nuget.org/packages/Yarp.ReverseProxy), version 2.3.0 or later.
The configuration for YARP is defined in the appsettings.json file. See [Configuration Files](xref:fundamentals/servers/yarp/config-files) for details.
62
+
The configuration for YARP is defined in the `appsettings.json` file. For more information, see <xref:fundamentals/servers/yarp/config-files>.
63
63
64
-
The configuration can also be provided programmatically. See [Configuration Providers](xref:fundamentals/servers/yarp/config-providers) for details.
64
+
The configuration can also be provided programmatically. For more information, see <xref:fundamentals/servers/yarp/config-providers>.
65
65
66
-
You can find out more about the available configuration options by looking at [RouteConfig](xref:Yarp.ReverseProxy.Configuration.RouteConfig) and [ClusterConfig](xref:Yarp.ReverseProxy.Configuration.ClusterConfig).
66
+
Learn more about the available configuration options by looking at <xref:Yarp.ReverseProxy.Configuration.RouteConfig> and <xref:Yarp.ReverseProxy.Configuration.ClusterConfig>.
67
67
68
-
```JSON
68
+
```json
69
69
{
70
70
"Logging": {
71
71
"LogLevel": {
@@ -97,6 +97,8 @@ You can find out more about the available configuration options by looking at [R
97
97
}
98
98
```
99
99
100
-
### Running the project
100
+
## Run the project
101
+
102
+
When using the .NET CLU, use `dotnet run` called within the sample's directory or `dotnet run --project <path to .csproj file>`.
101
103
102
-
Use `dotnet run` called within the sample's directory or `dotnet run --project <path to .csproj file>`
104
+
In Visual Studio, start the app with the **Run** button.
0 commit comments