在Core 2.2中通过本地设置代理

时间:2019-04-01 14:53:39

标签: .net proxy core

我正在尝试连接到Azure Key Vault。我们在本地具有代理,并且使用.NET CORE 2.2似乎并不困难。它可以与较早的框架一起使用,但CORE 2.2中没有Web配置。

我正在尝试以下方法,但不起作用。任何帮助表示赞赏

public static IWebHostBuilder CreateWebHostBuilder(string[] args)
    {
        return WebHost.CreateDefaultBuilder(args)
    .UseStartup<Startup>()
    .UseHttpSys(options =>
        {
           options.Authentication.Schemes = AuthenticationSchemes.None;
            options.Authentication.AllowAnonymous = true;
            options.MaxConnections = null;
            options.MaxRequestBodySize = 30000000;
            options.UrlPrefixes.Add($"http://proxy:8090");

        });
    }

我需要能够连接到Key Vault并获取凭据。似乎它可以在不设置代理的情况下与AZURE活动目录一起使用,但不适用于Key Vault

0 个答案:

没有答案