优化appsetting.json配置文件

This commit is contained in:
不做码农
2022-03-03 20:55:37 +08:00
parent 9c89842ede
commit 35219931b0
2 changed files with 2 additions and 6 deletions
+1 -1
View File
@@ -30,7 +30,7 @@ namespace ZR.Admin.WebApi
public IConfiguration Configuration { get; }
public void ConfigureServices(IServiceCollection services)
{
string corsUrls = Configuration["sysConfig:cors"];
string corsUrls = Configuration["corsUrls"];
//配置跨域
services.AddCors(c =>
+1 -5
View File
@@ -13,10 +13,7 @@
"conn_zrAdmin_type": 1, //MySql = 0, SqlServer = 1
"conn_bus_type": 1,
"urls": "http://localhost:8888", //项目启动url
"sysConfig": {
"DBCommandTimeout": 10,
"cors": "http://localhost:8887" //跨域地址(前端启动项目,前后端分离单独部署需要设置),多个用","隔开
},
"corsUrls": "http://localhost:8887", //跨域地址(前端启动项目,前后端分离单独部署需要设置),多个用","隔开
"JwtSettings": {
"Issuer": "ZRAdmin.NET",
"Audience": "ZRAdmin.NET",
@@ -26,7 +23,6 @@
"DemoMode": false, //是否演示模式
"DbKey": "", //数据库加密key
"Upload": {
"UploadDirectory": "/",
"UploadUrl": "http://localhost:8888"
},
//阿里云存储配置