feat(#IW622): 支持二级域名单点登录
#Comment comment #IW622 #Issue close https://gitee.com/LongbowEnterprise/dashboard/issues?id=IW622
This commit is contained in:
parent
9bc8cf6f5c
commit
0764437f3f
|
@ -80,7 +80,11 @@ namespace Bootstrap.Admin
|
||||||
options.SerializerSettings.DateFormatString = "yyyy-MM-dd HH:mm:ss";
|
options.SerializerSettings.DateFormatString = "yyyy-MM-dd HH:mm:ss";
|
||||||
JsonConvert.DefaultSettings = () => options.SerializerSettings;
|
JsonConvert.DefaultSettings = () => options.SerializerSettings;
|
||||||
}).SetCompatibilityVersion(CompatibilityVersion.Version_2_2);
|
}).SetCompatibilityVersion(CompatibilityVersion.Version_2_2);
|
||||||
services.AddAuthentication(CookieAuthenticationDefaults.AuthenticationScheme).AddCookie(options => options.Cookie.Path = "/");
|
services.AddAuthentication(CookieAuthenticationDefaults.AuthenticationScheme).AddCookie(options =>
|
||||||
|
{
|
||||||
|
options.Cookie.Path = "/";
|
||||||
|
options.Cookie.Domain = Configuration["Domain"];
|
||||||
|
});
|
||||||
services.AddApiVersioning(option =>
|
services.AddApiVersioning(option =>
|
||||||
{
|
{
|
||||||
option.DefaultApiVersion = new ApiVersion(1, 0);
|
option.DefaultApiVersion = new ApiVersion(1, 0);
|
||||||
|
|
|
@ -17,6 +17,7 @@
|
||||||
},
|
},
|
||||||
"SwaggerPathBase": "",
|
"SwaggerPathBase": "",
|
||||||
"AllowOrigins": "http://localhost:49185",
|
"AllowOrigins": "http://localhost:49185",
|
||||||
|
"Domain": null,
|
||||||
"KeyPath": "..\\keys",
|
"KeyPath": "..\\keys",
|
||||||
"DisableAutomaticKeyGeneration": false,
|
"DisableAutomaticKeyGeneration": false,
|
||||||
"LongbowCache": {
|
"LongbowCache": {
|
||||||
|
|
|
@ -51,6 +51,7 @@
|
||||||
],
|
],
|
||||||
"SwaggerPathBase": "/BA",
|
"SwaggerPathBase": "/BA",
|
||||||
"AllowOrigins": "http://localhost,http://argo.zylweb.cn",
|
"AllowOrigins": "http://localhost,http://argo.zylweb.cn",
|
||||||
|
"Domain": null,
|
||||||
"KeyPath": "..\\keys",
|
"KeyPath": "..\\keys",
|
||||||
"ApplicationName": "__bd__",
|
"ApplicationName": "__bd__",
|
||||||
"ApplicationDiscriminator": "BootstrapAdmin",
|
"ApplicationDiscriminator": "BootstrapAdmin",
|
||||||
|
|
|
@ -60,6 +60,7 @@ namespace Bootstrap.Client
|
||||||
services.AddAuthentication(CookieAuthenticationDefaults.AuthenticationScheme).AddCookie(options =>
|
services.AddAuthentication(CookieAuthenticationDefaults.AuthenticationScheme).AddCookie(options =>
|
||||||
{
|
{
|
||||||
options.Cookie.Path = "/";
|
options.Cookie.Path = "/";
|
||||||
|
options.Cookie.Domain = Configuration["Domain"];
|
||||||
options.RebuildRedirectUri(Configuration["AuthHost"]);
|
options.RebuildRedirectUri(Configuration["AuthHost"]);
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
|
@ -32,5 +32,6 @@
|
||||||
],
|
],
|
||||||
"KeyPath": "..\\keys",
|
"KeyPath": "..\\keys",
|
||||||
"AuthHost": "http://localhost:50852",
|
"AuthHost": "http://localhost:50852",
|
||||||
"AllowOrigins": "http://localhost:50852"
|
"AllowOrigins": "http://localhost:50852",
|
||||||
|
"Domain": null
|
||||||
}
|
}
|
||||||
|
|
|
@ -30,6 +30,7 @@
|
||||||
],
|
],
|
||||||
"AppId": 2,
|
"AppId": 2,
|
||||||
"AuthHost": "http://argo.zylweb.cn/BA",
|
"AuthHost": "http://argo.zylweb.cn/BA",
|
||||||
|
"Domain": null,
|
||||||
"AllowOrigins": "http://localhost,http://argo.zylweb.cn",
|
"AllowOrigins": "http://localhost,http://argo.zylweb.cn",
|
||||||
"KeyPath": "..\\keys",
|
"KeyPath": "..\\keys",
|
||||||
"ApplicationName": "__bd__",
|
"ApplicationName": "__bd__",
|
||||||
|
|
Loading…
Reference in New Issue