Program.cs 950 B

1234567891011121314151617181920212223242526272829303132
  1. using System;
  2. using System.Collections.Generic;
  3. using System.IO;
  4. using System.Linq;
  5. using System.Threading.Tasks;
  6. using Microsoft.AspNetCore.Hosting;
  7. using Microsoft.Extensions.Configuration;
  8. using Microsoft.Extensions.Hosting;
  9. using Microsoft.Extensions.Logging;
  10. namespace MySystem
  11. {
  12. public class Program
  13. {
  14. public static void Main(string[] args)
  15. {
  16. CreateHostBuilder(args).Build().Run();
  17. }
  18. public static IHostBuilder CreateHostBuilder(string[] args) =>
  19. Host.CreateDefaultBuilder(args)
  20. .ConfigureWebHostDefaults(webBuilder =>
  21. {
  22. webBuilder
  23. .UseUrls("http://*:5311")
  24. .UseKestrel()
  25. .UseContentRoot(Directory.GetCurrentDirectory())
  26. .UseIISIntegration()
  27. .UseStartup<Startup>();
  28. });
  29. }
  30. }