wok-6.x annotate nzbget-webui/receipt @ rev 20248

Up alsa (1.1.5) again
author Pascal Bellard <pascal.bellard@slitaz.org>
date Mon Mar 12 15:28:31 2018 +0100 (2018-03-12)
parents 9911b9ad7712
children a78610b2eb47
rev   line source
pascal@17192 1 # SliTaz package receipt.
pascal@17192 2
pascal@17192 3 PACKAGE="nzbget-webui"
pascal@17192 4 VERSION="13.0"
pascal@17192 5 CATEGORY="network"
pascal@17192 6 SHORT_DESC="The most efficient usenet downloader, web user interface."
pascal@17192 7 MAINTAINER="pascal.bellard@slitaz.org"
pascal@17192 8 LICENSE="GPL2"
pascal@17192 9 WEB_SITE="http://nzbget.net/"
pascal@17192 10
pascal@17192 11 WANTED="nzbget"
pascal@17192 12 DEPENDS="nzbget"
pascal@17192 13
pascal@17192 14 # Rules to gen a SliTaz package suitable for Tazpkg.
pascal@17192 15 genpkg_rules()
pascal@17192 16 {
pascal@17192 17 mkdir -p $fs/usr/share/nzbget
pascal@17192 18 cp -a $install/usr/share/nzbget/webui $fs/usr/share/nbzget
pascal@17192 19 }
pascal@17192 20
pascal@17192 21 post_install()
pascal@17192 22 {
pascal@17192 23 # Configure lighttpd server
pascal@18730 24 if [ -f "$1/etc/lighttpd/lighttpd.conf" ]; then
pascal@18730 25 if ! grep -q /usr/share/nzbget/ "$1/etc/lighttpd/lighttpd.conf"; then
pascal@18730 26 sed -e 's|.*"/examples/" => "/usr/share/examples/",| "/examples/" => "/usr/share/examples/",\n "/nzbget/" => "/usr/share/nzbget/webui/",|g' -i "$1/etc/lighttpd/lighttpd.conf"
pascal@17192 27 if [ -z "$1" ]; then
pascal@17192 28 # Start Web server.
pascal@17192 29 /etc/init.d/lighttpd stop
pascal@17192 30 /etc/init.d/lighttpd start
pascal@17192 31 fi
pascal@17192 32 fi
pascal@17192 33 fi
pascal@17192 34 # Configure apache server
pascal@18730 35 if [ -f "$1/etc/apache/httpd.conf" ]; then
pascal@18730 36 if [ ! -f "$1/etc/apache/conf.d/nzbget" ]; then
pascal@18730 37 cat > "$1/etc/apache/conf.d/nzbget" <<EOT
pascal@17192 38 <IfModule mod_alias.c>
pascal@17192 39 Alias /nzbget /usr/share/nzbget/webui
pascal@17192 40 </IfModule>
pascal@17192 41 <Directory /usr/share/nzbget/webui/>
pascal@17192 42 DirectoryIndex index.html
pascal@17192 43 Options +FollowSymLinks
pascal@17192 44 AllowOverride None
pascal@17192 45 Order allow,deny
pascal@17192 46 Allow from all
pascal@17192 47 </Directory>
pascal@17192 48 EOT
pascal@17192 49 if [ -z "$1" ]; then
pascal@17192 50 # Start Web server.
pascal@17192 51 /etc/init.d/apache stop
pascal@17192 52 /etc/init.d/apache start
pascal@17192 53 fi
pascal@17192 54 fi
pascal@17192 55 fi
pascal@17192 56 }