diff --git a/FAuth/FAuth.csproj b/FAuth/FAuth.csproj index be6e447..82a9744 100644 --- a/FAuth/FAuth.csproj +++ b/FAuth/FAuth.csproj @@ -27,4 +27,10 @@ + + + + + + diff --git a/FAuth/Startup.cs b/FAuth/Startup.cs index 16c5b25..f6ea336 100644 --- a/FAuth/Startup.cs +++ b/FAuth/Startup.cs @@ -65,13 +65,14 @@ namespace FAuth //עSwagger services.AddSwaggerGen(c => { + var option = this.Configuration.GetSection("SwaggerDoc"); c.SwaggerDoc("V1",new OpenApiInfo { - Title = "ӿĵ", - Version = "1.0", - Description = "api", + Title = option.GetValue("Title"), + Version = option.GetValue("Version"), + Description = option.GetValue("Description"), Contact = new OpenApiContact { - Name = "Falcon", - Url = new Uri("http://39.105.71.191/Falcon/FAuth"), + Name = option.GetValue("Contact:Name"), + Url = new Uri(option.GetValue("Contact:Url")), }, }); var xmlPath = Path.Combine(AppContext.BaseDirectory,typeof(Program).Assembly.GetName().Name + ".xml"); diff --git a/FAuth/appsettings.json b/FAuth/appsettings.json index 4036d5f..e170643 100644 --- a/FAuth/appsettings.json +++ b/FAuth/appsettings.json @@ -1,4 +1,4 @@ -{ +{ "Logging": { "LogLevel": { "Default": "Information", @@ -19,5 +19,14 @@ "UserTicketDecryptorOption": { "Key": "abcd" }, - "urls": "http://*:9000;https://*:9001" + "urls": "http://*:9000;https://*:9001", + "SwaggerDoc": { + "Title": "Falcon SSO 统一登录接口文档", + "Version": "1.0", + "Description": "统一采用API接口设计,查下下面详细接口规范。", + "Contact": { + "Name": "技术支持(点击链接,发布工单)", + "Url": "http://39.105.71.191/Falcon/FalconSSO/issues" + } + } }