mirror of
https://github.com/nsnail/Ocelot.git
synced 2025-04-22 06:42:50 +08:00
all administration tests passing again...yey
This commit is contained in:
parent
3f6f665f93
commit
b23bbf56b9
@ -158,7 +158,9 @@ namespace Ocelot.DependencyInjection
|
|||||||
services.TryAddSingleton<IIdentityServerConfiguration>(identityServerConfiguration);
|
services.TryAddSingleton<IIdentityServerConfiguration>(identityServerConfiguration);
|
||||||
services.TryAddSingleton<IHashMatcher, HashMatcher>();
|
services.TryAddSingleton<IHashMatcher, HashMatcher>();
|
||||||
var identityServerBuilder = services
|
var identityServerBuilder = services
|
||||||
.AddIdentityServer()
|
.AddIdentityServer(o => {
|
||||||
|
o.IssuerUri = "Ocelot";
|
||||||
|
})
|
||||||
.AddInMemoryApiResources(Resources(identityServerConfiguration))
|
.AddInMemoryApiResources(Resources(identityServerConfiguration))
|
||||||
.AddInMemoryClients(Client(identityServerConfiguration))
|
.AddInMemoryClients(Client(identityServerConfiguration))
|
||||||
.AddResourceOwnerValidator<OcelotResourceOwnerPasswordValidator>();
|
.AddResourceOwnerValidator<OcelotResourceOwnerPasswordValidator>();
|
||||||
|
@ -9,17 +9,14 @@ namespace Ocelot.ManualTest
|
|||||||
public static void Main(string[] args)
|
public static void Main(string[] args)
|
||||||
{
|
{
|
||||||
IWebHostBuilder builder = new WebHostBuilder();
|
IWebHostBuilder builder = new WebHostBuilder();
|
||||||
|
|
||||||
builder.ConfigureServices(s => {
|
builder.ConfigureServices(s => {
|
||||||
s.AddSingleton(builder);
|
s.AddSingleton(builder);
|
||||||
});
|
});
|
||||||
|
|
||||||
builder.UseKestrel()
|
builder.UseKestrel()
|
||||||
.UseContentRoot(Directory.GetCurrentDirectory())
|
.UseContentRoot(Directory.GetCurrentDirectory())
|
||||||
.UseStartup<Startup>();
|
.UseStartup<Startup>();
|
||||||
|
|
||||||
var host = builder.Build();
|
var host = builder.Build();
|
||||||
|
|
||||||
host.Run();
|
host.Run();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user