wok annotate ajaxterm/receipt @ rev 20761
updated cairo again
author | Hans-G?nter Theisgen |
---|---|
date | Tue Feb 12 17:49:17 2019 +0100 (2019-02-12) |
parents | 11b5e93cb5f2 |
children | aaa3fcf79cf3 |
rev | line source |
---|---|
pascal@1951 | 1 # SliTaz package receipt. |
pascal@1951 | 2 |
pascal@1951 | 3 PACKAGE="ajaxterm" |
pascal@1951 | 4 VERSION="0.10" |
pascal@1951 | 5 CATEGORY="network" |
pascal@1951 | 6 SHORT_DESC="Login terminal for the web." |
pascal@1951 | 7 MAINTAINER="pascal.bellard@slitaz.org" |
pascal@15201 | 8 LICENSE="PublicDomain LGPL" |
al@14789 | 9 WEB_SITE="http://antony.lesuisse.org/software/ajaxterm/" |
pascal@1951 | 10 SOURCE="Ajaxterm" |
pascal@1951 | 11 TARBALL="$SOURCE-$VERSION.tar.gz" |
pascal@1952 | 12 WGET_URL="${WEB_SITE}files/$TARBALL" |
al@14789 | 13 TAGS="web application" |
al@14789 | 14 |
pascal@1951 | 15 DEPENDS="python" |
pascal@1951 | 16 SUGGESTED="apache lighttpd-ssl lighttpd-modules" |
pascal@1951 | 17 |
al@19278 | 18 # Rules to configure and make the package. |
al@19278 | 19 compile_rules() |
al@19278 | 20 { |
al@19278 | 21 cook_pick_manpages $src/ajaxterm.1 |
al@19278 | 22 } |
al@19278 | 23 |
pascal@1951 | 24 # Rules to gen a SliTaz package suitable for Tazpkg. |
pascal@1951 | 25 genpkg_rules() |
pascal@1951 | 26 { |
pascal@1951 | 27 mkdir -p $fs/usr/share/ajaxterm |
pascal@1951 | 28 cp -a $src/*.py $src/*.js $src/*.css $src/*.html $fs/usr/share/ajaxterm |
pankso@9697 | 29 cp -a $stuff/* $fs/ |
al@14789 | 30 chown -R root:root $fs |
al@14789 | 31 find $fs -type f -name '*.py' -exec chmod a+x \{\} \; |
pascal@1951 | 32 } |
pascal@1951 | 33 |
pascal@1951 | 34 post_install() |
pascal@1951 | 35 { |
pascal@18730 | 36 grep ^RUN_DAEMONS "$1/etc/rcS.conf" | grep -q "ajaxterm" || sed -i \ |
pascal@18730 | 37 's/RUN_DAEMONS="/RUN_DAEMONS="ajaxterm /' "$1/etc/rcS.conf" |
pascal@1951 | 38 # Configure lighttpd server |
pascal@18730 | 39 if [ -f "$1/usr/lib/lighttpd/mod_proxy.so" ]; then |
pascal@18730 | 40 grep -q mod_proxy "$1/etc/lighttpd/lighttpd.conf" || |
pascal@18730 | 41 cat >> "$1/etc/lighttpd/lighttpd.conf" <<EOT |
pascal@1951 | 42 server.modules += ( "mod_proxy" ) |
pascal@1951 | 43 EOT |
pascal@18730 | 44 grep -q ajaxterm "$1/etc/lighttpd/lighttpd.conf" || |
pascal@18730 | 45 cat >> "$1/etc/lighttpd/lighttpd.conf" <<EOT |
pascal@1951 | 46 proxy.server = ( "/ajaxterm/" => |
pascal@1951 | 47 ( ( "host" => "127.0.0.1", "port" => 8022 ) ) |
pascal@1951 | 48 ) |
pascal@1951 | 49 EOT |
pascal@1951 | 50 if [ -z "$1" ]; then |
pascal@1951 | 51 # Start Web server. |
pascal@1951 | 52 /etc/init.d/lighttpd stop |
pascal@1951 | 53 /etc/init.d/lighttpd start |
pascal@1951 | 54 fi |
pascal@1951 | 55 fi |
pascal@1951 | 56 # Configure apache server |
pascal@18730 | 57 if [ -f "$1/etc/apache/httpd.conf" ]; then |
pascal@18730 | 58 if [ ! -f "$1/etc/apache/conf.d/ajaxterm" ]; then |
pascal@18730 | 59 cat > "$1/etc/apache/conf.d/ajaxterm" <<EOT |
pascal@1951 | 60 <IfModule mod_proxy.c> |
pascal@1951 | 61 ProxyRequests Off |
pascal@1951 | 62 <Proxy *> |
pascal@1951 | 63 Order deny,allow |
pascal@1951 | 64 Allow from all |
pascal@1951 | 65 </Proxy> |
pascal@1951 | 66 ProxyPass /ajaxterm/ http://localhost:8022/ |
pascal@1951 | 67 ProxyPassReverse /ajaxterm/ http://localhost:8022/ |
pascal@1951 | 68 </IfModule> |
pascal@1951 | 69 EOT |
pascal@1951 | 70 if [ -z "$1" ]; then |
pascal@1951 | 71 # Start Web server. |
pascal@1951 | 72 /etc/init.d/apache stop |
pascal@1951 | 73 sleep 2 |
pascal@1951 | 74 /etc/init.d/apache start |
pascal@1951 | 75 fi |
pascal@1951 | 76 fi |
pascal@1951 | 77 fi |
pascal@1951 | 78 [ -z "$1" ] && /etc/init.d/ajaxterm start |
pascal@18730 | 79 [ ! -f "$1/usr/lib/lighttpd/mod_proxy.so" -a \ |
pascal@18730 | 80 ! -f "$1/etc/apache/httpd.conf" ] && |
al@18667 | 81 [ -z "$quiet" ] && cat <<EOT |
pascal@1951 | 82 -------- |
pascal@1951 | 83 You should install either lighttpd |
pascal@1951 | 84 # tazpkg get-install lighttpd-ssl ; tazpkg get-install lighttpd-modules |
pascal@1951 | 85 or apache |
pascal@1951 | 86 # tazpkg get-install apache |
pascal@1951 | 87 and reconfigure |
pascal@1951 | 88 # tazpkg reconfigure ajaxterm |
pascal@1951 | 89 -------- |
pascal@1951 | 90 EOT |
pascal@1951 | 91 } |