登录浏览器配置界面
编辑 Tomcat conf 下的 tomcat-users.xml 添加
<role rolename="manager-gui"/>
<user username="admin" password="123456" roles="manager-gui"/>
结果
配置多端口
编辑 Tomcat conf 下的 server.xml 添加
<Service name="Catalina1">
<Connector port="8090" protocol="HTTP/1.1" connectionTimeout="20000" redirectPort="8443" />
<Connector port="8009" protocol="AJP/1.3" redirectPort="8443" />
<Engine name="Catalina1" defaultHost="localhost">
<Realm className="org.apache.catalina.realm.LockOutRealm">
<Realm className="org.apache.catalina.realm.UserDatabaseRealm" resourceName="UserDatabase" />
</Realm>
<Host name="localhost" appBase="webapps" unpackWARs="true" autoDeploy="true">
<Context path="/" docBase="C:Program FilesApache Software FoundationTomcat 8.5webappshelloword" reloadable="true" />
</Host>
</Engine>
</Service>