Eclipse下启动tomcat报错,Cannot publish to the server because it is missing its runtime environment.

问题:在启动tomcat的时候报错:说缺少运行环境,我们用的是tomcat8.

Eclipse下启动tomcat报错,Cannot publish to the server because it is missing its runtime environment.

网上查找答案说当出现这个错误时,去eclipse-->server-->Runtime Environments中看看是不是tomcat的配置变了

Eclipse下启动tomcat报错,Cannot publish to the server because it is missing its runtime environment.

发现果然变了,于是添加tomcat8,解决。