fix path confusion part 2

This commit is contained in:
Wolfgang Hottgenroth 2021-12-06 13:48:34 +01:00
parent 6cbffa2b1a
commit bfcfba544e
Signed by: wn
GPG Key ID: E49AF3B9EF6DD469
2 changed files with 2 additions and 2 deletions

View File

@ -4,7 +4,7 @@ using System.IO;
using System.Threading.Tasks;
namespace ${env['packagename']}.Controllers {
[Route("/${env['routeprefix']}/openapi/JSON")]
[Route("/${env['routeprefix']}/api/openapi/JSON")]
public class OpenAPIDocCtrl : ControllerBase {
private IWebHostEnvironment _hostingEnvironment;

View File

@ -92,7 +92,7 @@ if [ "$STAGE2" = "1" ]; then
-e 's#\(using '$PACKAGE_NAME'.OpenApi;\)#\1\n\n// added by post-processor\nusing '$PACKAGE_NAME'.Services;\n#' \
-e 's#^\([[:space:]]*\)\(// Add framework services.\)#\1// added by post-processor\n\1services.AddTransient<IDbService, DbService>();\n\n\1\2#' \
-e 's#\(c.RoutePrefix = "\)openapi\(";\)#\1'$ROUTE_PREFIX'/api/doc\2#' \
-e 's#\(c.SwaggerEndpoint("\)/openapi/2.0.0/openapi.json\(", "Generic Database API Service");\)#\1'$ROUTE_PREFIX'/api/openapi/JSON\2#' \
-e 's#\(c.SwaggerEndpoint("\)/openapi/2.0.0/openapi.json\(", "Generic Database API Service");\)#\1/'$ROUTE_PREFIX'/api/openapi/JSON\2#' \
-e 's#\(c.RouteTemplate = "\)openapi/{documentName}/openapi.json\(";\)#\1'$ROUTE_PREFIX'/api/openapi/JSON\2#' \
-e 's#\(app.UseHttpsRedirection();\)#// \1#'