packages: nexus/nexus.spec - up to 1.3.6 (1.2.1 branched as NEXUS_1_2) - de...

pawelz pawelz at pld-linux.org
Thu Sep 24 17:11:58 CEST 2009


Author: pawelz                       Date: Thu Sep 24 15:11:58 2009 GMT
Module: packages                      Tag: HEAD
---- Log message:
- up to 1.3.6 (1.2.1 branched as NEXUS_1_2)
- deployed in tomcat (no longer standalone app)
- does not work

---- Files affected:
packages/nexus:
   nexus.spec (1.7 -> 1.8) 

---- Diffs:

================================================================
Index: packages/nexus/nexus.spec
diff -u packages/nexus/nexus.spec:1.7 packages/nexus/nexus.spec:1.8
--- packages/nexus/nexus.spec:1.7	Tue Feb 10 13:45:40 2009
+++ packages/nexus/nexus.spec	Thu Sep 24 17:11:53 2009
@@ -1,37 +1,23 @@
 # $Revision$, $Date$
 
-%define	plexus_ver	1.6.4.1
-
 %include	/usr/lib/rpm/macros.java
 Summary:	Maven Repository Manager
 Name:		nexus
-Version:	1.2.1
+Version:	1.3.6
 Release:	0.1
 License:	GPL v3
 Group:		Networking/Daemons/Java
-Source0:	http://nexus.sonatype.org/downloads/%{name}-webapp-%{version}-bundle.tar.gz
-# Source0-md5:	608be3bc450b17a8529da9b604184f6f
-Source1:	%{name}.init
+Source0:	http://nexus.sonatype.org/downloads/%{name}-webapp-%{version}.war
+# Source0-md5:	1eec39a389ff86931237e00a5861bd2c
+Source1:	%{name}-context.xml
 Source2:	%{name}-plexus.properties
-Source3:	%{name}-classworlds.conf
-Source4:	%{name}-wrapper.conf
 URL:		http://nexus.sonatype.org/
 BuildRequires:	jpackage-utils
 BuildRequires:	rpm-javaprov
 BuildRequires:	rpmbuild(macros) >= 1.300
-Requires(post,preun):	/sbin/chkconfig
-Requires(postun):	/usr/sbin/groupdel
-Requires(postun):	/usr/sbin/userdel
-Requires(pre):	/bin/id
-Requires(pre):	/usr/bin/getgid
-Requires(pre):	/usr/sbin/groupadd
-Requires(pre):	/usr/sbin/useradd
-# We do need exactly 3.2.3 version (it is tagged as JSW_3_2)
-Requires:	java-service-wrapper = 3.2.3
+Requires:	group(servlet)
 Requires:	jpackage-utils
 Requires:	rc-scripts
-Provides:	group(nexus)
-Provides:	user(nexus)
 BuildArch:	noarch
 BuildRoot:	%{tmpdir}/%{name}-%{version}-root-%(id -u -n)
 
@@ -51,41 +37,17 @@
 
 %install
 rm -rf $RPM_BUILD_ROOT
-install -d $RPM_BUILD_ROOT{/etc/{rc.d/init.d,sysconfig},%{_javadir},%{_datadir},%{_sharedstatedir}/nexus/conf,/var/run/nexus}
-
-install %SOURCE1 $RPM_BUILD_ROOT/etc/rc.d/init.d/nexus
-install %SOURCE2 $RPM_BUILD_ROOT%{_sharedstatedir}/nexus/conf/plexus.properties
-install %SOURCE3 $RPM_BUILD_ROOT%{_sharedstatedir}/nexus/conf/classworlds.conf
-install %SOURCE4 $RPM_BUILD_ROOT%{_sharedstatedir}/nexus/conf/wrapper.conf
-install %{name}-webapp-%{version}/conf/plexus.xml $RPM_BUILD_ROOT%{_sharedstatedir}/nexus/conf/plexus.xml
-
-cp -a %{name}-webapp-%{version}/lib/plexus-platform-jsw-%{plexus_ver}.jar $RPM_BUILD_ROOT%{_javadir}/plexus-platform-jsw-%{plexus_ver}.jar
-ln -s plexus-platform-jsw-%{plexus_ver}.jar $RPM_BUILD_ROOT%{_javadir}/plexus-platform-jsw.jar
-
-cp -a %{name}-webapp-%{version}/runtime/apps/nexus $RPM_BUILD_ROOT%{_datadir}/nexus
-
-ln -s %{_sharedstatedir}/nexus/conf $RPM_BUILD_ROOT%{_sysconfdir}/nexus
-
-%pre
-%groupadd -g 201 nexus
-%useradd -u 201 -d %{_sharedstatedir}/nexus -s /bin/false -c "nexus user" -g nexus nexus
-
-%post
-/sbin/chkconfig --add nexus
-%service nexus restart "nexus daemon"
-
-%preun
-if [ "$1" = "0" ]; then
-	%service nexus stop
-	/sbin/chkconfig --del nexus
-fi
-
-%postun
-if [ "$1" = "0" ]; then
-	%userremove nexus
-	%groupremove nexus
-fi
 
+install -d $RPM_BUILD_ROOT{%{_sysconfdir}/nexus,%{_datadir}/nexus,%{_sharedstatedir}/{nexus,tomcat/conf/Catalina/localhost}}
+#install %{SOURCE1} $RPM_BUILD_ROOT%{_sysconfdir}/nexus/web.xml
+install %{SOURCE1} $RPM_BUILD_ROOT%{_sharedstatedir}/tomcat/conf/Catalina/localhost/nexus.xml
+install %{SOURCE2} $RPM_BUILD_ROOT%{_sysconfdir}/nexus/plexus.properties
+
+cp -a . $RPM_BUILD_ROOT%{_datadir}/nexus
+
+mv $RPM_BUILD_ROOT%{_datadir}/nexus/WEB-INF/web.xml $RPM_BUILD_ROOT%{_sysconfdir}/nexus/web.xml
+ln -sf %{_datadir}/nexus/WEB-INF/web.xml $RPM_BUILD_ROOT%{_sysconfdir}/nexus/web.xml
+ln -sf %{_datadir}/nexus/WEB-INF/plexus.properties $RPM_BUILD_ROOT%{_sysconfdir}/nexus/plexus.properties
 
 %clean
 rm -rf $RPM_BUILD_ROOT
@@ -93,22 +55,13 @@
 %files
 %defattr(644,root,root,755)
 
-%attr(754,root,root) /etc/rc.d/init.d/nexus
-
-%{_sysconfdir}/nexus
+%attr(770,root,servlet) %{_datadir}/nexus
+%attr(770,root,servlet) %{_sharedstatedir}/nexus
 
-%{_javadir}/plexus-platform-jsw-%{plexus_ver}.jar
-%{_javadir}/plexus-platform-jsw.jar
-
-%{_datadir}/nexus
-
-%attr(770,nexus,nexus) %dir %{_sharedstatedir}/nexus
-%attr(770,nexus,nexus) %dir %{_sharedstatedir}/nexus/conf
-%attr(660,nexus,nexus) %config(noreplace) %verify(not md5 mtime size) %{_sharedstatedir}/nexus/conf/plexus.properties
-%attr(660,nexus,nexus) %config(noreplace) %verify(not md5 mtime size) %{_sharedstatedir}/nexus/conf/plexus.xml
-%attr(660,nexus,nexus) %config(noreplace) %verify(not md5 mtime size) %{_sharedstatedir}/nexus/conf/classworlds.conf
-%attr(660,nexus,nexus) %config(noreplace) %verify(not md5 mtime size) %{_sharedstatedir}/nexus/conf/wrapper.conf
-%attr(775,nexus,nexus) %dir /var/run/nexus
+%dir %{_sysconfdir}/nexus
+%attr(660,root,servlet) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/nexus/plexus.properties
+%attr(660,root,servlet) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/nexus/web.xml
+%attr(660,root,servlet) %config(noreplace) %verify(not md5 mtime size) %{_sharedstatedir}/tomcat/conf/Catalina/localhost/nexus.xml
 
 %define date	%(echo `LC_ALL="C" date +"%a %b %d %Y"`)
 %changelog
@@ -116,6 +69,11 @@
 All persons listed below can be reached at <cvs_login>@pld-linux.org
 
 $Log$
+Revision 1.8  2009/09/24 15:11:53  pawelz
+- up to 1.3.6 (1.2.1 branched as NEXUS_1_2)
+- deployed in tomcat (no longer standalone app)
+- does not work
+
 Revision 1.7  2009/02/10 12:45:40  pawelz
 - up to 1.2.1
 
================================================================

---- CVS-web:
    http://cvs.pld-linux.org/cgi-bin/cvsweb.cgi/packages/nexus/nexus.spec?r1=1.7&r2=1.8&f=u



More information about the pld-cvs-commit mailing list