IIS가없는 독립 실행 형 모드에서 내 맞춤 서비스에 ServiceStack을 사용하고 있습니다.ServiceStack : 아니요 /swagger-ui/index.html
내 서비스에 대한 설명서를 /metadata
이상으로 추가하고 싶습니다. 나는의 자신감 플러그를하려고 생각했다.
내가 플러그인 명령을 내 구성에 추가 한
public override void Configure(Funq.Container container)
{
SetConfig(new EndpointHostConfig()
{
DefaultRedirectPath = "index.html",
DebugMode = true,
WriteErrorsToResponse = true,
CustomHttpHandlers =
{
{ HttpStatusCode.Unauthorized, new AuthorizationErrorHandler() },
{ HttpStatusCode.Forbidden, new AuthorizationErrorHandler() },
{ HttpStatusCode.NotFound, new AuthorizationErrorHandler() }
}
});
// For automatic generation of documentation to APIs
Plugins.Add(new SwaggerFeature());
}
기존 서비스가 계속 작동하지만,
/자신감-UI에 액세스하려고 시도 /index.html
오류를 찾을 수 없습니다. 명확하게
https://github.com/ServiceStack/ServiceStack/wiki/Swagger-API
에 문서화되어 있지 추가 단계가있다 실제로이 페이지에 자신을 설정해야합니까? 그렇다면 어떻게?
또한 swagger 플러그인을 사용하여 자체 호스팅 서비스 스택에 대한 문제가 있습니다. 제 질문을 살펴보십시오. http : // stackoverflow.com/questions/19356051/ – Nnoel