]> git.pld-linux.org Git - packages/apache-tomcat.git/commitdiff
- install directories writable for tomcat into /var/lib
authorpawelz <pawelz@pld-linux.org>
Fri, 23 Jan 2009 20:16:11 +0000 (20:16 +0000)
committercvs2git <feedback@pld-linux.org>
Sun, 24 Jun 2012 12:13:13 +0000 (12:13 +0000)
- now /etc/tomcat and /usr/share/tomcat are ro

Changed files:
    apache-tomcat.spec -> 1.67

apache-tomcat.spec

index 8e90c765986a7285c5219bae4de9ae5f230d1e69..8ddfd885d8b6d63193231c00fbaeb87244edd2c4 100644 (file)
@@ -14,7 +14,6 @@ Group:                Development/Languages/Java
 Source0:       http://www.apache.org/dist/tomcat/tomcat-5/v%{version}/src/%{name}-%{version}-src.tar.gz
 # Source0-md5: eb3f196013550b9b1684e4ff18593a8e
 Source1:       %{name}.init
-Source2:       %{name}.sysconfig
 Patch0:                %{name}-skip-servletapi.patch
 Patch1:                %{name}-nsis.patch
 Patch2:                %{name}-native.patch
@@ -237,15 +236,15 @@ install -d $TOMCATDIR/bin \
            $TOMCATDIR/common/{lib,classes,endorsed} \
            $TOMCATDIR/server/{lib,classes} \
            $TOMCATDIR/webapps \
-           $RPM_BUILD_ROOT%{_sysconfdir} \
            $RPM_BUILD_ROOT%{_logdir}/tomcat \
+           $RPM_BUILD_ROOT%{_vardir}/webapps \
            $RPM_BUILD_ROOT%{_vardir}/work \
+           $RPM_BUILD_ROOT%{_vardir}/conf \
            $RPM_BUILD_ROOT/etc/rc.d/init.d
 
 install %{SOURCE1} $RPM_BUILD_ROOT/etc/rc.d/init.d/tomcat
-install %{SOURCE2} $RPM_BUILD_ROOT/etc/sysconfig/tomcat
 
-cp -pR conf/* $RPM_BUILD_ROOT%{_sysconfdir}
+cp -pR conf/* $CATALINADIR/conf
 cp -HR bin common server $TOMCATDIR
 
 cp -rf server/webapps $TOMCATDIR/server
@@ -253,9 +252,10 @@ cp -rf webapps $TOMCATDIR
 cp -rf shared $TOMCATDIR
 cp -rf temp $TOMCATDIR
 
-ln -sf %{_logdir}/tomcat $TOMCATDIR/logs
+ln -sf %{_logdir}/tomcat $CATALINADIR/logs
 ln -sf %{_vardir}/work $TOMCATDIR/work
-ln -sf %{_sysconfdir} $TOMCATDIR/conf
+ln -sf %{_vardir}/conf $TOMCATDIR/conf
+ln -sf %{_vardir}/conf $RPM_BUILD_ROOT%{_sysconfdir}
 
 # symlinks instead of copies
 ln -sf $(find-jar commons-el) $TOMCATDIR/common/lib/commons-el.jar
@@ -329,11 +329,10 @@ fi
 %files
 %defattr(644,root,root,755)
 %doc build/{RELEASE-NOTES,RUNNING.txt}
-# tomcat wants to regenerate tomcat-users.xml
-%dir %attr(775,root,http) %{_sysconfdir}
-%config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/*
 %attr(754,root,root) /etc/rc.d/init.d/tomcat
+%{_sysconfdir}
 %dir %{_tomcatdir}
+%dir %{_tomcatdir}/conf
 %dir %{_tomcatdir}/bin
 %{_tomcatdir}/bin/catalina-tasks.xml
 %{_tomcatdir}/bin/jkstatus-tasks.xml
@@ -350,7 +349,6 @@ fi
 %lang(fr) %{_tomcatdir}/common/i18n/tomcat-i18n-fr.jar
 %lang(ja) %{_tomcatdir}/common/i18n/tomcat-i18n-ja.jar
 %{_tomcatdir}/common/lib
-%{_tomcatdir}/conf
 %{_tomcatdir}/logs
 %dir %{_tomcatdir}/server
 %dir %{_tomcatdir}/server/classes
@@ -361,7 +359,11 @@ fi
 %{_tomcatdir}/shared
 %{_tomcatdir}/temp
 %dir %{_vardir}
+# tomcat config has to be writeable because of tomacta-users.xml file and
+# Catalina dir
+%config(noreplace) %attr(775,root,http) %verify(not md5 mtime size) %{_vardir}/conf
 %dir %attr(1730,root,http) %{_vardir}/work
+%dir %attr(1730,root,http) %{_vardir}/webapps
 %dir %attr(1730,root,http) %{_logdir}/tomcat
 
 %if 0
This page took 0.086673 seconds and 4 git commands to generate.