Skip to content

Commit 8deb1d7

Browse files
authored
Version the Let's Encrypt article (#35615)
1 parent bbf2327 commit 8deb1d7

File tree

1 file changed

+18
-10
lines changed

1 file changed

+18
-10
lines changed

aspnetcore/fundamentals/servers/yarp/lets-encrypt.md

Lines changed: 18 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -3,27 +3,33 @@ uid: fundamentals/servers/yarp/lets-encrypt
33
title: YARP Lets Encrypt
44
description: YARP Lets Encrypt
55
author: samsp-msft
6+
monikerRange: '<= aspnetcore-7.0'
67
ms.author: samsp
7-
ms.date: 2/6/2025
8+
ms.date: 6/13/2025
89
ms.topic: article
910
content_well_notification: AI-contribution
1011
ai-usage: ai-assisted
1112
---
12-
1313
# YARP Lets Encrypt
1414

15+
> [!NOTE]
16+
> The [`LettuceEncrypt` NuGet package](https://github.com/natemcmaster/LettuceEncrypt) described in this article is archived and no longer supported, so the package isn't recommended for use.
17+
1518
## Introduction
16-
YARP can support the certificate authority [Lets Encrypt](https://letsencrypt.org/) by using the API of another ASP.NET Core project [LettuceEncrypt](https://github.com/natemcmaster/LettuceEncrypt). It allows you to set up TLS between the client and YARP with minimal configuration.
19+
20+
YARP can support the certificate authority [Lets Encrypt](https://letsencrypt.org/) by using the API of another ASP.NET Core project, [`LettuceEncrypt`](https://github.com/natemcmaster/LettuceEncrypt). It allows you to set up TLS between the client and YARP with minimal configuration.
1721

1822
## Requirements
1923

20-
Add the LettuceEncrypt package dependency:
24+
Add the `LettuceEncrypt` package dependency:
25+
2126
```csproj
2227
<PackageReference Include="LettuceEncrypt" Version="1.1.2" />
2328
```
2429

2530
## Configuration
26-
There are required options for LettuceEncrypt that should be set, see the example of `appsettings.json`:
31+
32+
There are required options for `LettuceEncrypt` that should be set. See the example of `appsettings.json`:
2733

2834
```json
2935
{
@@ -37,8 +43,10 @@ There are required options for LettuceEncrypt that should be set, see the exampl
3743
},
3844

3945
"LettuceEncrypt": {
40-
// Set this to automatically accept the terms of service of your certificate authority.
41-
// If you don't set this in config, you will need to press "y" whenever the application starts
46+
// Set this to automatically accept the terms of service of your certificate
47+
// authority.
48+
// If you don't set this in config, you will need to press "y" whenever the
49+
// application starts
4250
"AcceptTermsOfService": true,
4351

4452
// You must specify at least one domain name
@@ -56,16 +64,17 @@ There are required options for LettuceEncrypt that should be set, see the exampl
5664
services.AddLettuceEncrypt();
5765
```
5866

59-
For more options (i.e. saving certificates) see examples in [LettuceEncrypt doc](https://github.com/natemcmaster/LettuceEncrypt).
67+
For more options (for example, saving certificates) see the examples in the [`LettuceEncrypt` project README](https://github.com/natemcmaster/LettuceEncrypt).
6068

6169
## Kestrel Endpoints
6270

63-
If your project is explicitly using kestrel options to configure IP addresses, ports, or HTTPS settings, you will also need to call `UseLettuceEncrypt`.
71+
If your project is explicitly using Kestrel options to configure IP addresses, ports, or HTTPS settings, call `UseLettuceEncrypt`:
6472

6573
Example:
6674

6775
```csharp
6876
var builder = WebApplication.CreateBuilder(args);
77+
6978
builder.WebHost.ConfigureKestrel(kestrel =>
7079
{
7180
kestrel.ListenAnyIP(443, portOptions =>
@@ -77,4 +86,3 @@ builder.WebHost.ConfigureKestrel(kestrel =>
7786
});
7887
});
7988
```
80-

0 commit comments

Comments
 (0)