tomcat.apache.org/download-90…
apache
终端输入 vim ~/.bash_profile 若是没有bash_profile则须要先建立vim
添加Tomcat环境变量配置浏览器
#tomcat配置
CATALINA_BASE=/Users/xxx/Library/apache-tomcat-9.0.8
CATALINA_HOME=/Users/xxx/Library/apache-tomcat-9.0.8
export PATH=$PATH:/Users/xxx/Library/apache-tomcat-9.0.8/bin
export CATALINA_BASE CATALINA_HOME
复制代码
须要进入Tomcat下的bin目录进行运行,即便配置了环境变量仍然会报一下错误tomcat
xxxxxx@bogon:~|⇒ sh startup.sh
Cannot find ./catalina.sh
The file is absent or does not have execute permission
This file is needed to run this program
xxxxxx@bogon:~|⇒
复制代码
终端进入/Users/xxx/Library/apache-tomcat-9.0.8/bin目录,输入sh startup.sh启动Tomcatbash
此时在浏览器中输入 http://loacalhost:8080ui
终端 xxx/bin 目录下,输入sh shutdown.sh 关闭Tomcatthis