* Fix sgi-cgi postinst
authorSteven Barth <steven@midlink.org>
Sun, 15 Jun 2008 20:10:20 +0000 (20:10 +0000)
committerSteven Barth <steven@midlink.org>
Sun, 15 Jun 2008 20:10:20 +0000 (20:10 +0000)
libs/sgi-cgi/ipkg/postinst

index bbc1e53812745b1e98378909afd668bd8e51a28c..d8780c2e7e7f487b4e024d1fcca302861963ce85 100755 (executable)
@@ -1,11 +1,10 @@
 #!/bin/sh
-[ -f "${IPKG_INSTROOT}/etc/httpd.conf" ] && { 
-       PATTERNS='/cgi-bin/luci/admin:root:$p$root'
+PATTERNS='/cgi-bin/luci/admin:root:$p$root'
 
-       for i in $PATTERNS
-       do
-               grep "$i" ${IPKG_INSTROOT}/etc/httpd.conf >/dev/null 2>/dev/null || echo "$i" >> ${IPKG_INSTROOT}/etc/httpd.conf
-       done 
+for i in $PATTERNS
+do
+       grep "$i" ${IPKG_INSTROOT}/etc/httpd.conf >/dev/null 2>/dev/null || echo "$i" >> ${IPKG_INSTROOT}/etc/httpd.conf
+done 
+
+[ -n "${IPKG_INSTROOT}" ] || /etc/init.d/httpd restart
 
-       [ -n "${IPKG_INSTROOT}" ] || /etc/init.d/httpd restart
-}