Skip to content

Commit 52e2aa4

Browse files
Apply suggestions from code review
Co-authored-by: Samruddhi Khandale <samruddhikhandale@github.com>
1 parent 6a1fa17 commit 52e2aa4

File tree

1 file changed

+7
-7
lines changed

1 file changed

+7
-7
lines changed

src/dotnet/README.md

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -39,11 +39,11 @@ See [history](history) for information on the contents of each version and [here
3939

4040
Alternatively, you can use the contents of [.devcontainer](.devcontainer) to fully customize your container's contents or to build it for a container host architecture not supported by the image.
4141

42-
### Enabling HTTPS in ASP.NET Core
42+
### Enabling HTTPS in ASP.NET Core by creating a dev certificate
4343

44-
You can use `dotnet dev-certs https` inside the Dev Container to create a development HTTPS certificate for ASP.NET Core. However, each time the container is recreated, the development certificate will be lost. To make the development certificate survive container rebuilds, you can use a named volume.
44+
You can use `dotnet dev-certs https` inside the dev container to create a development HTTPS certificate for ASP.NET Core. However, each time the container is recreated, the development certificate will be lost. To make the development certificate survive container rebuilds, you can use a named volume.
4545

46-
For example, in `devcontainer.json`, add a named volume for the `x509stores` directory inside the `vscode` user's home folder. Also add a lifecycle script, which adds the development certificate to the Dev Container's trust store.
46+
For example, in `devcontainer.json`, add a named volume for the `x509stores` directory inside the `vscode` user's home folder. Also add a lifecycle script, which adds the development certificate to the dev container's trust store.
4747

4848
``` json
4949
"mounts": [
@@ -72,7 +72,7 @@ sudo -E dotnet dev-certs https --export-path /usr/local/share/ca-certificates/ht
7272
sudo update-ca-certificates
7373
```
7474

75-
You should see the following output when the Dev Container is created:
75+
You should see the following output when the dev container is created:
7676

7777
``` text
7878
Running the onCreateCommand from devcontainer.json...
@@ -85,11 +85,11 @@ Running hooks in /etc/ca-certificates/update.d...
8585
done.
8686
```
8787

88-
Now this certificate will survive container rebuilds. The certificate will also be trusted by code running inside the container like `System.Net.HttpClient`, or tools like wget and curl. If needed, you can use Docker Desktop to export the development certificate to a local directory, in case you need to add it to any other trust stores.
88+
Now this certificate will survive container rebuilds. The certificate will also be trusted by code running inside the container like `System.Net.HttpClient`, or tools like `wget` and `curl`. If needed, you can use Docker Desktop to export the development certificate to a local directory, in case you need to add it to any other trust stores.
8989

90-
#### Alternate solution
90+
### Enabling HTTPS in ASP.NET using your own dev certificate
9191

92-
You can mount an exported copy of your local dev certificate. This solution is only suitable for private projects, as the password will become part of your `devcontainer.json`. Do not apply this solution to team projects or open source projects.
92+
You can mount an exported copy of your local dev certificate for enhanced convenience. This solution is ideal for private projects, but please note that the password will be included in your `devcontainer.json`. Avoid using this method for team projects or open source projects to maintain security best practices.
9393

9494
1. Export the local certificate using the following command:
9595

0 commit comments

Comments
 (0)