- 工信部备案号 滇ICP备05000110号-1
- 滇公安备案 滇53010302000111
- 增值电信业务经营许可证 B1.B2-20181647、滇B1.B2-20190004
- 云南互联网协会理事单位
- 安全联盟认证网站身份V标记
- 域名注册服务机构许可:滇D3-20230001
- 代理域名注册服务机构:新网数码
Nginx+tomcat整合安装配置
到http://www.landui.com下载JRE软件。
wget http://www.landui.com/otn-pub/java/jdk/7u2-b13/jre-7u2-linux-i586.tar.gz tar xzf jre-7u2-linux-i586.tar.gz mv jre1.7.0_02/ /usr/local/jre
到http://www.landui.com/下载tomcat
wget http://www.landui.com/apache-mirror/tomcat/tomcat-7/v7.0.23/bin/apache-tomcat-7.0.23.tar.gz tar xzf apache-tomcat-7.0.23.tar.gz mv apache-tomcat-7.0.23 /usr/local/tomcat
vi /etc/profile
在文件末尾增加:
export JRE_HOME=/usr/local/jre
执行source命令使生效
source /etc/profile
1.打开tomcat安装目录下面conf目录下的server.xml文件。
2.找到如下文字:
<Host name="localhost" appBase="webapps" unpackWARs="true" autoDeploy="true">
3.在上面找到的文字后面添加如下内容
<Context path="" docBase="/usr/local/nginx/html" debug="0" reloadable="true" />
/usr/local/nginx/html即为根目录地址。
安装nginx
yum install pcre-devel zlib-devel cd /tmp wget http://www.landui.com/download/nginx-1.0.14.tar.gz tar xzf nginx-1.0.14.tar.gz cd nginx-1.0.14 ./configure --prefix=/usr/local/nginx make && make install
在nginx.conf中的server区块中加入:
location ~ .(jsp|jspx|do){ proxy_set_header Host $host; proxy_set_header X-Forwarded-For $remote_addr; proxy_pass http://www.landui.com:8080; }
/usr/local/nginx/sbin/nginx /usr/local/tomcat/bin/startup.sh
售前咨询
售后咨询
备案咨询
二维码
TOP