# HG changeset patch # User Christophe Lincoln # Date 1392579666 -3600 # Node ID 3418d10317a43f0f91b58f3065dc622b0a76d2bb # Parent 6380f08f134608df05f36d609347e8d8ce5f8724 mirror: add cmd to update website and add SHell CGI support diff -r 6380f08f1346 -r 3418d10317a4 mirror/files/etc/lighttpd/vhosts.conf --- a/mirror/files/etc/lighttpd/vhosts.conf Sun Feb 16 18:48:04 2014 +0100 +++ b/mirror/files/etc/lighttpd/vhosts.conf Sun Feb 16 20:41:06 2014 +0100 @@ -101,29 +101,18 @@ index-file.names += ( "index.php" ) } -# slitaz.org +# www.slitaz.org # -#$HTTP["host"] =~ "(^|www\.)slitaz\.(org|com|eu)$" { $HTTP["host"] =~ "^www\.slitaz\.(org|com|eu)$" { - server.document-root = "/home/slitaz/website" + server.document-root = "/home/slitaz/repos/website" server.errorlog = "/var/log/lighttpd/slitaz.org-error.log" accesslog.filename = "/var/log/lighttpd/slitaz.org-access.log" include "awstats.conf" - -### index-file.names = ( "index.html" ) -### index-file.names += ( "start.html" ) + index-file.names += ( "index.cgi" ) index-file.names += ( "index.php" ) - - -### url.rewrite-once = ( -### "^/about" => "/fr/about", -### "^/artwork" => "/fr/artwork", -### "^/devel" => "/fr/devel", -### "^/doc" => "/fr/doc", -### "^/get" => "/fr/get", -### "^/packages" => "/fr/packages" -### ) - + cgi.assign = ( + ".cgi" => "/bin/sh" + ) } # doc.slitaz.org @@ -226,16 +215,3 @@ alias.url += ( "/static" => "/var/www/slitaz/mirror/static/" ) index-file.names += ( "index.php" ) } - -# mf.slitaz.org -# -# Mirror Files serve SliTaz static files such as CSS and images -# Here we point the vhost to the Hg repo so we can update files via -# cron: hg pull -u /home/slitaz/repos/slitaz-forge -# -$HTTP["host"] =~ "^mf\.slitaz\.org$" { - server.document-root = "/home/slitaz/repos/slitaz-forge/mf" - server.errorlog = "/var/log/lighttpd/mf.slitaz.org-error.log" - accesslog.filename = "/var/log/lighttpd/mf.slitaz.org-access.log" - include "awstats.conf" -} diff -r 6380f08f1346 -r 3418d10317a4 mirror/mirror --- a/mirror/mirror Sun Feb 16 18:48:04 2014 +0100 +++ b/mirror/mirror Sun Feb 16 20:41:06 2014 +0100 @@ -13,6 +13,7 @@ INFO="$WWW/mirror-info" TINY="$WWW/pizza/tiny" BACKUPS="/home/backups" +WEBSITE="/home/slitaz/website" usage() { cat << EOT @@ -22,7 +23,8 @@ up-info Update mirror.slitaz.org/info/ web interface up-tiny Update tiny.slitaz.org/ web interface up-mirror Update mirror.slitaz.org files - up-pkgs Update pkgs.slitaz.org + up-www Update main website www.slitaz.org + up-pkgs Update pkgs.slitaz.org web interface EOT } @@ -43,6 +45,9 @@ cd $REPOS/slitaz-forge && hg pull -u echo "Copying root to: $MIRROR" cp -a mirror/root/* $MIRROR ;; + up-www) + echo "Updating: www.slitaz.org" + cd $WEBSITE && hg pull -u ;; up-pkgs) echo "Updating: pkgs.slitaz.org..." cd $REPOS/slitaz-forge && hg pull -u