autostart gacksbackend
smbaker [Tue, 22 May 2012 00:45:33 +0000 (17:45 -0700)]
rpm_builds/SPECS/gackscentral.spec.template
rpm_builds/build-gackscentral

index d9f8593..e2af3dc 100644 (file)
@@ -35,6 +35,7 @@ install -d -o 0 -g 0 %{buildroot}/etc/httpd
 install -d -o 0 -g 0 %{buildroot}/etc/httpd/conf.d
 
 install -d -o 0 -g 0 %{buildroot}/etc/cron.d
+install -d -o 0 -g 0 %{buildroot}/etc/init.d
 
 install gacks-api.conf %{buildroot}/etc/httpd/conf.d
 
@@ -50,6 +51,7 @@ install gacksaccountmanager.py %{buildroot}/usr/local/gackscentral/bin
 install gacksaccount_test.py %{buildroot}/usr/local/gackscentral/bin
 install gacksauth.py %{buildroot}/usr/local/gackscentral/bin
 install gacksreset.py %{buildroot}/usr/local/gackscentral/bin
+install gacksbackend.py %{buildroot}/usr/local/gackscentral/bin
 install gackscalendar.py %{buildroot}/usr/local/gackscentral/bin
 install gackscalendar_list.py %{buildroot}/usr/local/gackscentral/bin
 install gackscalendar_mysql.py %{buildroot}/usr/local/gackscentral/bin
@@ -79,6 +81,8 @@ install localhost-gacks-runasap.sh %{buildroot}/usr/local/gackscentral/bin
 install localhost-gacks-applyinvoices.sh %{buildroot}/usr/local/gackscentral/bin
 install gackscentral.cron %{buildroot}/etc/cron.d
 
+install gacksbackend.init %{buildroot}/etc/init.d
+
 # Geniwrapper stuff
 #install __init__.py %{buildroot}/usr/local/gackscentral/bin/sfa
 #install __init__.py %{buildroot}/usr/local/gackscentral/bin/sfa/trust
@@ -113,6 +117,9 @@ ln -sf /usr/local/gackscentral/bin/gackscli.py /usr/bin/gackscli
 # apache can't seem to write the log files
 chown -R apache /usr/local/gackscentral/var/log
 
+chkconfig gacksbackend.init on
+service gacksbackend.init restart
+
 %preun
 if [ $1 = 0 ]; then
   rm -f /usr/bin/gackscli
@@ -135,6 +142,7 @@ fi
 /usr/local/gackscentral/bin/gacksaccount_test.py
 /usr/local/gackscentral/bin/gacksauth.py
 /usr/local/gackscentral/bin/gacksreset.py
+/usr/local/gackscentral/bin/gacksbackend.py
 /usr/local/gackscentral/bin/gackscalendar.py
 /usr/local/gackscentral/bin/gackscalendar_list.py
 /usr/local/gackscentral/bin/gackscalendar_mysql.py
@@ -164,6 +172,9 @@ fi
 /usr/local/gackscentral/bin/localhost-gacks-applyinvoices.sh
 %attr(0644,root,root) /etc/cron.d/gackscentral.cron
 
+/etc/init.d/gacksbackend.init
+%attr(0755,root,root) /etc/init.d/gacksbackend.init
+
 # geniwrapper stuff
 #/usr/local/gackscentral/bin/sfa/__init__.py
 #/usr/local/gackscentral/bin/sfa/trust/__init__.py
index 4b61aeb..dd0ad95 100755 (executable)
@@ -30,6 +30,8 @@ cp $SOURCE/apps/gacks/localhost-gacks-runasap.sh $FOLDER
 cp $SOURCE/apps/gacks/localhost-gacks-applyinvoices.sh $FOLDER
 cp $SOURCE/apps/gacks/gackscentral.cron $FOLDER
 
+cp $SOURCE/apps/gacks/gacksbackend.init $FOLDER
+
 chmod +x $FOLDER/*.sh
 chmod +x $FOLDER/gackscli.py