在resources中加入application.properties文件,里面加入 servier.port = 端口号 访问的时候,就用localhost:端口号 完事 转载于:https://www.cnblogs.com/gudulijia/p/6733840.html