当应用程序部署在tomcat中时,ServletUriComponentsBuilder.fromCurrentContextPath()返回0.0.0.0:8080

时间:2019-03-05 16:28:13

标签: java spring spring-boot tomcat

我正在使用ServletUriComponentsBuilder.fromCurrentContextPath()在spring boot rest应用程序中构建下载文件的url,这在本地工作正常,但是当部署在oiur公司服务器上的tomcat服务器上时,它将返回0.0.0.0:8080,而不是实际的url < / p>

感谢您的帮助!

0 个答案:

没有答案
相关问题