Re-examining WebHostBuilderContext
Remember the WebHostBuilder
Kestrel configuration in the Program.cs
file that we looked at in Chapter 4, Configuring and Customizing HTTPS with Kestrel? In that chapter, we saw that you should use user secrets to configure the certificates password, as shown in the following code snippet:
public class Program { public static void Main(string[] args) { CreateHostBuilder(args).Build().Run(); } public static IHostBuilder CreateHostBuilder( string[] args) => Host.CreateDefaultBuilder(args) .ConfigureWebHostDefaults(webBuilder => { ...