urlrewritefilter 4.0.3を設定しようとしていますが、指示を理解して正しい方法で設定していません。 私は/opt/apache-tomcat-7.0.64/の下に、以下の設定でインストールapacheの-のtomcat-7.0.64を使用しています:urlrewritefilter tomcat 7.0.64用tuckey設定
CATALINA_BASEを使う:/opt/apache-tomcat-7.0.64 使い方CATALINA_HOME:/opt/apache-tomcat-7.0.64 CATALINA_TMPDIRの使用:/opt/apache-tomcat-7.0.64/temp JRE_HOMEの使用:/opt/jdk1.7.0_80/jre CLASSPATHの使用:/ opt/apache- Tomcatの-7.0.64/binに/ bootstrap.jar:/opt/apache-tomcat-7.0.64/bin/tomcat-juli.jar
私は以下のような構成を設定している:
urlrewritefilter-4.0.3.jar under folder /opt/apache-tomcat-7.0.64/lib
web.xml and urlrewrite.xml files under /opt/apache-tomcat-7.0.64/webapps/ROOT/WEB-INF
configuration for these files are:
web.xml content ini
<?xml version="1.0" encoding="ISO-8859-1"?>
<!--
Licensed to the Apache Software Foundation (ASF) under one or more
contributor license agreements. See the NOTICE file distributed with
this work for additional information regarding copyright ownership.
The ASF licenses this file to You under the Apache License, Version 2.0
(the "License"); you may not use this file except in compliance with
the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
-->
<web-app xmlns="http://java.sun.com/xml/ns/javaee"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://java.sun.com/xml/ns/javaee
http://java.sun.com/xml/ns/javaee/web-app_3_0.xsd"
version="3.0"
metadata-complete="true">
<filter>
<filter-name>UrlRewriteFilter</filter-name>
<filter-class>org.tuckey.web.filters.urlrewrite.UrlRewriteFilter</filter-class>
<!-- set the amount of seconds the conf file will be checked for reload
can be a valid integer (0 denotes check every time,
empty/not set denotes no reload check) -->
<init-param>
<param-name>confReloadCheckInterval</param-name>
<param-value>0</param-value>
</init-param>
</filter>
<filter-mapping>
<filter-name>UrlRewriteFilter</filter-name>
<url-pattern>/*</url-pattern>
<dispatcher>REQUEST</dispatcher>
<dispatcher>FORWARD</dispatcher>
</filter-mapping>
</web-app>
web.xml content end
******************************
urlrewrite.xml content ini
<?xml version="1.0" encoding="utf-8"?>
<!DOCTYPE urlrewrite
PUBLIC "-//tuckey.org//DTD UrlRewrite 3.0//EN"
"http://www.tuckey.org/res/dtds/urlrewrite3.0.dtd">
<!--
UrlRewriteFilter from http://tuckey.org/urlrewrite/ proyect
-->
<urlrewrite>
<rule>
<name>redirect</name>
<condition name="host" operator="notequal">^www.tucarne.com</condition>
<from>^/(.*)</from>
<to type="permanent-redirect" last="true">http://www.tucarne.com/$1</to>
</rule>
</urlrewrite>
urlrewrite.xml content end
マニュアルとFAQから取得するwebとurlrewriteファイルは、適切なパスと正しいcontainstで設定されていますが、動作しません。なぜ間違っているのか分かりません。
この時点で私を助けることができますか?
ありがとうございます。