SpringBoot集成springfox-swagger2访问页面弹窗提示问题

弹窗提示:
Unable to infer base url. This is common when using dynamic servlet registration or when the API is behind an API Gateway. The base url is the root of where all the swagger resources are served. For e.g. if the api is available at http://example.org/api/v2/api-docs then the base url is http://example.org/api/. Please enter the location manually:

在这里插入图片描述

解决方法: 启动类StartApplication上加注解@EnableSwagger2。