Skip to content

Commit b23db77

Browse files
committed
Ticket ## : Add gitter + fix swagger edp
1 parent 6747f4b commit b23db77

File tree

3 files changed

+13
-4
lines changed

3 files changed

+13
-4
lines changed

README.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,7 @@ It supports most of the concepts introduced by the Case Management Model And Not
1616
[![Build status](https://ci.appveyor.com/api/projects/status/q2ra83o0rcla41oc?svg=true)](https://ci.appveyor.com/project/simpleidserver/casemanagement)
1717
[![MyGet (dev)](https://img.shields.io/myget/advance-ict/v/CaseManagement.CMMN.svg)](http://myget.org/gallery/advance-ict)
1818
[![Documentation Status](https://readthedocs.org/projects/casemanagement/badge/?version=latest)](https://casemanagement.readthedocs.io/en/latest/)
19+
[![Join the chat at https://gitter.im/simpleidserver/CaseManagement](https://badges.gitter.im/simpleidserver/CaseManagement.svg)](https://gitter.im/simpleidserver/CaseManagement?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge)
1920

2021
For project documentation, please visit [readthedocs](https://casemanagement.readthedocs.io/en/latest/).
2122

conf/casemanagement.service

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ Description=Case Management API
33
After=network.target
44

55
[Service]
6-
ExecStart=/usr/bin/dotnet /home/ftpuser/src/build/results/services/CaseManagementApi/CaseManagement.CMMN.Host.dll --server.urls="http://*:60005"
6+
ExecStart=/usr/bin/dotnet /home/ftpuser/src/build/results/services/CaseManagementApi/CaseManagement.CMMN.Host.dll --pathBase=/casemanagementapi --server.urls="http://*:60005"
77
KillMode=process
88
TimeoutStopSec=5s
99
Restart=always

src/CaseManagement.CMMN.Host/Startup.cs

Lines changed: 11 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -94,16 +94,24 @@ public void ConfigureServices(IServiceCollection services)
9494

9595
public void Configure(IApplicationBuilder app, IHostingEnvironment env, ILoggerFactory loggerFactory)
9696
{
97+
var pathBase = string.Empty;
9798
if (_configuration.GetChildren().Any(i => i.Key == "pathBase"))
9899
{
99-
app.UsePathBase(_configuration["pathBase"]);
100+
pathBase = _configuration["pathBase"];
101+
app.UsePathBase(pathBase);
100102
}
101103

102104
app.UseForwardedHeaders();
103105
app.UseSwagger();
104106
app.UseSwaggerUI(c =>
105-
{
106-
c.SwaggerEndpoint("/swagger/v1/swagger.json", "CaseManagement API V1");
107+
{
108+
var edp = "/swagger/v1/swagger.json";
109+
if (!string.IsNullOrWhiteSpace(pathBase))
110+
{
111+
edp = $"{pathBase}{edp}";
112+
}
113+
114+
c.SwaggerEndpoint(edp, "CaseManagement API V1");
107115
});
108116
app.UseAuthentication();
109117
app.UseCors("AllowAll");

0 commit comments

Comments
 (0)