Bug 245263

Summary: Fix rhn-java spec file
Product: [Retired] Red Hat Network Reporter: Mike Orazi <morazi>
Component: RHN/OtherAssignee: Mike Orazi <morazi>
Status: CLOSED CURRENTRELEASE QA Contact: Steve Milner <smilner>
Severity: high Docs Contact:
Priority: high    
Version: rhn500CC: rhn-bugs
Target Milestone: ---   
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: 5.0.2 Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2007-07-25 15:15:59 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On:    
Bug Blocks: 239809    

Description Mike Orazi 2007-06-21 22:33:30 UTC
Description of problem:
rhn-java spec file needs pre & postun tags to remove the exploded rhn war
directory + the tomcat work directory so that tomcat doesn't accidentally run
old versions of the application.

Tomcat5 should always clean up, but sometimes it seems to not shut down cleaning
and keep old revs around.


Version-Release number of selected component (if applicable):


How reproducible:
Ever rpm update

Steps to Reproduce:
1. Update rhn-java rpm
2. Notice /usr/share/tomcat5/webapps/rhn directory is older than
/usr/share/tomcat5/webapps/rhn.war
3.
  
Actual results:


Expected results:
Removed /usr/share/tomcat5/webapps/rhn & /usr/share/tomcat5/work/localhost/rhn

Additional info:

Comment 1 Steve Milner 2007-06-29 18:22:26 UTC
James Bowes added the following ....

+#Remove the exploded war and work directory
%pre
rm -rf /usr/share/tomcat5/webapps/rhn
rm -rf /usr/share/tomcat5/work/Catalina/localhost/rhn

+#Remove the exploded war & work directory
%postun
rm -rf /usr/share/tomcat5/webapps/rhn
rm -rf /usr/share/tomcat5/work/Catalina/localhost/rhn

Issue seems to be fixed:
[root@rhnjava webapps]# hostname
rhnjava.back-webqa.redhat.com
[root@rhnjava webapps]# ls -la | grep rhn
drwxr-xr-x  11 tomcat tomcat     4096 Jun 29 11:41 rhn
-rwxrwxr-x   1 tomcat tomcat 22827614 Jun 29 11:06 rhn.war
[root@rhnjava webapps]# 

Comment 2 James Bowes 2007-07-25 15:15:59 UTC
rhn502 released.