Skip to content

Commit 840fe8d

Browse files
authored
Merge pull request #6486 from ghogen/containers
Container Tools Edit and Refresh: Add Startup code
2 parents e5639c6 + 976d457 commit 840fe8d

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed

docs/containers/edit-and-refresh.md

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -76,6 +76,16 @@ To quickly iterate changes, you can start your application in a container. Then,
7676
}
7777
```
7878

79+
Modify the `Startup` method as follows:
80+
81+
```csharp
82+
public Startup(IConfiguration configuration, IWebHostEnvironment webHostEnvironment)
83+
{
84+
Configuration = configuration;
85+
Env = webHostEnvironment;
86+
}
87+
```
88+
7989
For more information, see [Razor file compilation in ASP.NET Core](/aspnet/core/mvc/views/view-compilation?view=aspnetcore-3.1).
8090

8191
1. Set **Solution Configuration** to **Debug**. Then, press **Ctrl**+**F5** to build your Docker image and run it locally.

0 commit comments

Comments
 (0)