wok view nzbget-webui/receipt @ rev 23462
updated pymux (0.6 -> 0.14)
author | Hans-G?nter Theisgen |
---|---|
date | Sat Apr 04 17:32:52 2020 +0100 (2020-04-04) |
parents | a78610b2eb47 |
children | d30dcfb0598a |
line source
1 # SliTaz package receipt.
3 PACKAGE="nzbget-webui"
4 VERSION="21.0"
5 CATEGORY="network"
6 SHORT_DESC="The most efficient usenet downloader, web user interface."
7 MAINTAINER="pascal.bellard@slitaz.org"
8 LICENSE="GPL2"
9 WEB_SITE="https://nzbget.net/"
11 DEPENDS="nzbget"
12 WANTED="nzbget"
14 # Rules to gen a SliTaz package suitable for Tazpkg.
15 genpkg_rules()
16 {
17 mkdir -p $fs/usr/share/nzbget
18 cp -a $install/usr/share/nzbget/webui $fs/usr/share/nbzget
19 }
21 post_install()
22 {
23 # Configure lighttpd server
24 if [ -f "$1/etc/lighttpd/lighttpd.conf" ]
25 then
26 if ! grep -q /usr/share/nzbget/ "$1/etc/lighttpd/lighttpd.conf"
27 then
28 sed -e 's|.*"/examples/" => "/usr/share/examples/",| "/examples/" => "/usr/share/examples/",\n "/nzbget/" => "/usr/share/nzbget/webui/",|g' -i "$1/etc/lighttpd/lighttpd.conf"
29 if [ -z "$1" ]
30 then
31 # Start Web server.
32 /etc/init.d/lighttpd stop
33 /etc/init.d/lighttpd start
34 fi
35 fi
36 fi
38 # Configure apache server
39 if [ -f "$1/etc/apache/httpd.conf" ]
40 then
41 if [ ! -f "$1/etc/apache/conf.d/nzbget" ]
42 then
43 cat > "$1/etc/apache/conf.d/nzbget" <<EOT
44 <IfModule mod_alias.c>
45 Alias /nzbget /usr/share/nzbget/webui
46 </IfModule>
47 <Directory /usr/share/nzbget/webui/>
48 DirectoryIndex index.html
49 Options +FollowSymLinks
50 AllowOverride None
51 Order allow,deny
52 Allow from all
53 </Directory>
54 EOT
55 if [ -z "$1" ]
56 then
57 # Start Web server.
58 /etc/init.d/apache stop
59 /etc/init.d/apache start
60 fi
61 fi
62 fi
63 }