Hi
we have created 2 app (angular apps) and we use a single Auth server.
Our goal is from app1 move to app2 without reinsert credentials.
Our landscape is confgured in multitenant enviroment with tenant resolver, so we have
The first App use a login embedded on Angular when I click in a link that redirect to App2 I land on home but I'm not already logged in. I click the login button but I need to re enter my credentials.
Is it possibile to login directly?
If I go on Auth server page after login I can see all my apps but only one (the first) if I click I can go inside already loggedin the second no
I see that if I configure auth server with this options and try to login from api (https://customer1.api.myapp.com) I can't login
"SelfUrl": "https://auth.myapp.com",
...
"TenantResolver": "https://{0}.auth.myapp.com"
If I remove the tenant resolver I see the login page from auth server I need to inser manually the tenant but it works
Hi I know but I don't found any other solution
Hi
I found this possibile solution
.ConfigureWebHostDefaults(builder =>
{
builder.Configure(app =>
{
app.UseRouting();
app.UseHangfireDashboard();
app.UseEndpoints(endpoints =>
{
endpoints.MapHangfireDashboard();
});
});
})
How can I add a HangFire Dashboar to my console APP/winService?
How can I inject Iconfiguration?
public override async Task OnApplicationInitializationAsync(
ApplicationInitializationContext context)
{
await context.AddBackgroundWorkerAsync<PollingWorker>();
}
If I add an IServiceProvider I get this error
annot resolve parameter 'Microsoft.Extensions.DependencyInjection.IServiceCollection service' of constructor 'Void .ctor(Microsoft.Extensions.DependencyInjection.IServiceCollection)'.
at Autofac.Core.Activators.Reflection.ReflectionActivator.GetAllBindings(ConstructorBinder[] availableConstructors, IComponentContext context, IEnumerable`1 parameters)
at Autofac.Core.Activators.Reflection.ReflectionActivator.ActivateInstance(IComponentContext context, IEnumerable`1 parameters)
at Autofac.Core.Activators.Reflection.ReflectionActivator.<ConfigurePipeline>b__11_0(ResolveRequestContext ctxt, Action`1 next)
at Autofac.Core.Resolving.Pipeline.ResolvePipelineBuilder.<>c__DisplayClass14_0.<BuildPipeline>b__1(ResolveRequestContext ctxt)
Hangfire
HI how can I add a recurring job at run time? and how can I remove it?
so I try to add via startup but I try to read polling intervall via appsettings.json but I can't do it
public PollingWorker()
{
//_options = ServiceProvider.GetService<IOptions<Dataptions>>().Value; --> Null exception
RecurringJobId = nameof(PollingWorker);
CronExpression = Cron.MinuteInterval(2);
}
I try to login from winfrom using IIdentityModelAuthenticationService it works fine on host but how can I set the tenant? How can get tenat Id from name?
using (var cs = _provider.CreateScope())
{
_tenant.Change(myTenantGuid, txtTenant.Text);
AsyncHelper.RunSync(() =>
_tokenManager.ObtainAccessToken(txtUser.Text, txtPassword.Text, txtUrl.Text));
var q = AsyncHelper.RunSync(() => _appService.GetAsync());
}
Hi
from my side it not works but I found this post and I remove
responseType: 'code',
After that my login on angular side work I dont redirect me to IDS login page.
The issue still exists on API if I try to login from swagger the app redirect me to base auth and not to tenant auth
I've configure my app in multi tenant (with tenant resolver) and replace login component with local Angular UI the problem is that when I click login I'll be redirect to IDS (mvc page in place to my local Angular UI).
My App.Component.Ts is set to:
ngOnInit() {
this.replaceableComponentsService.add({
key: eAccountComponents.Login,
component: LoginComponent,
});
this.replaceableComponentsService.add({
key: eAccountComponents.Register,
component: RegisterComponent,
});
this.replaceableComponentsService.add({
key: eThemeLeptonComponents.AccountLayout,
component: AccountLayoutComponent,
});
}
It works fine if I don't use tenantResolver but when I switch to tenant roselver (using {0} for placeholder) local login not work