slitaz-modular rev 171

initramfs: Update local-mirror script and lighttpd config files. Support new /lib/libtaz.sh script.
author Christopher Rogers <slaxemulator@gmail.com>
date Tue Apr 24 18:55:39 2012 +0000 (2012-04-24)
parents 0c446964a0d0
children b227f5995c89
files initramfs/etc/lighttpd/vhosts-local-mirror.conf initramfs/etc/lighttpd/vhosts-local-tank.conf initramfs/etc/lighttpd/vhosts-tank.conf initramfs/etc/local-mirror.conf initramfs/usr/bin/local-mirror initramfs/usr/bin/makegraphs initramfs/usr/bin/slitaz-modular
line diff
     1.1 --- a/initramfs/etc/lighttpd/vhosts-local-mirror.conf	Sun Mar 04 01:55:59 2012 -0500
     1.2 +++ b/initramfs/etc/lighttpd/vhosts-local-mirror.conf	Tue Apr 24 18:55:39 2012 +0000
     1.3 @@ -2,7 +2,7 @@
     1.4  # mirror.slitaz.org (Server canonical hostname)
     1.5  #
     1.6  $HTTP["host"] =~ "^mirror([0-9]*)\.slitaz\.org$" {
     1.7 -  server.document-root = "/home/slitaz/www/slitaz/mirror"
     1.8 +  server.document-root = "/home/slitaz/www/mirror"
     1.9    server.errorlog = "/var/log/lighttpd/mirror.slitaz.org-error.log"
    1.10    accesslog.filename = "/var/log/lighttpd/mirror.slitaz.org-access.log"
    1.11    
    1.12 @@ -31,10 +31,15 @@
    1.13  
    1.14    alias.url += ( "/webboot" => "/home/slitaz/www/boot/" )
    1.15  
    1.16 +  alias.url += ( "/usbkey" => "/home/slitaz/www/usbkey/")
    1.17 +
    1.18 +  alias.url += ( "/roadmap" => "/home/slitaz/www/roadmap/")
    1.19 +
    1.20    alias.url += ( "/pkgs" => "/home/slitaz/www/pkgs/" )
    1.21 -  index-file.names += ( "search.cgi" )
    1.22 +  index-file.names += ( "search.sh" )
    1.23    cgi.assign += (
    1.24 -    ".cgi" => "/bin/sh"
    1.25 +    ".cgi" => "/bin/sh",
    1.26 +    ".sh" => "/bin/sh"
    1.27    )
    1.28  
    1.29    alias.url += ( "/hg" => "/home/slitaz/www/hg/" )
     2.1 --- a/initramfs/etc/lighttpd/vhosts-local-tank.conf	Sun Mar 04 01:55:59 2012 -0500
     2.2 +++ b/initramfs/etc/lighttpd/vhosts-local-tank.conf	Tue Apr 24 18:55:39 2012 +0000
     2.3 @@ -35,15 +35,12 @@
     2.4  
     2.5  # pro.slitaz.org
     2.6  #
     2.7 -$HTTP["host"] =~ "pro\.slitaz\.org$" {
     2.8 +$HTTP["host"] =~ "(slitaz\.pro$|pro\.slitaz\.org$)" {
     2.9    server.document-root = "/home/slitaz/www/pro"
    2.10    server.errorlog = "/var/log/lighttpd/pro.slitaz.org-error.log"
    2.11    accesslog.filename = "/var/log/lighttpd/pro.slitaz.org-access.log"
    2.12 -  url.rewrite-final = (
    2.13 -    "^/system/test/(.*)$" => "/index.php?q=system/test/$1",
    2.14 -    "^/([^.?]*)\?(.*)$" => "/index.php?q=$1&$2",
    2.15 -    "^/([^.?]*)$" => "/index.php?q=$1",
    2.16 -    "^/rss.xml" => "/index.php?q=rss.xml"
    2.17 +  cgi.assign = (
    2.18 +    ".cgi" => "/bin/sh"
    2.19    )
    2.20  }
    2.21  
    2.22 @@ -75,8 +72,9 @@
    2.23    server.errorlog = "/var/log/lighttpd/pkgs.slitaz.org-error.log"
    2.24    accesslog.filename = "/var/log/lighttpd/pkgs.slitaz.org-access.log"
    2.25    cgi.assign = (
    2.26 -    ".cgi" => "/bin/sh"
    2.27 +    ".sh" => "/bin/sh"
    2.28    )
    2.29 +  index-file.names += ( "search.sh" )
    2.30  }
    2.31  
    2.32  # bb.slitaz.org (Build Bot)
    2.33 @@ -153,24 +151,41 @@
    2.34      )
    2.35  }
    2.36  
    2.37 +# roadmap.slitaz.org
    2.38 +#
    2.39 +$HTTP["host"] =~ "roadmap\.slitaz\.org$" {
    2.40 +  server.document-root = "/home/slitaz/www/roadmap"
    2.41 +  server.errorlog = "/var/log/lighttpd/roadmap.slitaz.org-error.log"
    2.42 +  accesslog.filename = "/var/log/lighttpd/roadmap.slitaz.org-access.log"
    2.43 +  cgi.assign = (
    2.44 +    ".cgi" => "/bin/sh"
    2.45 +  )
    2.46 +  index-file.names = ( "roadmap.cgi" )
    2.47 +}
    2.48 +
    2.49  # bugs.slitaz.org
    2.50  #
    2.51 -$HTTP["host"] =~ "bugs\.slitaz\.org$" {
    2.52 -  #cgi.assign = (
    2.53 -  #  ".cgi" => "/usr/bin/python"
    2.54 -  #)
    2.55 -  #server.document-root = "/home/slitaz/www/bugs"
    2.56 -  #url.rewrite-once = ( "(.*)" => "/roundup.cgi$1" )
    2.57 +$HTTP["host"] =~ "^bugs\.slitaz\.org$" {
    2.58 +  server.document-root = "/home/slitaz/www/bugs"
    2.59    server.errorlog = "/var/log/lighttpd/bugs.slitaz.org-error.log"
    2.60    accesslog.filename = "/var/log/lighttpd/bugs.slitaz.org-access.log"
    2.61 -  #url.rewrite = ( "(.*)" => "/bugs$1" )
    2.62 -  proxy.server = ( "" => ((
    2.63 -      "host" => "127.0.0.1",
    2.64 -      "port" => "8917"
    2.65 -    ))
    2.66 +  index-file.names = ( "bugs.cgi" )
    2.67 +  cgi.assign = (
    2.68 +    ".cgi" => "/bin/sh"
    2.69    )
    2.70  }
    2.71  
    2.72 +# try.slitaz.org (For testing)
    2.73 +#
    2.74 +$HTTP["host"] =~ "(try\.slitaz\.org$)" {
    2.75 +  server.document-root = "/home/slitaz/www/try"
    2.76 +  server.errorlog = "/var/log/lighttpd/try.slitaz.org-error.log"
    2.77 +  accesslog.filename = "/var/log/lighttpd/try.slitaz.org-access.log"
    2.78 +  cgi.assign = (
    2.79 +    ".cgi" => "/bin/sh"
    2.80 +  )
    2.81 +  #index-file.names = ( "index.cgi" )
    2.82 +}
    2.83  
    2.84  # cloud.slitaz.org
    2.85  #
     3.1 --- a/initramfs/etc/lighttpd/vhosts-tank.conf	Sun Mar 04 01:55:59 2012 -0500
     3.2 +++ b/initramfs/etc/lighttpd/vhosts-tank.conf	Tue Apr 24 18:55:39 2012 +0000
     3.3 @@ -1,15 +1,6 @@
     3.4  # /etc/lighttpd/vhosts.conf : Virtual hosts configuration file.
     3.5  #
     3.6  
     3.7 -# Nice url's for Drupal
     3.8 -#
     3.9 -#url.rewrite-final = (
    3.10 -#  "^/system/test/(.*)$" => "/index.php?q=system/test/$1",
    3.11 -#  "^/([^.?]*)\?(.*)$" => "/index.php?q=$1&$2",
    3.12 -#  "^/([^.?]*)$" => "/index.php?q=$1",
    3.13 -#   "^/rss.xml" => "/index.php?q=rss.xml"
    3.14 -#  )
    3.15 -
    3.16  # tank.slitaz.org (Server canonical hostname)
    3.17  #
    3.18  $HTTP["host"] =~ "tank\.slitaz\.org$" {
    3.19 @@ -20,31 +11,25 @@
    3.20    index-file.names += ( "index.php" )
    3.21  }
    3.22  
    3.23 -# slitaz.org
    3.24 +# pro.slitaz.org
    3.25  #
    3.26 -$HTTP["host"] =~ "(^|www\.)slitaz\.org$" {
    3.27 -  server.document-root = "/home/slitaz/www/website"
    3.28 -  server.errorlog = "/var/log/lighttpd/slitaz.org-error.log"
    3.29 -  accesslog.filename = "/var/log/lighttpd/slitaz.org-access.log"
    3.30 -  
    3.31 -  include "awstats.conf"
    3.32 -  index-file.names += ( "index.cgi", "index.php", "index.html" )
    3.33 +$HTTP["host"] =~ "(slitaz\.pro$|pro\.slitaz\.org$)" {
    3.34 +  server.document-root = "/home/slitaz/www/pro"
    3.35 +  server.errorlog = "/var/log/lighttpd/pro.slitaz.org-error.log"
    3.36 +  accesslog.filename = "/var/log/lighttpd/pro.slitaz.org-access.log"
    3.37    cgi.assign = (
    3.38      ".cgi" => "/bin/sh"
    3.39    )
    3.40  }
    3.41  
    3.42 -# pro.slitaz.org
    3.43 +# boot.slitaz.org
    3.44  #
    3.45 -$HTTP["host"] =~ "pro\.slitaz\.org$" {
    3.46 -  server.document-root = "/home/slitaz/www/pro"
    3.47 -  server.errorlog = "/var/log/lighttpd/pro.slitaz.org-error.log"
    3.48 -  accesslog.filename = "/var/log/lighttpd/pro.slitaz.org-access.log"
    3.49 -  url.rewrite-final = (
    3.50 -    "^/system/test/(.*)$" => "/index.php?q=system/test/$1",
    3.51 -    "^/([^.?]*)\?(.*)$" => "/index.php?q=$1&$2",
    3.52 -    "^/([^.?]*)$" => "/index.php?q=$1",
    3.53 -    "^/rss.xml" => "/index.php?q=rss.xml"
    3.54 +$HTTP["host"] =~ "boot\.slitaz\.org$" {
    3.55 +  server.document-root = "/home/slitaz/www/boot"
    3.56 +  server.errorlog = "/var/log/lighttpd/boot.slitaz.org-error.log"
    3.57 +  accesslog.filename = "/var/log/lighttpd/boot.slitaz.org-access.log"
    3.58 +  cgi.assign = (
    3.59 +    ".cgi" => "/bin/sh"
    3.60    )
    3.61  }
    3.62  
    3.63 @@ -54,18 +39,10 @@
    3.64    userdir.path = "Public"
    3.65    userdir.exclude-user = ("root")
    3.66    server.document-root = "/home/slitaz/www/people"
    3.67 -  server.errorlog = "/var/log/lighttpd/people.slitaz.org-error.log"
    3.68 +  server.errorlog = "/var/log/lighttpd/people.slitaz.org-erro.log"
    3.69    accesslog.filename = "/var/log/lighttpd/people.slitaz.org-access.log"
    3.70  }
    3.71  
    3.72 -# boot.slitaz.org
    3.73 -#
    3.74 -$HTTP["host"] =~ "boot\.slitaz\.org$" {
    3.75 -  server.document-root = "/home/slitaz/www/boot"
    3.76 -  server.errorlog = "/var/log/lighttpd/boot.slitaz.org-error.log"
    3.77 -  accesslog.filename = "/var/log/lighttpd/boot.slitaz.org-access.log"
    3.78 -}
    3.79 -
    3.80  # pkgs.slitaz.org
    3.81  #
    3.82  $HTTP["host"] =~ "pkgs\.slitaz\.org$" {
    3.83 @@ -77,156 +54,70 @@
    3.84    )
    3.85  }
    3.86  
    3.87 -# bb.slitaz.org (Build Bot)
    3.88 +# cook.slitaz.org
    3.89  #
    3.90 -$HTTP["host"] =~ "bb\.slitaz\.org$" {
    3.91 -  server.document-root = "/home/slitaz/www/bb"
    3.92 -  server.errorlog = "/var/log/lighttpd/bb.slitaz.org-error.log"
    3.93 -  accesslog.filename = "/var/log/lighttpd/bb.slitaz.org-access.log"
    3.94 +$HTTP["host"] =~ "cook\.slitaz\.org$" {
    3.95 +  server.document-root = "/home/slitaz/www/cook"
    3.96 +  server.errorlog = "/var/log/lighttpd/cook.slitaz.org-error.log"
    3.97 +  accesslog.filename = "/var/log/lighttpd/cook.slitaz.org-access.log"
    3.98 +  cgi.assign = (
    3.99 +    ".cgi" => "/bin/sh"
   3.100 +  )
   3.101 +  index-file.names = ( "cooker.cgi" )
   3.102  }
   3.103  
   3.104 -# hg.slitaz.org (Mercurial repos)
   3.105 +# slitaz.me
   3.106  #
   3.107 -$HTTP["host"] =~ "hg\.slitaz\.org" {
   3.108 -  cgi.assign = (
   3.109 -    ".cgi" => "/usr/bin/python"
   3.110 -  )
   3.111 -  server.document-root = "/home/slitaz/www/hg"
   3.112 -  url.rewrite-once = ( "(.*)" => "/hgwebdir.cgi$1" )
   3.113 -  auth.backend = "plain"
   3.114 -  auth.backend.plain.userfile = "/etc/lighttpd/plain.passwd"
   3.115 -  $HTTP["querystring"] =~ "cmd=unmundle" {
   3.116 -    auth.require = ( "/" => (
   3.117 -      "method" => "basic",
   3.118 -      "realm" => "SliTaz Mercurial repositories protected area",
   3.119 -      "require" => "valid-user"
   3.120 -      )
   3.121 -    )
   3.122 -  }
   3.123 +$HTTP["host"] =~ "slitaz\.me$" {
   3.124 +  server.document-root = "/home/slitaz/www/me"
   3.125 +  server.errorlog = "/var/log/lighttpd/slitaz.me-error.log"
   3.126 +  accesslog.filename = "/var/log/lighttpd/slitaz.me-access.log"
   3.127  }
   3.128  
   3.129 -# repos.slitaz.org (Mercurial repos with auth and write access)
   3.130 +# roadmap.slitaz.org
   3.131  #
   3.132 -$HTTP["host"] =~ "repos\.slitaz\.org" {
   3.133 +$HTTP["host"] =~ "roadmap\.slitaz\.org$" {
   3.134 +  server.document-root = "/home/slitaz/www/roadmap"
   3.135 +  server.errorlog = "/var/log/lighttpd/roadmap.slitaz.org-error.log"
   3.136 +  accesslog.filename = "/var/log/lighttpd/roadmap.slitaz.org-access.log"
   3.137    cgi.assign = (
   3.138 -    ".cgi" => "/usr/bin/python"
   3.139 +    ".cgi" => "/bin/sh"
   3.140    )
   3.141 -  server.document-root = "/home/slitaz/www/hg"
   3.142 -  url.rewrite-once = ( "(.*)" => "/hgwebdir.cgi$1" )
   3.143 -  auth.backend = "plain"
   3.144 -  auth.backend.plain.userfile = "/etc/lighttpd/plain.passwd"
   3.145 -  auth.require = ( "/" =>
   3.146 -    (
   3.147 -    "method" => "basic",
   3.148 -    "realm" => "SliTaz Mercurial repositories protected area",
   3.149 -    "require" => "valid-user"
   3.150 -    )
   3.151 -  )
   3.152 -
   3.153 -}
   3.154 -
   3.155 -# doc.slitaz.org
   3.156 -#
   3.157 -$HTTP["host"] =~ "doc\.slitaz\.org" {
   3.158 -  server.document-root = "/home/slitaz/www/doc"
   3.159 -  index-file.names = ("doku.php") 
   3.160 -  var.dokudir = ""
   3.161 -   # Rewrites for dokuwiki
   3.162 -    url.rewrite = (
   3.163 -      "^" + var.dokudir + "/lib/.*$"              => "$0",
   3.164 -      "^" + var.dokudir + "/_media/(.*)?\?(.*)$"  => var.dokudir + "/lib/exe/fetch.php?media=$1&$2",
   3.165 -      "^" + var.dokudir + "/_media/(.*)$"         => var.dokudir + "/lib/exe/fetch.php?media=$1",
   3.166 -      "^" + var.dokudir + "/_detail/(.*)?\?(.*)$" => var.dokudir + "/lib/exe/detail.php?media=$1&$2",
   3.167 -      "^" + var.dokudir + "/_detail/(.*)?$"       => var.dokudir + "/lib/exe/detail.php?media=$1",
   3.168 -      "^" + var.dokudir + "/_export/([^/]+)/(.*)\?(.*)$" => var.dokudir + "/doku.php?do=export_$1&id=$2&$3",
   3.169 -      "^" + var.dokudir + "/_export/([^/]+)/(.*)" => var.dokudir + "/doku.php?do=export_$1&id=$2",
   3.170 -      "^" + var.dokudir + "/doku.php.*"           => "$0",
   3.171 -      "^" + var.dokudir + "/feed.php.*"           => "$0",
   3.172 -      "^" + var.dokudir + "/(.*)\?(.*)"           => var.dokudir + "/doku.php?id=$1&$2",
   3.173 -      "^" + var.dokudir + "/(.*)"                 => var.dokudir + "/doku.php?id=$1"
   3.174 -    )
   3.175 -}
   3.176 -
   3.177 -# scn.slitaz.org
   3.178 -#
   3.179 -$HTTP["host"] =~ "scn\.slitaz\.org$" {
   3.180 -  server.document-root = "/home/slitaz/www/scn"
   3.181 -  server.errorlog = "/var/log/lighttpd/scn.slitaz.org-error.log"
   3.182 -  accesslog.filename = "/var/log/lighttpd/scn.slitaz.org-access.log"
   3.183 -  url.rewrite-final = (
   3.184 -    "^/system/test/(.*)$" => "/index.php?q=system/test/$1",
   3.185 -    "^/([^.?]*)\?(.*)$" => "/index.php?q=$1&$2",
   3.186 -    "^/([^.?]*)$" => "/index.php?q=$1",
   3.187 -    "^/rss.xml" => "/index.php?q=rss.xml"
   3.188 -  )
   3.189 -}
   3.190 -
   3.191 -# store.slitaz.org
   3.192 -#
   3.193 -$HTTP["host"] =~ "store\.slitaz\.org$" {
   3.194 -  server.document-root = "/home/slitaz/www/store"
   3.195 -  server.errorlog = "/var/log/lighttpd/store.slitaz.org-error.log"
   3.196 -  accesslog.filename = "/var/log/lighttpd/store.slitaz.org-access.log"
   3.197 -}
   3.198 -
   3.199 -# groups.slitaz.org
   3.200 -#
   3.201 -$HTTP["host"] =~ "groups\.slitaz\.org$" {
   3.202 -  server.document-root = "/home/slitaz/www/groups"
   3.203 -  server.errorlog = "/var/log/lighttpd/groups.slitaz.org-error.log"
   3.204 -  accesslog.filename = "/var/log/lighttpd/groups.slitaz.org-access.log"
   3.205 -  url.rewrite-final = (
   3.206 -    "^/system/test/(.*)$" => "/index.php?q=system/test/$1",
   3.207 -    "^/([^.?]*)\?(.*)$" => "/index.php?q=$1&$2",
   3.208 -    "^/([^.?]*)$" => "/index.php?q=$1",
   3.209 -    "^/rss.xml" => "/index.php?q=rss.xml"
   3.210 -  )
   3.211 +  index-file.names = ( "roadmap.cgi" )
   3.212  }
   3.213  
   3.214  # bugs.slitaz.org
   3.215  #
   3.216 -$HTTP["host"] =~ "bugs\.slitaz\.org$" {
   3.217 -  #cgi.assign = (
   3.218 -  #  ".cgi" => "/usr/bin/python"
   3.219 -  #)
   3.220 -  #server.document-root = "/home/slitaz/www/bugs"
   3.221 -  #url.rewrite-once = ( "(.*)" => "/roundup.cgi$1" )
   3.222 -
   3.223 -  #url.rewrite = ( "(.*)" => "/bugs$1" )
   3.224 -  proxy.server = ( "" => ((
   3.225 -      "host" => "127.0.0.1",
   3.226 -      "port" => "8917"
   3.227 -    ))
   3.228 +$HTTP["host"] =~ "^bugs\.slitaz\.org$" {
   3.229 +  server.document-root = "/home/slitaz/www/bugs"
   3.230 +  server.errorlog = "/var/log/lighttpd/bugs.slitaz.org-error.log"
   3.231 +  accesslog.filename = "/var/log/lighttpd/bugs.slitaz.org-access.log"
   3.232 +  index-file.names = ( "bugs.cgi" )
   3.233 +  cgi.assign = (
   3.234 +    ".cgi" => "/bin/sh"
   3.235    )
   3.236  }
   3.237  
   3.238 -# cook.slitaz.org
   3.239 +# try.slitaz.org (For testing)
   3.240  #
   3.241 -$HTTP["host"] =~ "cook\.slitaz\.org$" {
   3.242 +$HTTP["host"] =~ "(try\.slitaz\.org$)" {
   3.243 +  server.document-root = "/home/slitaz/www/try"
   3.244 +  server.errorlog = "/var/log/lighttpd/try.slitaz.org-error.log"
   3.245 +  accesslog.filename = "/var/log/lighttpd/try.slitaz.org-access.log"
   3.246    cgi.assign = (
   3.247 +    ".py" => "/usr/bin/python",
   3.248 +    ".sh" => "/bin/sh",
   3.249      ".cgi" => "/bin/sh"
   3.250    )
   3.251 -  index-file.names = ( "cooker.cgi" )
   3.252 -  server.document-root = "/home/slitaz/www/cook"
   3.253 +  #index-file.names = ( "index.cgi" )
   3.254  }
   3.255  
   3.256 -# cloud.slitaz.org
   3.257 +# cloud.slitaz.me
   3.258  #
   3.259 -$HTTP["host"] =~ "cloud\.slitaz\.org$" {
   3.260 -  cgi.assign = (
   3.261 -   ".cgi" => "/bin/sh"
   3.262 -  )
   3.263 -  index-file.names = ( "cloud.cgi" )
   3.264 +$HTTP["host"] =~ "cloud\.slitaz\.me$" {
   3.265    server.document-root = "/home/slitaz/www/cloud"
   3.266 -  auth.backend = "plain"
   3.267 -  auth.backend.plain.userfile = "/etc/lighttpd/cloud.users"
   3.268 -  auth.require = ( "/" =>
   3.269 -    (
   3.270 -    "method" => "basic"
   3.271 -    "realm" => "SliTaz Cloud protected area",
   3.272 -    "require" => "valid-user"
   3.273 -    )
   3.274 -  )
   3.275 +  server.errorlog = "/var/log/lighttpd/cloud.slitaz.me-error.log"
   3.276 +  accesslog.filename = "/var/log/lighttpd/cloud.slitaz.me-access.log"
   3.277  }
   3.278  
   3.279  # ssfs.slitaz.org
   3.280 @@ -250,27 +141,18 @@
   3.281  
   3.282  # These hosts are personnal website for me and my family, pankso.
   3.283  
   3.284 -
   3.285 -# libordux
   3.286 +# pankso.com
   3.287  #
   3.288 -$HTTP["host"] =~ "(^|\.)libordux\.$" {
   3.289 -  server.document-root = "/home/pankso/vhosts/libordux"
   3.290 -  server.errorlog = "/var/log/lighttpd/libordux.error.log"
   3.291 -  accesslog.filename = "/var/log/lighttpd/libordux.access.log"
   3.292 +$HTTP["host"] =~ "(^|\.)pankso\.com$" {
   3.293 +  server.document-root = "/home/pankso/vhosts/pankso"
   3.294 +  server.errorlog = "/var/log/lighttpd/pankso.error.log"
   3.295 +  accesslog.filename = "/var/log/lighttpd/pankso.access.log"
   3.296  }
   3.297  
   3.298  # lincolm.ch
   3.299  #
   3.300  $HTTP["host"] =~ "(^|\.)lincolm\.ch$" {
   3.301    server.document-root = "/home/pankso/vhosts/lincolm"
   3.302 -  server.errorlog = "/var/log/lighttpd/lincolm-error.log"
   3.303 -  accesslog.filename = "/var/log/lighttpd/lincolm-access.log"
   3.304 +  server.errorlog = "/var/log/lighttpd/lincolm.error.log"
   3.305 +  accesslog.filename = "/var/log/lighttpd/lincolm.access.log"
   3.306  }
   3.307 -
   3.308 -# solufina.ch
   3.309 -#
   3.310 -$HTTP["host"] =~ "(^|\.)solufina\.ch$" {
   3.311 -  server.document-root = "/home/pankso/vhosts/solufina"
   3.312 -  server.errorlog = "/var/log/lighttpd/solufina.log"
   3.313 -  accesslog.filename = "/var/log/lighttpd/solufina.log"
   3.314 -}
     4.1 --- a/initramfs/etc/local-mirror.conf	Sun Mar 04 01:55:59 2012 -0500
     4.2 +++ b/initramfs/etc/local-mirror.conf	Tue Apr 24 18:55:39 2012 +0000
     4.3 @@ -3,26 +3,26 @@
     4.4   slitaz-doc-wiki-data slitaz-forge slitaz-modular slitaz-pizza \
     4.5   slitaz-tools slitaz-vz ssfs tazlito tazpanel tazpkg tazusb \
     4.6   tazwok slitaz-dev-tools website wok wok-stable wok-tiny \
     4.7 - wok-undigest wok-tank my-cookutils piratebox"
     4.8 -WWW="website people doc pizza cook pkgs mirror boot tank hg \
     4.9 -lfs absguide man-html piratebox hgbook gimp.en gimp.fr gimp.es"
    4.10 + wok-undigest wok-tank my-cookutils tazbug piratebox"
    4.11 +WWW="website people doc pizza cook pkgs mirror boot try tank hg \
    4.12 +lfs absguide man-html roadmap usbkey pro piratebox \
    4.13 +hgbook gimp.en gimp.fr gimp.es"
    4.14  IP_ADDR="127.0.0.1"
    4.15  ROUTER_IP="192.168.1.1"
    4.16  ADDRESS="www.slitaz.org pizza.slitaz.org boot.slitaz.org \
    4.17 -mirror.slitaz.org tank.slitaz.org doc.slitaz.org \
    4.18 +mirror.slitaz.org try.slitaz.org tank.slitaz.org doc.slitaz.org \
    4.19  pkgs.slitaz.org hg.slitaz.org cook.slitaz.org \
    4.20 -people.slitaz.org piratebox.lan"
    4.21 +people.slitaz.org roadmap.slitaz.org usbkey.slitaz.org \
    4.22 +pro.slitaz.org piratebox.lan"
    4.23  VHOST_FILE="/etc/lighttpd/vhosts-local.conf"
    4.24  VHOST_MIRROR_FILE="/etc/lighttpd/vhosts-local-mirror.conf"
    4.25  VHOST_TANK_FILE="/etc/lighttpd/vhosts-local-tank.conf"
    4.26  REPOS_DIR="/repos"
    4.27 -REPOS_WEB_DIR="/home/slitaz/repos-web"
    4.28 +REPOS_WEB_DIR="$SLITAZ_HOME/repos-web"
    4.29  CUSTOM_WOK="yes"
    4.30  MKCHROOT="yes"
    4.31  
    4.32 -MAIN_WWW_DIR="/home/slitaz/www"
    4.33 +MAIN_WWW_DIR="$SLITAZ_HOME/www"
    4.34  
    4.35 -STABLE="/home/slitaz/stable"
    4.36 -COOKING="/home/slitaz/cooking"
    4.37  #PKGDIR
    4.38 -#SRCDIR
    4.39 \ No newline at end of file
    4.40 +#SRCDIR
     5.1 --- a/initramfs/usr/bin/local-mirror	Sun Mar 04 01:55:59 2012 -0500
     5.2 +++ b/initramfs/usr/bin/local-mirror	Tue Apr 24 18:55:39 2012 +0000
     5.3 @@ -22,27 +22,34 @@
     5.4  
     5.5  COOKORDER="$(find /mnt/live/mnt/* -maxdepth 1 -name "cookorder.list")"
     5.6  CUR_PWD="$PWD"
     5.7 -version="$(cat /etc/slitaz-release)"
     5.8 +version="$SLITAZ_RELEASE"
     5.9  
    5.10 -[ -d $SLITAZ_DIR/$version ] || mkdir -p $SLITAZ_DIR/$version
    5.11 -[ -d $SLITAZ_DIR/repos ] || ln -sf $REPOS_DIR $SLITAZ_DIR/repos
    5.12 -[ -d $SLITAZ_DIR/repos ] && REPOS_DIR="$SLITAZ_DIR/repos"
    5.13 +[ -d $SLITAZ_HOME/$version ] || mkdir -p $SLITAZ_HOME/$version
    5.14 +[ -d $SLITAZ_HOME/repos ] || ln -sf $REPOS_DIR $SLITAZ_HOME/repos
    5.15 +[ -d $SLITAZ_HOME/repos ] && REPOS_DIR="$SLITAZ_HOME/repos"
    5.16 +PYTHON_LIB="/usr/lib/python2.7"
    5.17  
    5.18  if [ -d $PKGDIR ]; then
    5.19 -	[ -d $SLITAZ_DIR/$version/packages ] || ln -sf $PKGDIR $SLITAZ_DIR/$version/packages
    5.20 -	[ -d $SLITAZ_DIR/packages ] || ln -sf $PKGDIR $SLITAZ_DIR/packages
    5.21 +	[ -d $SLITAZ_HOME/$version/packages ] || ln -sf $PKGDIR $SLITAZ_HOME/$version/packages
    5.22 +	[ -d $SLITAZ_HOME/packages ] || ln -sf $PKGDIR $SLITAZ_HOME/packages
    5.23  fi
    5.24  if [ -d $SRCDIR ]; then
    5.25 -	[ -d $SLITAZ_DIR/$version/src ] || ln -sf $SRCDIR $SLITAZ_DIR/$version/src
    5.26 -	[ -d $SLITAZ_DIR/src ] || ln -sf $SRCDIR $SLITAZ_DIR/src
    5.27 +	[ -d $SLITAZ_HOME/$version/src ] || ln -sf $SRCDIR $SLITAZ_HOME/$version/src
    5.28 +	[ -d $SLITAZ_HOME/src ] || ln -sf $SRCDIR $SLITAZ_HOME/src
    5.29  fi
    5.30  
    5.31  #repos folders for website
    5.32  PEOPLE_WWW_DIR="$REPOS_DIR/slitaz-forge/people"
    5.33 +MIRROR_WWW_DIR="$REPOS_DIR/slitaz-forge/mirror/root"
    5.34 +MIRROR_INFO_WWW_DIR="$REPOS_DIR/slitaz-forge/mirror/info"
    5.35 +PKGS_WWW_DIR="$REPOS_DIR/slitaz-forge/pkgs"
    5.36  DOC_WWW_DIR="$REPOS_DIR/slitaz-forge/doc"
    5.37  PIZZA_WWW_DIR="$REPOS_DIR/slitaz-pizza/php"
    5.38  BOOT_WWW_DIR="$REPOS_DIR/slitaz-forge/boot"
    5.39  TANK_WWW_DIR="$REPOS_DIR/slitaz-forge/tank/web"
    5.40 +USBKEY_WWW_DIR="$REPOS_DIR/slitaz-forge/usbkey"
    5.41 +ROADMAP_WWW_DIR="$REPOS_DIR/slitaz-forge/roadmap"
    5.42 +PRO_WWW_DIR="$REPOS_DIR/slitaz-forge/pro"
    5.43  
    5.44  if [ "$COMMAND" = "tank-only" ]; then
    5.45  	WWW="${WWW/mirror/}"
    5.46 @@ -63,7 +70,7 @@
    5.47  [ -d $REPOS_DIR ] || continue
    5.48  
    5.49  INCOMING_REPOSITORY="$COOKING/packages-incoming"
    5.50 -INCOMING="$SLITAZ_DIR/$version/incoming"
    5.51 +INCOMING="$SLITAZ_HOME/$version/incoming"
    5.52  CRON_FILE="/var/spool/cron/crontabs/root"
    5.53  
    5.54  www() {
    5.55 @@ -91,9 +98,9 @@
    5.56  	
    5.57  	case "$b" in
    5.58  		website)
    5.59 -			cd $REPOS_DIR/$b
    5.60 -			hg update testing
    5.61 -			cd $CUR_DIR
    5.62 +			#cd $REPOS_DIR/$b
    5.63 +			#hg update testing
    5.64 +			#cd $CUR_DIR
    5.65  			[ -d $REPOS_DIR/$b ] && ln -s $REPOS_DIR/$b $MAIN_WWW_DIR
    5.66  			if [ -f $MAIN_WWW_DIR/$b/libs/get-feeds.sh ]; then
    5.67  				if [ ! $(grep -l "$MAIN_WWW_DIR/$b/libs/get-feeds.sh" $CRON_FILE) ]; then
    5.68 @@ -103,7 +110,7 @@
    5.69  			fi
    5.70  		;;
    5.71  		people)
    5.72 -			[ -d $REPOS_DIR/slitaz-forge/people ] && ln -s $REPOS_DIR/slitaz-forge/people $MAIN_WWW_DIR/people
    5.73 +			[ -d $PEOPLE_WWW_DIR ] && ln -s $PEOPLE_WWW_DIR $MAIN_WWW_DIR/people
    5.74  		;;
    5.75  		doc)
    5.76  			[ -d $DOC_WWW_DIR ] && cp -a $DOC_WWW_DIR $MAIN_WWW_DIR/doc
    5.77 @@ -117,11 +124,11 @@
    5.78  			chmod 777 -R $MAIN_WWW_DIR/doc
    5.79  		;;
    5.80  		bugs)
    5.81 -			[ -d $SLITAZ_DIR/bugs ] || mkdir -p $SLITAZ_DIR/bugs
    5.82 +			[ -d $SLITAZ_HOME/bugs ] || mkdir -p $SLITAZ_HOME/bugs
    5.83  			[ -d $MAIN_WWW_DIR/bugs ] || mkdir -p $MAIN_WWW_DIR/bugs
    5.84 -			[ -d $REPOS_DIR/slitaz-forge/bugs ] && cp -a $REPOS_DIR/slitaz-forge/bugs/roundup.wsgi $SLITAZ_DIR/bugs/roundup.wsgi
    5.85 -			[ -d $REPOS_DIR/slitaz-forge/bugs ] && cp -a $REPOS_DIR/slitaz-forge/bugs/server.ini $SLITAZ_DIR/bugs/server.ini
    5.86 -			[ -d $REPOS_DIR/slitaz-forge/bugs/templates/slitaz ] && cp -a $REPOS_DIR/slitaz-forge/bugs/templates/slitaz/* $SLITAZ_DIR/bugs
    5.87 +			[ -d $REPOS_DIR/slitaz-forge/bugs ] && cp -a $REPOS_DIR/slitaz-forge/bugs/roundup.wsgi $SLITAZ_HOME/bugs/roundup.wsgi
    5.88 +			[ -d $REPOS_DIR/slitaz-forge/bugs ] && cp -a $REPOS_DIR/slitaz-forge/bugs/server.ini $SLITAZ_HOME/bugs/server.ini
    5.89 +			[ -d $REPOS_DIR/slitaz-forge/bugs/templates/slitaz ] && cp -a $REPOS_DIR/slitaz-forge/bugs/templates/slitaz/* $SLITAZ_HOME/bugs
    5.90  			[ -f /usr/share/roundup/cgi-bin/roundup.cgi ] && ln -sf /usr/share/roundup/cgi-bin/roundup.cgi $MAIN_WWW_DIR/bugs/roundup.cgi
    5.91  		;;
    5.92  		pizza)
    5.93 @@ -176,11 +183,11 @@
    5.94  			#	make install
    5.95  			#	cd $pwd
    5.96  			#fi
    5.97 -			echo "$SLITAZ_DIR/$version/packages" > $LOCALSTATE/mirror
    5.98 +			echo "$SLITAZ_HOME/$version/packages" > $LOCALSTATE/mirror
    5.99  			[ -d $LOCALSTATE/undigest/incoming ] || mkdir -p $LOCALSTATE/undigest/incoming
   5.100  			[ -f $LOCALSTATE/undigest/incoming/mirror ] || echo "$INCOMING" > $LOCALSTATE/undigest/incoming/mirror
   5.101  			echo "incoming" > $LOCALSTATE/priority
   5.102 -			[ -d $SLITAZ_DIR/$version/incoming ] || mkdir -p $SLITAZ_DIR/$version/incoming
   5.103 +			[ -d $SLITAZ_HOME/$version/incoming ] || mkdir -p $SLITAZ_HOME/$version/incoming
   5.104  			[ -d /var/www/cooker ] && cp -a /var/www/cooker $MAIN_WWW_DIR/$b
   5.105  			[ -f /usr/share/$b/header.html ] && cp -a /usr/share/$b/header.html $MAIN_WWW_DIR/$b/header.html
   5.106  			[ -f /etc/slitaz/$b.conf ] && cp -a /etc/slitaz/$b.conf $MAIN_WWW_DIR/$b/$b.conf
   5.107 @@ -188,51 +195,50 @@
   5.108  				if [ -d $PKGDIR ]; then
   5.109  					tazpkg recharge
   5.110  					tazdev gen-chroot $version
   5.111 -					[ -d $SLITAZ_DIR/$version/chroot ] && mkdir -p $SLITAZ_DIR/$version/chroot$(dirname $CRON_FILE)
   5.112 -					[ -d $SLITAZ_DIR/$version/chroot ] && echo "0 */2 * * * /usr/bin/cooker" > $SLITAZ_DIR/$version/chroot${CRON_FILE}
   5.113 -					[ -d $SLITAZ_DIR/$version/chroot ] && echo "$SLITAZ_DIR/$version/packages" > $SLITAZ_DIR/$version/chroot${LOCALSTATE}/mirror
   5.114 -					mkdir -p $SLITAZ_DIR/$version/chroot${LOCALSTATE}/undigest/incoming
   5.115 -					echo "$SLITAZ_DIR/$version/incoming" > $SLITAZ_DIR/$version/chroot${LOCALSTATE}/undigest/incoming/mirror
   5.116 +					[ -d $SLITAZ_HOME/$version/chroot ] && mkdir -p $SLITAZ_HOME/$version/chroot$(dirname $CRON_FILE)
   5.117 +					[ -d $SLITAZ_HOME/$version/chroot ] && echo "0 */2 * * * /usr/bin/cooker" > $SLITAZ_HOME/$version/chroot${CRON_FILE}
   5.118 +					[ -d $SLITAZ_HOME/$version/chroot ] && echo "$SLITAZ_HOME/$version/packages" > $SLITAZ_HOME/$version/chroot${LOCALSTATE}/mirror
   5.119 +					mkdir -p $SLITAZ_HOME/$version/chroot${LOCALSTATE}/undigest/incoming
   5.120 +					echo "$SLITAZ_HOME/$version/incoming" > $SLITAZ_HOME/$version/chroot${LOCALSTATE}/undigest/incoming/mirror
   5.121  				fi
   5.122  			fi
   5.123 -			[ -d $REPOS_DIR/wok-tank ] && ln -sf $REPOS_DIR/wok-tank $SLITAZ_DIR/$version/wok-hg
   5.124 -			#[ -d $REPOS_DIR/wok-tank ] && ln -sf $REPOS_DIR/wok-tank $SLITAZ_DIR/$version/wok
   5.125 -			[ -d $MAIN_WWW_DIR/$b/packages ] || ln -sf $SLITAZ_DIR/$version/packages $MAIN_WWW_DIR/$b/packages
   5.126 -			[ -d $MAIN_WWW_DIR/$b/incoming ] || ln -sf $SLITAZ_DIR/$version/incoming $MAIN_WWW_DIR/$b/incoming
   5.127 +			[ -d $REPOS_DIR/wok-tank ] && ln -sf $REPOS_DIR/wok-tank $SLITAZ_HOME/$version/wok-hg
   5.128 +			#[ -d $REPOS_DIR/wok-tank ] && ln -sf $REPOS_DIR/wok-tank $SLITAZ_HOME/$version/wok
   5.129 +			[ -d $MAIN_WWW_DIR/$b/packages ] || ln -sf $SLITAZ_HOME/$version/packages $MAIN_WWW_DIR/$b/packages
   5.130 +			[ -d $MAIN_WWW_DIR/$b/incoming ] || ln -sf $SLITAZ_HOME/$version/incoming $MAIN_WWW_DIR/$b/incoming
   5.131  		;;
   5.132 +		try)
   5.133 +			[ -d $MAIN_WWW_DIR/tinycm ] || ln -sf $REPOS_DIR/tinycm $MAIN_WWW_DIR/tinycm ;;
   5.134  		pkgs)
   5.135 -			[ -d $MAIN_WWW_DIR/pkgs ] || mkdir -p $MAIN_WWW_DIR/pkgs
   5.136  			pwd=$(pwd)
   5.137 -			#if [ -d $REPOS_DIR/slitaz-dev-tools/tazpkg-web ]; then
   5.138 -			#	cd $REPOS_DIR/slitaz-dev-tools/tazpkg-web
   5.139 -			#	make install
   5.140 -			#	cd $pwd
   5.141 -			#fi
   5.142 -			[ -d /var/lib/tazpkg-web/style ] && cp -a /var/lib/tazpkg-web/style $MAIN_WWW_DIR/pkgs
   5.143 -			[ -f /var/lib/tazpkg-web/search.cgi ] && cp -a /var/lib/tazpkg-web/search.cgi $MAIN_WWW_DIR/pkgs
   5.144 -			#[ -d $REPOS_DIR/slitaz-dev-tools/tazpkg-web/style ] && cp -a $REPOS_DIR/slitaz-dev-tools/tazpkg-web/style/* $MAIN_WWW_DIR/pkgs
   5.145 -			#[ -f $REPOS_DIR/slitaz-dev-tools/tazpkg-web/search.cgi ] && cp -a $REPOS_DIR/slitaz-dev-tools/tazpkg-web/search.cgi $MAIN_WWW_DIR/pkgs
   5.146 +			if [ -d $PKGS_WWW_DIR ]; then
   5.147 +				cd $PKGS_WWW_DIR
   5.148 +				make install-msg
   5.149 +				cd $pwd
   5.150 +			fi
   5.151 +			[ -d $MAIN_WWW_DIR/pkgs ] || ln -sf $PKGS_WWW_DIR $MAIN_WWW_DIR/pkgs
   5.152  			[ -d $REPOS_DIR/flavors ] && ln -sf $REPOS_DIR/flavors $COOKING/flavors
   5.153 -			#[ -d $REPOS_DIR/flavors-stable ] && ln -sf $REPOS_DIR/flavors-stable $STABLE/flavors
   5.154 -			#[ -d $COOKING/wok ] || ln -sf $REPOS_DIR/wok $COOKING/clean-wok
   5.155 -			#[ -d $STABLE/clean-wok ] || ln -sf $REPOS_DIR/wok-stable $STABLE/clean-wok
   5.156 -			if [ -f "/usr/bin/tazpkg-web" ]; then
   5.157 -				tazpkg-web cooking
   5.158 -				if [ ! $(grep -l "/usr/bin/tazpkg-web cooking" $CRON_FILE) ]; then
   5.159 -					echo "# Update pkgs.slitaz.org pages" >> $CRON_FILE
   5.160 -					echo "20 02 * * * /usr/bin/tazpkg-web cooking" >> $CRON_FILE
   5.161 -				fi
   5.162 -			fi
   5.163  		;;
   5.164 +		usbkey)
   5.165 +			[ -d $USBKEY_WWW_DIR ] && ln -sf $USBKEY_WWW_DIR $MAIN_WWW_DIR/usbkey ;;
   5.166 +		pro)
   5.167 +			[ -d $PRO_WWW_DIR ] && ln -sf $PRO_WWW_DIR $MAIN_WWW_DIR/pro ;;
   5.168 +		roadmap)
   5.169 +			[ -d $ROADMAP_WWW_DIR ] && ln -sf $ROADMAP_WWW_DIR $MAIN_WWW_DIR/roadmap ;;
   5.170  		mirror)
   5.171 -			[ -d $REPOS_DIR/slitaz-dev-tools/mirror-tools/mirror-info ] && cp -a $REPOS_DIR/slitaz-dev-tools/mirror-tools/mirror-info $MAIN_WWW_DIR
   5.172 -			[ -d $REPOS_DIR/slitaz-dev-tools/mirror-tools/slitaz ] && cp -a $REPOS_DIR/slitaz-dev-tools/mirror-tools/slitaz $MAIN_WWW_DIR
   5.173 -			[ -d $MAIN_WWW_DIR/slitaz/mirror/packages ] || mkdir -p $MAIN_WWW_DIR/slitaz/mirror/packages
   5.174 -			[ -d $PKGDIR ] && ln -sf $PKGDIR $MAIN_WWW_DIR/slitaz/mirror/packages/$version
   5.175 -			[ -d /var/www/slitaz ] || ln -sf $MAIN_WWW_DIR/slitaz /var/www/slitaz
   5.176 +			[ -d $MIRROR_INFO_WWW_DIR ] && cp -a $MIRROR_INFO_WWW_DIR  $MAIN_WWW_DIR/mirror-info
   5.177 +			[ -d $MIRROR_WWW_DIR ] && cp -a $MIRROR_WWW_DIR $MAIN_WWW_DIR/mirror
   5.178 +			[ -d $MAIN_WWW_DIR/mirror/packages ] || mkdir -p $MAIN_WWW_DIR/mirror/packages
   5.179 +			[ -d $PKGDIR ] && ln -sf $PKGDIR $MAIN_WWW_DIR/mirror/packages/$version
   5.180 +			[ -d /var/www/slitaz ] || mkdir -p /var/www/slitaz
   5.181 +			[ -d /var/www/slitaz/mirror ] || ln -sf $MAIN_WWW_DIR/mirror /var/www/slitaz/mirror
   5.182 +			[ -d /var/www/mirror ] || ln -sf $MAIN_WWW_DIR/mirror /var/www/mirror
   5.183  			[ -d /var/www/mirror-info ] || ln -sf $MAIN_WWW_DIR/mirror-info /var/www/mirror-info
   5.184  			[ -d $MAIN_WWW_DIR/mirror-info/pics ] || mkdir -p $MAIN_WWW_DIR/mirror-info/pics
   5.185  			[ -d $MAIN_WWW_DIR/mirror-info/pics/rrd ] || ln -sf $MAIN_WWW_DIR/pics/rrd $MAIN_WWW_DIR/mirror-info/pics/rrd
   5.186 +			[ -f $REPOS_DIR/slitaz-forge/mirror/files/etc/rsyncd.conf ] && cp -a $REPOS_DIR/slitaz-forge/mirror/files/etc/rsyncd.conf /etc/rsyncd.conf
   5.187 +			[ -f $REPOS_DIR/slitaz-forge/mirror/files/etc/rsyncd.motd ] && cp -a $REPOS_DIR/slitaz-forge/mirror/files/etc/rsyncd.motd /etc/rsyncd.motd
   5.188 +			[ -f $REPOS_DIR/slitaz-forge/mirror/files/usr/bin/chkfilelist ] && cp -a $REPOS_DIR/slitaz-forge/mirror/files/usr/bin/chkfilelist /usr/bin/chkfilelist
   5.189  			if [ -f /usr/bin/makegraphs ]; then
   5.190  				[ -f $MAIN_WWW_DIR/pics/makegraphs ] || cp -a /usr/bin/makegraphs $MAIN_WWW_DIR/pics/makegraphs
   5.191  				if [ ! $(grep -l "$MAIN_WWW_DIR/pics/makegraphs" $CRON_FILE) ]; then
   5.192 @@ -255,8 +261,8 @@
   5.193  					mkdir -p $dirlog
   5.194  				fi
   5.195  			done
   5.196 -			[ -d $MAIN_WWW_DIR/$b/pics ] || mkdir -p $MAIN_WWW_DIR/$b/pics
   5.197 -			[ -d $MAIN_WWW_DIR/$b/pics/rrd ] || ln -sf $MAIN_WWW_DIR/pics/rrd $MAIN_WWW_DIR/$b/pics/rrd
   5.198 +			[ -d $MAIN_WWW_DIR/$b/images ] || mkdir -p $MAIN_WWW_DIR/$b/images
   5.199 +			[ -d $MAIN_WWW_DIR/$b/graphs/rrd ] || ln -sf $MAIN_WWW_DIR/graphs/rrd $MAIN_WWW_DIR/$b/images/rrd
   5.200  			if [ -f /usr/share/awstats/extras/update ]; then
   5.201  				if [ ! $(grep -l "/usr/share/awstats/extras/update" $CRON_FILE) ]; then
   5.202  					echo "# Update Web stats" >> $CRON_FILE
   5.203 @@ -273,6 +279,7 @@
   5.204  		;;
   5.205  		hg)
   5.206  			[ -d $MAIN_WWW_DIR/hg ] || mkdir -p $MAIN_WWW_DIR/hg
   5.207 +			[ -d $REPOS_DIR/slitaz-dev-tools/slitaz-mercurial-style ] && cp -a $REPOS_DIR/slitaz-dev-tools/slitaz-mercurial-style/* $PYTHON_LIB/site-packages/mercurial
   5.208  			[ -f /usr/share/examples/mercurial/hgwebdir.cgi ] && cp -a /usr/share/examples/mercurial/hgwebdir.cgi $MAIN_WWW_DIR/hg
   5.209  			[ -f /usr/share/examples/mercurial/hgwebdir.cgi ] && cp -a /usr/share/examples/mercurial/hgwebdir.cgi $MAIN_WWW_DIR/hg/hgwebdir.py
   5.210  			[ -f $REPOS_DIR/slitaz-forge/tank/files/etc/mercurial/hgweb.config ] && cp -a $REPOS_DIR/slitaz-forge/tank/files/etc/mercurial/hgweb.config /etc/mercurial
   5.211 @@ -327,6 +334,7 @@
   5.212  				mkdir -p $MAIN_WWW_DIR/piratebox/share
   5.213  				chmod -R 777 $MAIN_WWW_DIR/piratebox/share
   5.214  			fi
   5.215 +			echo "<date>00:00:00</date>&nbsp;&nbsp;<name>PirateBox:</name>&nbsp;&nbsp;&nbsp;<data class='def'>Chat and share files anonymously!</data><br>" > $MAIN_WWW_DIR/piratebox/cgi-bin/data.pso
   5.216  			;;
   5.217  		linuxgazette)
   5.218  			#if [ -d /repos/linuxgazette ]; then
   5.219 @@ -427,12 +435,13 @@
   5.220  up_src_links() {
   5.221  	local i
   5.222  	if [ -d $SRCDIR ]; then
   5.223 -		[ -d $MAIN_WWW_DIR/slitaz/mirror/sources/packages ] && rm -rf $MAIN_WWW_DIR/slitaz/mirror/sources/packages
   5.224 +		[ -d $MAIN_WWW_DIR/mirror/sources/packages ] && rm -rf $MAIN_WWW_DIR/mirror/sources/packages
   5.225  		for i in $(ls $SRCDIR); do
   5.226 -			[ -d $MAIN_WWW_DIR/slitaz/mirror/sources/packages/${i:0:1} ] || mkdir -p $MAIN_WWW_DIR/slitaz/mirror/sources/packages/${i:0:1}
   5.227 -			[ -f $MAIN_WWW_DIR/slitaz/mirror/sources/packages/${i:0:1}/$i ] || ln -sf $SRCDIR/$i $MAIN_WWW_DIR/slitaz/mirror/sources/packages/${i:0:1}/$i
   5.228 +			[ -d $MAIN_WWW_DIR/mirror/sources/packages/${i:0:1} ] || mkdir -p $MAIN_WWW_DIR/mirror/sources/packages/${i:0:1}
   5.229 +			[ -f $MAIN_WWW_DIR/mirror/sources/packages/${i:0:1}/$i ] || ln -sf $SRCDIR/$i $MAIN_WWW_DIR/mirror/sources/packages/${i:0:1}/$i
   5.230  		done
   5.231  	fi
   5.232 +	[ -f /usr/bin/chkfilelist ] && /usr/bin/chkfilelist
   5.233  }
   5.234  
   5.235  case "$COMMAND" in 
   5.236 @@ -446,9 +455,11 @@
   5.237  		done
   5.238  		#echo "127.0.0.1 localhost $(cat /etc/hostname)" > /etc/hosts
   5.239  		[ "$IP_ADDR" == "127.0.0.1" ] && echo "127.0.0.1 tazpanel.slitaz.org" >> /etc/hosts
   5.240 -		for hostname in $ADDRESS; do 
   5.241 +		for hostname in $ADDRESS; do
   5.242  				if [ "$hostname" = "www.slitaz.org" ]; then
   5.243  					echo "$IP_ADDR $hostname slitaz.org" >> /etc/hosts
   5.244 +				elif [ "$hostname" = "pro.slitaz.org" ]; then
   5.245 +					echo "$IP_ADDR $hostname slitaz.pro" >> /etc/hosts
   5.246  				else
   5.247  					echo "$IP_ADDR $hostname" >> /etc/hosts
   5.248  				fi
   5.249 @@ -462,8 +473,8 @@
   5.250  				echo "dhcp-option=option:router,$ROUTER_IP" >> /etc/dnsmasq.conf
   5.251  			fi
   5.252  		fi
   5.253 -		if [ -d "$SLITAZ_DIR/$version/packages" ]; then
   5.254 -			echo "$SLITAZ_DIR/$version/packages" > $LOCALSTATE/mirror
   5.255 +		if [ -d "$SLITAZ_HOME/$version/packages" ]; then
   5.256 +			echo "$SLITAZ_HOME/$version/packages" > $LOCALSTATE/mirror
   5.257  		fi
   5.258  		if [ "$COMMAND" = "tank-only" ]; then
   5.259  			[ -f $VHOST_TANK_FILE ] && ln -sf $VHOST_TANK_FILE /etc/lighttpd/vhosts.conf
     6.1 --- a/initramfs/usr/bin/makegraphs	Sun Mar 04 01:55:59 2012 -0500
     6.2 +++ b/initramfs/usr/bin/makegraphs	Tue Apr 24 18:55:39 2012 +0000
     6.3 @@ -1,14 +1,13 @@
     6.4  #!/bin/sh
     6.5 -#*/5  * * * * /var/www/mirror-info/bin/makegraphs >/dev/null
     6.6 +#*/5  * * * * /home/slitaz/www/tank/lib/makegraphs >/dev/null
     6.7  
     6.8  # RRD database directory
     6.9 -rrdlog="/var/spool/rrd"
    6.10 +rrdlog="/home/slitaz/www/graphs/log/rrd"
    6.11  
    6.12  # Images directory
    6.13 -rrdgraph="/var/www/vhosts/pics/rrd"
    6.14 +rrdgraph="/home/slitaz/www/graphs/images/rrd"
    6.15  
    6.16  # Colors
    6.17 -#rrdcolors="--color SHADEA#EAE9EE --color SHADEB#EAE9EE --color BACK#EAE9EE" 
    6.18  rrdcolors="--color SHADEA#FFFFFF --color SHADEB#FFFFFF --color BACK#FFFFFF" 
    6.19  rrdgraphargs="-aPNG -i -z --alt-y-grid -w 600 -h 100 -r $rrdcolors"
    6.20  
    6.21 @@ -18,20 +17,21 @@
    6.22  updatecpudata() {
    6.23  	[ -e "$rrdlog/cpu.rrd" ] || rrdtool create $rrdlog/cpu.rrd --step=300 \
    6.24  			DS:user:COUNTER:600:0:500000000 \
    6.25 +			DS:nice:COUNTER:600:0:500000000 \
    6.26  			DS:system:COUNTER:600:0:500000000 \
    6.27  			DS:idle:COUNTER:600:0:500000000 \
    6.28 +			DS:iowait:COUNTER:600:0:500000000 \
    6.29 +			DS:irq:COUNTER:600:0:500000000 \
    6.30 +			DS:softirq:COUNTER:600:0:500000000 \
    6.31 +			DS:celsius:GAUGE:600:0:50000 \
    6.32  			RRA:AVERAGE:0.5:1:576  RRA:AVERAGE:0.5:6:672 \
    6.33  			RRA:AVERAGE:0.5:24:732 RRA:AVERAGE:0.5:144:1460
    6.34 -	grep '^cpu' /proc/stat | while read cpu user nice system idle misc; do
    6.35 -		rrdtool update $rrdlog/cpu.rrd -t user:system:idle \
    6.36 -			N:$(( $user + $nice )):$system:$idle
    6.37 -		break
    6.38 -	done
    6.39 -
    6.40 -	[ -e "$rrdlog/cpu2.rrd" ] &&
    6.41 -	grep '^cpu' /proc/stat | while read cpu user nice system idle misc; do
    6.42 -		rrdtool update $rrdlog/cpu2.rrd -t nice:user:system:idle \
    6.43 -			N:$nice:$user:$system:$idle
    6.44 +	grep '^cpu' /proc/stat | while read cpu user nice system idle iowait irq softirq misc; do
    6.45 +		celsius=$(find /sys | grep /temp._input | xargs cat | \
    6.46 +			awk '{ if ($0 > max) max=$0 } END { print max/1 }')
    6.47 +		rrdtool update $rrdlog/cpu.rrd \
    6.48 +			-t celsius:nice:user:system:idle:iowait:irq:softirq \
    6.49 +			N:$celsius:$nice:$user:$system:$idle:$iowait:$irq:$softirq
    6.50  		break
    6.51  	done
    6.52  }
    6.53 @@ -39,22 +39,30 @@
    6.54  updatecpugraph() {
    6.55  	period=$1
    6.56  	info="$(grep '^model name' /proc/cpuinfo | cut -d: -f2 \
    6.57 -		| sed 's/ * / /g' | head -1)"
    6.58 +		| sed 's/ * / /g' | awk '
    6.59 +{ s=$0 ; n++ }                    
    6.60 +END { if (n > 1) printf " %dx",n; print s }')"
    6.61  	rrdtool graph "$rrdgraph/cpu-$period.png" --start -1$period \
    6.62  		$rrdgraphargs -l 0 -u 100 -t "cpu usage per $period [$info ]" \
    6.63  		DEF:user=$rrdlog/cpu.rrd:user:AVERAGE \
    6.64  		DEF:system=$rrdlog/cpu.rrd:system:AVERAGE \
    6.65  		DEF:idle=$rrdlog/cpu.rrd:idle:AVERAGE \
    6.66 -		'CDEF:total=user,system,idle,+,+' \
    6.67 +		DEF:nice=$rrdlog/cpu.rrd:nice:AVERAGE \
    6.68 +		DEF:celsius=$rrdlog/cpu.rrd:celsius:AVERAGE \
    6.69 +		'CDEF:total=user,system,idle,nice,+,+,+' \
    6.70  		'CDEF:userpct=100,user,total,/,*' \
    6.71  		'CDEF:systempct=100,system,total,/,*' \
    6.72  		'CDEF:idlepct=100,idle,total,/,*' \
    6.73 +		'CDEF:nicepct=100,nice,total,/,*' \
    6.74 +		'CDEF:temp=celsius,1000,/' \
    6.75  		'AREA:userpct#0000FF:user cpu usage' \
    6.76 +		'STACK:nicepct#C0C0FF:nice cpu usage' \
    6.77  		'STACK:systempct#FF0000:system cpu usage' \
    6.78 -		'STACK:idlepct#00FF00:idle cpu usage\j'
    6.79 +		'STACK:idlepct#00FF00:idle cpu usage' \
    6.80 +		'LINE1:temp#000000:temperature\g' \
    6.81 +		'GPRINT:temp:MAX:max %2.0lfC\j'
    6.82  }
    6.83  
    6.84 -
    6.85  updatememgraph() {
    6.86  	period=$1
    6.87  	info="$(free | awk '\
    6.88 @@ -115,15 +123,15 @@
    6.89  
    6.90  	while read tag count unit; do
    6.91  		case "$tag" in
    6.92 -		MemTotal:)  memtotal=$(($count * 1024));;
    6.93 -		MemFree:)   memfree=$(($count * 1024))
    6.94 +		MemTotal:)  memtotal=$count;;
    6.95 +		MemFree:)   memfree=$count
    6.96  			    memused=$(($memtotal - $memfree))
    6.97  			    memshared=0;;
    6.98 -		MemShared:) memshared=$(($count * 1024));;
    6.99 -		Buffers:)   membuffers=$(($count * 1024));;
   6.100 -		Cached:)    memcache=$(($count * 1024));;
   6.101 -		SwapTotal:) swaptotal=$(($count * 1024));;
   6.102 -		SwapFree:)  swapfree=$(($count * 1024))
   6.103 +		MemShared:) memshared=$count;;
   6.104 +		Buffers:)   membuffers=$count;;
   6.105 +		Cached:)    memcache=$count;;
   6.106 +		SwapTotal:) swaptotal=$count;;
   6.107 +		SwapFree:)  swapfree=$count
   6.108  			    swapused=$(( $swaptotal - $swapfree));;
   6.109  		esac
   6.110  	done < /proc/meminfo
   6.111 @@ -151,6 +159,10 @@
   6.112  	info="[ $(fdisk -l 2> /dev/null | grep "^Disk $2:" | \
   6.113  		  sed "s|Disk $2: \(.*\), .*|\1|") ]"
   6.114  	if [ -e /sys/block/${2#/dev/}/device/iodone_cnt ]; then
   6.115 +	err=$(printf "%d\n" $(cat /sys/block/${2#/dev/}/device/ioerr_cnt) )
   6.116 +	done=$(printf "%d\n" $(cat /sys/block/${2#/dev/}/device/iodone_cnt) )
   6.117 +	rate=$(echo | awk "BEGIN { printf \"%.0e\\n\",$err/$done }")
   6.118 +	[ $err -eq 0 ] &&  rate="0"
   6.119  #		--right-axis-label "I/O state %"
   6.120  	rrdtool graph "$rrdgraph/disk-$period.png" --start -1$period \
   6.121  		$rrdgraphargs -t "disk access per $period $info" \
   6.122 @@ -164,10 +176,12 @@
   6.123  		"CDEF:writepct=100,write,$maxdisk,/,*" \
   6.124  		"CDEF:errpct=100,err,req,/,*" \
   6.125  		"CDEF:donepct=100,done,req,/,*" \
   6.126 +		"CDEF:errrate=err,done,/" \
   6.127  		'AREA:readpct#0000FF:sectors read from disk' \
   6.128 +		"COMMENT:I/O error rate $rate" \
   6.129  		'STACK:writepct#00FF00:sectors written to disk' \
   6.130 -		'LINE2:donepct#FFFF00:I/O complete' \
   6.131 -		'LINE2:errpct#FF0000:I/O error\j'
   6.132 +		'LINE2:donepct#FFFF00:% I/O complete' \
   6.133 +		'LINE2:errpct#FF0000:% I/O error\j'
   6.134  	else
   6.135  	rrdtool graph "$rrdgraph/disk-$period.png" --start -1$period \
   6.136  		$rrdgraphargs -t "disk access per $period $info" \
   6.137 @@ -219,6 +233,8 @@
   6.138  		DEF:incoming=$rrdlog/$interface.rrd:incoming:AVERAGE \
   6.139  		DEF:outgoing=$rrdlog/$interface.rrd:outgoing:AVERAGE \
   6.140  		'AREA:incoming#00FF00:incoming traffic' \
   6.141 +		'GPRINT:incoming:MAX:max input%8.3lf %sBps' \
   6.142 +		'GPRINT:outgoing:MAX:max output%8.3lf %sBps' \
   6.143  		'LINE1:outgoing#0000FF:outgoing traffic\j'
   6.144  }
   6.145  
   6.146 @@ -274,8 +290,9 @@
   6.147  	for i in /dev/* ; do 
   6.148  		[ $(stat -c "%02t%02T" $i) == $d ] || continue
   6.149  		echo $i
   6.150 -		break
   6.151 +		return
   6.152  	done
   6.153 +	df $1 | sed '$!d;s/ .*$//'
   6.154  }
   6.155  
   6.156  ###
     7.1 --- a/initramfs/usr/bin/slitaz-modular	Sun Mar 04 01:55:59 2012 -0500
     7.2 +++ b/initramfs/usr/bin/slitaz-modular	Tue Apr 24 18:55:39 2012 +0000
     7.3 @@ -8,11 +8,12 @@
     7.4  CDNAME="slitaz"
     7.5  QUIET="y"
     7.6  FORCE="y"
     7.7 -export LABEL="slitaz_${1}_$(date +%Y%m)"
     7.8 +export LABEL="slitaz_$1_$(date +%F)"
     7.9 +VOLUME_ID="$LABEL"
    7.10  PUBLISHER="Slitaz-$1"
    7.11  APPLICATION="Slitaz-$1"
    7.12  EXT="xz"
    7.13 -COMPRESSION="xz -Xbcj x86"
    7.14 +COMPRESSION="-comp xz -Xbcj x86"
    7.15  WORKING="$PROFILE/working"
    7.16  INITRAMFS="$WORKING/initramfs"
    7.17  UNION="$WORKING/union"
    7.18 @@ -42,8 +43,9 @@
    7.19  SOURCES_REPOSITORY="$LOCAL_REPOSITORY/src"
    7.20  HG_LIST="flavors flavors-stable slitaz-base-files slitaz-boot-scripts \
    7.21   slitaz-configs slitaz-dev-tools slitaz-doc slitaz-doc-wiki-data slitaz-forge \
    7.22 - slitaz-modular slitaz-pizza slitaz-tools tazlito tazpanel tazpkg tazusb tazweb \
    7.23 - tazwok website wok wok-stable wok-tiny wok-undigest"
    7.24 + slitaz-modular slitaz-pizza slitaz-tools slitaz-vz ssfs tazlito tazpanel \
    7.25 + tazpkg tazusb tazweb tazwok tiny-slitaz website wok wok-stable \
    7.26 + wok-tiny wok-undigest"
    7.27  
    7.28  error () { echo -e "\033[1;31;40m!!! \033[1;37;40m$@\033[1;0m"; }
    7.29  warn ()  { echo -e "\033[1;33;40m*** \033[1;37;40m$@\033[1;0m"; }
    7.30 @@ -82,7 +84,7 @@
    7.31  
    7.32  look_for_dep()
    7.33  {
    7.34 -		grep -m1 ^$1$'\t' $INCOMING_REPOSITORY/wok-depends.txt | \
    7.35 +		grep -m1 ^$1$'\t' $INCOMING_REPOSITORY/depends.txt | \
    7.36  			cut -f 2 | sed 's|^[ \t]*||g' | sed 's| |\n|g' | sed '/^$/d'
    7.37  }
    7.38  
    7.39 @@ -117,7 +119,7 @@
    7.40  
    7.41  	info "Making bootable image"
    7.42  	cat "$BASEDIR/initramfs/initramfs.list" | grep -v "^#" | while read pkgname; do
    7.43 -		if [ ! -f ${INITRAMFS}/var/lib/tazpkg/installed/${pkgname}/files.list ]; then
    7.44 +		if [ ! -f ${INITRAMFS}${INSTALLED}/${pkgname}/files.list ]; then
    7.45  			tazpkg get-install $pkgname --root=$INITRAMFS | tee -a $LOG/initramfs.log
    7.46  			if [ ! $(grep -l "^${pkgname}$" $ISODIR/packages-order.txt) ]; then
    7.47  				echo "$pkgname" >> $ISODIR/packages-order.txt
    7.48 @@ -197,7 +199,7 @@
    7.49  		done
    7.50  		[ -d $CUR_DIR ] || mkdir $CUR_DIR
    7.51  		md5sum $PKGNAME.tazpkg > $PKGNAME/fs/$INSTALLED/$PACKAGE/pkgmd5
    7.52 -		create_module $PKGNAME/fs $CUR_DIR/$PKGNAME.$EXT /var/lib/tazpkg/installed
    7.53 +		create_module $PKGNAME/fs $CUR_DIR/$PKGNAME.$EXT $INSTALLED
    7.54  	fi
    7.55  }
    7.56  
    7.57 @@ -224,7 +226,7 @@
    7.58  	#	fi
    7.59  	#fi
    7.60  	[ -f "$2" ] && rm -f "$2" # overwrite, never append to existing file
    7.61 -	mksquashfs "$1" "$2" -b 256K -comp $COMPRESSION >/dev/null
    7.62 +	mksquashfs "$1" "$2" -b 256K $COMPRESSION >/dev/null
    7.63  	if [ $? -ne 0 ]; then return 1; fi
    7.64  	chmod a-wx "$2" # remove execute and write attrib
    7.65  	chmod a+r "$2" # add read for everyone
    7.66 @@ -314,7 +316,7 @@
    7.67  	fi
    7.68  	
    7.69  	[ -d $INCOMING_REPOSITORY ] || mkdir -p $INCOMING_REPOSITORY
    7.70 -	tazwok gen-wok-db --WOK=$SLITAZ_DIR/repos/wok
    7.71 +	cooker gen-wok-db $SLITAZ_DIR/repos/wok-tank
    7.72  
    7.73  	local i
    7.74  	for flavors in $FLAVORS_LIST; do
    7.75 @@ -328,56 +330,114 @@
    7.76  backup_pkg() {
    7.77  	if [ "${BACKUP_PACKAGES}" = "yes" ]; then
    7.78  		[ -d $PKGISO_DIR ] && rm -r $PKGISO_DIR
    7.79 +		[ -f $LOG/backup_pkg.log ] && rm -rf $LOG/backup_pkg.log
    7.80  		mkdir -p $PKGISO_DIR
    7.81 -		WOK=${HG_DIR}/wok/home/slitaz/repos/wok
    7.82  		info "Making cooking list based installed packages in union"
    7.83  		# this is to filter out packages build by get- 
    7.84  		# packages that don't exist in repo or wok
    7.85 -		cat $ISODIR/packages-order.txt | while read pkg; do
    7.86 +		cat $ISODIR/packages-installed.list | while read pkg; do
    7.87  			if [ ! -f $WOK/$pkg/receipt ]; then
    7.88 -				sed -i "s|^${pkg}$||g" $ISODIR/packages-order.txt
    7.89 +				sed -i "s|$pkg||g" $ISODIR/packages-installed.list
    7.90  			fi
    7.91  		done
    7.92 -		tazwok gen-cooklist $ISODIR/packages-order.txt > $ISODIR/cookorder.list
    7.93 -		[ -f $INCOMING_REPOSITORY/wok-wanted.txt ] || tazwok gen-wok-db
    7.94 +		local pkg wanted rwanted pkg_VERSION incoming_pkg_VERSION cache_pkg_VERSION
    7.95 +		cook gen-cooklist $ISODIR/packages-installed.list > $ISODIR/cookorder.list
    7.96 +		[ -f $PKGS/fullco.txt ] || cook gen-wok-db $WOKHG
    7.97 +		cookorder=$ISODIR/cookorder.list
    7.98 +		[ "$BACKUP_ALL" = "yes" ] && cookorder=$PKGS/fullco.txt
    7.99 +		[ "$BACKUP_ALL" = "yes" ] && cp -a $cookorder $PKGISO_DIR/fullco.txt
   7.100 +		CACHE_REPOSITORY="$CACHE_DIR/$(cat /etc/slitaz-release)/packages"
   7.101 +		[ -f $PROFILE/list/backupall.banned ] && cp -a $PROFILE/list/backupall.banned $ISODIR/blocked
   7.102  		
   7.103 -		CACHE_REPOSITORY="$CACHE_DIR/$(cat /etc/slitaz-release)/packages"
   7.104 -
   7.105 -		cat $ISODIR/cookorder.list | grep -v "^#" | while read pkg; do
   7.106 -			rwanted=$(grep $'\t'$pkg$ $INCOMING_REPOSITORY/wok-wanted.txt | cut -f 1)
   7.107 +		cat $cookorder | grep -v "^#" | while read pkg; do
   7.108 +			[ -f "$WOK/$pkg/receipt" ] || continue
   7.109 +			unset rwanted pkg_VERSION incoming_pkg_VERSION cache_pkg_VERSION
   7.110 +			rwanted=$(grep $'\t'$pkg$ $PKGS/wanted.txt | cut -f 1)
   7.111  			pkg_VERSION="$(grep -m1 -A1 ^$pkg$ $PACKAGES_REPOSITORY/packages.txt | \
   7.112  				tail -1 | sed 's/ *//')"
   7.113  			incoming_pkg_VERSION="$(grep -m1 -A1 ^$pkg$ $INCOMING_REPOSITORY/packages.txt | \
   7.114  				tail -1 | sed 's/ *//')"
   7.115 +			cache_pkg_VERSION="$(grep -m1 -A1 ^$pkg$ $LOCALSTATE/packages.txt | \
   7.116 +					tail -1 | sed 's/ *//')"
   7.117  			for wanted in $rwanted; do
   7.118 +				if [ -f $PROFILE/list/backupall.banned ]; then
   7.119 +					if [ "$BACKUP_ALL" = "yes" ]; then
   7.120 +						[ $(grep -l "^$wanted$" $PROFILE/list/backupall.banned) ] && continue
   7.121 +					fi
   7.122 +				fi
   7.123 +
   7.124  				if [ -f $INCOMING_REPOSITORY/$wanted-$incoming_pkg_VERSION.tazpkg ]; then
   7.125 +					info "Backing up $INCOMING_REPOSITORY/$wanted-$incoming_pkg_VERSION.tazpkg" | tee -a $LOG/backup_pkg.log
   7.126  					ln -sf $INCOMING_REPOSITORY/$wanted-$incoming_pkg_VERSION.tazpkg $PKGISO_DIR/$wanted-$incoming_pkg_VERSION.tazpkg
   7.127  				elif [ -f $PACKAGES_REPOSITORY/$wanted-$pkg_VERSION.tazpkg ]; then
   7.128 +					info "Backing up $PACKAGES_REPOSITORY/$wanted-$pkg_VERSION.tazpkg" | tee -a $LOG/backup_pkg.log
   7.129  					ln -sf $PACKAGES_REPOSITORY/$wanted-$pkg_VERSION.tazpkg $PKGISO_DIR/$wanted-$pkg_VERSION.tazpkg
   7.130 -				elif [ -f $CACHE_REPOSITORY/$Wanted-$pkg_VERSION.tazpkg ]; then
   7.131 -					ln -sf $CACHE_REPOSITORY/$wanted-$pkg_VERSION.tazpkg $PKGISO_DIR/$wanted-$pkg_VERSION.tazpkg
   7.132 +				elif [ -f $CACHE_REPOSITORY/$Wanted-$cache_pkg_VERSION.tazpkg ]; then
   7.133 +					info "Backing up $CACHE_REPOSITORY/$wanted-$cache_pkg_VERSION.tazpkg" | tee -a $LOG/backup_pkg.log
   7.134 +					ln -sf $CACHE_REPOSITORY/$wanted-$cache_pkg_VERSION.tazpkg $PKGISO_DIR/$wanted-$cache_pkg_VERSION.tazpkg
   7.135  				fi
   7.136  			done
   7.137 -		
   7.138 -			for i in $(ls $WOK/$pkg/receipt); do
   7.139 -				unset SOURCE TARBALL WANTED PACKAGE VERSION pkg_VERSION COOK_OPT
   7.140 -				source $i
   7.141 -				pkg_VERSION="$(grep -m1 -A1 ^$PACKAGE$ $PACKAGES_REPOSITORY/packages.txt | \
   7.142 -					tail -1 | sed 's/ *//')"
   7.143 -				incoming_pkg_VERSION="$(grep -m1 -A1 ^$pkg$ $INCOMING_REPOSITORY/packages.txt | \
   7.144 -					tail -1 | sed 's/ *//')"
   7.145 -				[ "$WGET_URL" ] || continue
   7.146 -				if [ -f $INCOMING_REPOSITORY/$PACKAGE-$incoming_pkg_VERSION.tazpkg ]; then
   7.147 -					ln -sf $INCOMING_REPOSITORY/$PACKAGE-$incoming_pkg_VERSION.tazpkg $PKGISO_DIR/$PACKAGE-$incoming_pkg_VERSION.tazpkg
   7.148 -				elif [ -f $PACKAGES_REPOSITORY/$PACKAGE-$pkg_VERSION.tazpkg ]; then
   7.149 -					ln -sf $PACKAGES_REPOSITORY/$PACKAGE-$pkg_VERSION.tazpkg $PKGISO_DIR/$PACKAGE-$pkg_VERSION.tazpkg
   7.150 -				elif [ -f $CACHE_REPOSITORY/$PACKAGE-$pkg_VERSION.tazpkg ]; then
   7.151 -					ln -sf $CACHE_REPOSITORY/$PACKAGE-$pkg_VERSION.tazpkg $PKGISO_DIR/$PACKAGE-$pkg_VERSION.tazpkg
   7.152 +			
   7.153 +			if [ -f $PROFILE/list/backupall.banned ]; then
   7.154 +				if [ "$BACKUP_ALL" = "yes" ]; then
   7.155 +					[ $(grep -l "^$pkg$" $PROFILE/list/backupall.banned) ] && continue
   7.156  				fi
   7.157 -			done
   7.158 +			fi
   7.159 +			
   7.160 +			if [ -f $INCOMING_REPOSITORY/$pkg-$incoming_pkg_VERSION.tazpkg ]; then
   7.161 +				info "Backing up $INCOMING_REPOSITORY/$pkg-$incoming_pkg_VERSION.tazpkg" | tee -a $LOG/backup_pkg.log
   7.162 +				ln -sf $INCOMING_REPOSITORY/$pkg-$incoming_pkg_VERSION.tazpkg $PKGISO_DIR/$pkg-$incoming_pkg_VERSION.tazpkg
   7.163 +			elif [ -f $PACKAGES_REPOSITORY/$pkg-$pkg_VERSION.tazpkg ]; then
   7.164 +				info "Backing up $PACKAGES_REPOSITORY/$pkg-$pkg_VERSION.tazpkg" | tee -a $LOG/backup_pkg.log
   7.165 +				ln -sf $PACKAGES_REPOSITORY/$pkg-$pkg_VERSION.tazpkg $PKGISO_DIR/$pkg-$pkg_VERSION.tazpkg
   7.166 +			elif [ -f $CACHE_REPOSITORY/$pkg-$cache_pkg_VERSION.tazpkg ]; then
   7.167 +				info "Backing up $CACHE_REPOSITORY/$pkg-$cache_pkg_VERSION.tazpkg" | tee -a $LOG/backup_pkg.log
   7.168 +				ln -sf $CACHE_REPOSITORY/$pkg-$cache_pkg_VERSION.tazpkg $PKGISO_DIR/$pkg-$cache_pkg_VERSION.tazpkg
   7.169 +			fi
   7.170  		done
   7.171  		
   7.172 -		[ -d $PKGISO_DIR ] && tazwok gen-list $PKGISO_DIR
   7.173 +		if [ "$SRC_PKG" = "yes" ]; then
   7.174 +			cat $cookorder | grep -v "^#" | while read pkg; do
   7.175 +				[ -f "$WOK/$pkg/receipt" ] || continue
   7.176 +				[ $(grep ^$pkg$ $PROFILE/list/srcpkg.banned) ] && continue
   7.177 +				for i in $(grep -l "^SOURCE=\"$pkg\"" $WOK/*/receipt); do
   7.178 +					unset SOURCE TARBALL WANTED PACKAGE VERSION COOK_OPT WGET_URL
   7.179 +					unset pkg_VERSION incoming_pkg_VERSION cache_pkg_VERSION src_pkg src_ver 
   7.180 +					#source $i
   7.181 +					src_pkg=$(grep ^PACKAGE= $WOK/$pkg/receipt | cut -d "=" -f 2 | sed -e 's/"//g')
   7.182 +					src_ver=$(grep ^VERSION= $WOK/$pkg/receipt | cut -d "=" -f 2 | sed -e 's/"//g')
   7.183 +					[ "$VERSION" = "$src_ver" ] || continue
   7.184 +					pkg_VERSION="$(grep -m1 -A1 ^$src_pkg$ $PACKAGES_REPOSITORY/packages.txt | \
   7.185 +						tail -1 | sed 's/ *//')"
   7.186 +					incoming_pkg_VERSION="$(grep -m1 -A1 ^$src_pkg$ $INCOMING_REPOSITORY/packages.txt | \
   7.187 +						tail -1 | sed 's/ *//')"
   7.188 +					cache_pkg_VERSION="$(grep -m1 -A1 ^$src_pkg$ $LOCALSTATE/packages.txt | \
   7.189 +						tail -1 | sed 's/ *//')"
   7.190 +					rwanted=$(grep $'\t'$src_pkg$ $PKGS/wanted.txt | cut -f 1)
   7.191 +					
   7.192 +					for wanted in $rwanted; do
   7.193 +						if [ -f $INCOMING_REPOSITORY/$wanted-$incoming_pkg_VERSION.tazpkg ]; then
   7.194 +							ln -sf $INCOMING_REPOSITORY/$wanted-$incoming_pkg_VERSION.tazpkg $PKGISO_DIR/$wanted-$incoming_pkg_VERSION.tazpkg
   7.195 +						elif [ -f $PACKAGES_REPOSITORY/$wanted-$pkg_VERSION.tazpkg ]; then
   7.196 +							ln -sf $PACKAGES_REPOSITORY/$wanted-$pkg_VERSION.tazpkg $PKGISO_DIR/$wanted-$pkg_VERSION.tazpkg
   7.197 +						elif [ -f $CACHE_REPOSITORY/$Wanted-$pkg_VERSION.tazpkg ]; then
   7.198 +							ln -sf $CACHE_REPOSITORY/$wanted-$pkg_VERSION.tazpkg $PKGISO_DIR/$wanted-$pkg_VERSION.tazpkg
   7.199 +						fi
   7.200 +					done
   7.201 +					
   7.202 +					if [ -f $INCOMING_REPOSITORY/$PACKAGE-$incoming_pkg_VERSION.tazpkg ]; then
   7.203 +						ln -sf $INCOMING_REPOSITORY/$PACKAGE-$incoming_pkg_VERSION.tazpkg $PKGISO_DIR/$PACKAGE-$incoming_pkg_VERSION.tazpkg
   7.204 +					elif [ -f $PACKAGES_REPOSITORY/$PACKAGE-$pkg_VERSION.tazpkg ]; then
   7.205 +						ln -sf $PACKAGES_REPOSITORY/$PACKAGE-$pkg_VERSION.tazpkg $PKGISO_DIR/$PACKAGE-$pkg_VERSION.tazpkg
   7.206 +					elif [ -f $CACHE_REPOSITORY/$PACKAGE-$cache_pkg_VERSION.tazpkg ]; then
   7.207 +						ln -sf $CACHE_REPOSITORY/$PACKAGE-$cache_pkg_VERSION.tazpkg $PKGISO_DIR/$PACKAGE-$cache_pkg_VERSION.tazpkg
   7.208 +					fi
   7.209 +				done
   7.210 +			done
   7.211 +		fi
   7.212 +		
   7.213 +		[ -f $LOG/packages-gen-list.log ] && rm -f $LOG/packages-gen-list.log
   7.214 +		[ -d $PKGISO_DIR ] && cook pkgdb $PKGISO_DIR | tee -a $LOG/packages-gen-list.log
   7.215  	fi
   7.216  	
   7.217  }
   7.218 @@ -385,46 +445,68 @@
   7.219  backup_src() {
   7.220  
   7.221  	if [ "${BACKUP_PACKAGES}" = "yes" -a "${BACKUP_SOURCES}" = "yes" ]; then
   7.222 -			[ -d $SOURCES_REPOSITORY ] || mkdir -p $SOURCES_REPOSITORY
   7.223 -			[ -d $SRCISO_DIR ] && rm -r $SRCISO_DIR
   7.224 -			mkdir -p $SRCISO_DIR
   7.225 -			WOK=${HG_DIR}/wok/home/slitaz/repos/wok
   7.226 -			cat $ISODIR/cookorder.list | grep -v "^#"| while read pkg; do
   7.227 -				#rwanted=$(grep $'\t'$pkg$ $INCOMING_REPOSITORY/wok-wanted.txt | cut -f 1)
   7.228 -				for i in $(ls $WOK/$pkg/receipt); do
   7.229 -					unset SOURCE TARBALL WANTED PACKAGE VERSION COOK_OPT
   7.230 -					source $i
   7.231 -					{ [ ! "$TARBALL" ] || [ ! "$WGET_URL" ] ; } && continue
   7.232 -					if [ ! -f "$SOURCES_REPOSITORY/$TARBALL" ] && \
   7.233 -						[ ! -f "$SOURCES_REPOSITORY/${SOURCE:-$PACKAGE}-$VERSION.tar.lzma" ]; then
   7.234 -						tazwok get-src $PACKAGE --nounpack
   7.235 -						if [ -f "$SOURCES_REPOSITORY/$TARBALL" ]; then
   7.236 -							ln -sf $SOURCES_REPOSITORY/$TARBALL $SRCISO_DIR/$TARBALL
   7.237 -						elif [ -f "$SOURCES_REPOSITORY/${SOURCE:-$PACKAGE}-$VERSION.tar.lzma" ]; then
   7.238 -							ln -sf $SOURCES_REPOSITORY/${SOURCE:-$PACKAGE}-$VERSION.tar.lzma $SRCISO_DIR/${SOURCE:-$PACKAGE}-$VERSION.tar.lzma
   7.239 -						fi
   7.240 -					else
   7.241 -						[ -f "$SOURCES_REPOSITORY/$TARBALL" ] && ln -sf $SOURCES_REPOSITORY/$TARBALL $SRCISO_DIR/$TARBALL
   7.242 -						[ -f "$SOURCES_REPOSITORY/${SOURCE:-$PACKAGE}-$VERSION.tar.lzma" ] && ln -sf $SOURCES_REPOSITORY/${SOURCE:-$PACKAGE}-$VERSION.tar.lzma $SRCISO_DIR/${SOURCE:-$PACKAGE}-$VERSION.tar.lzma
   7.243 +		[ -d $SOURCES_REPOSITORY ] || mkdir -p $SOURCES_REPOSITORY
   7.244 +		[ -d $SRCISO_DIR ] && rm -r $SRCISO_DIR
   7.245 +		mkdir -p $SRCISO_DIR
   7.246 +		local pkg cookorder pkg_VERSION
   7.247 +		cookorder=$ISODIR/cookorder.list
   7.248 +		[ "$BACKUP_ALL" = "yes" ] && cookorder=$PKGS/fullco.txt
   7.249 +		[ -f $LOG/cook-getsrc.log ] && rm -rf $LOG/cook-getsrc.log
   7.250 +		[ -f $LOG/backup_src.log ] && rm -rf $LOG/backup_src.log
   7.251 +		cat $cookorder | grep -v "^#" | while read pkg; do
   7.252 +			if [ -f $PROFILE/list/backupall.banned ]; then
   7.253 +				if [ "$BACKUP_ALL" = "yes" ]; then
   7.254 +					[ $(grep -l "^$pkg$" $PROFILE/list/backupall.banned) ] && continue
   7.255 +				fi
   7.256 +			fi
   7.257 +			unset PATCH SOURCE TARBALL WANTED PACKAGE VERSION COOK_OPT WGET_URL KBASEVER
   7.258 +			unset pkg_VERSION
   7.259 +			[ -f $WOK/$pkg/receipt ] || continue
   7.260 +			source $WOK/$pkg/receipt
   7.261 +			[ "$WGET_URL" ] || continue
   7.262 +			[ "$TARBALL" ] || continue
   7.263 +			pkg_VERSION="$(grep -m1 -A1 ^$pkg$ $PKGISO_DIR/packages.txt | \
   7.264 +				tail -1 | sed 's/ *//')"
   7.265 +			[ -f "$PKGISO_DIR/$PACKAGE-$pkg_VERSION.tazpkg" ] || continue
   7.266 +			#{ [ ! "$TARBALL" ] || [ ! "$WGET_URL" ] ; } && continue
   7.267 +			LZMA_TARBALL="${SOURCE:-$PACKAGE}-${KBASEVER:-$VERSION}.tar.lzma"
   7.268 +			if [ "$PATCH" ]; then
   7.269 +				if [ -f "$SOURCES_REPOSITORY/$(basename $PATCH)" ]; then
   7.270 +					info "Backing up $SOURCES_REPOSITORY/$(basename $PATCH)" | tee -a $LOG/backup_src.log
   7.271 +					ln -sf $SOURCES_REPOSITORY/$(basename $PATCH) $SRCISO_DIR/$(basename $PATCH)
   7.272 +				else
   7.273 +					cook $PACKAGE --getsrc | tee -a $LOG/cook-getsrc.log
   7.274 +					if [ -f "$SOURCES_REPOSITORY/$(basename $PATCH)" ]; then
   7.275 +						info "Backing up $SOURCES_REPOSITORY/$(basename $PATCH)" | tee -a $LOG/backup_src.log
   7.276 +						ln -sf $SOURCES_REPOSITORY/$(basename $PATCH) $SRCISO_DIR/$(basename $PATCH)
   7.277  					fi
   7.278 -				done
   7.279 -			done
   7.280 -			cd $SRCISO_DIR
   7.281 -			info "Make md5sum file for sources"
   7.282 -			find * -not -type d | grep -v md5sum | xargs md5sum > md5sum
   7.283 -			cd $WORKING
   7.284 +				fi
   7.285 +			fi
   7.286 +			if [ -f "$SOURCES_REPOSITORY/$LZMA_TARBALL" ]; then
   7.287 +				info "Backing up $SOURCES_REPOSITORY/$LZMA_TARBALL" | tee -a $LOG/backup_src.log
   7.288 +				ln -sf $SOURCES_REPOSITORY/$LZMA_TARBALL $SRCISO_DIR/$LZMA_TARBALL
   7.289 +			elif [ -f "$SOURCES_REPOSITORY/$TARBALL" ]; then
   7.290 +				info "Backing up $SOURCES_REPOSITORY/$TARBALL" | tee -a $LOG/backup_src.log
   7.291 +				ln -sf $SOURCES_REPOSITORY/$TARBALL $SRCISO_DIR/$TARBALL
   7.292 +			else
   7.293 +				cook $PACKAGE --getsrc | tee -a $LOG/cook-getsrc.log
   7.294 +				if [ -f "$SOURCES_REPOSITORY/$TARBALL" ]; then
   7.295 +					info "Backing up $SOURCES_REPOSITORY/$TARBALL" | tee -a $LOG/backup_src.log
   7.296 +					ln -sf $SOURCES_REPOSITORY/$TARBALL $SRCISO_DIR/$TARBALL
   7.297 +				elif [ -f "$SOURCES_REPOSITORY/$LZMA_TARBALL" ]; then
   7.298 +					info "Backing up $SOURCES_REPOSITORY/$LZMA_TARBALL" | tee -a $LOG/backup_src.log
   7.299 +					ln -sf $SOURCES_REPOSITORY/$LZMA_TARBALL $SRCISO_DIR/$LZMA_TARBALL
   7.300 +				fi
   7.301 +			fi
   7.302 +		done
   7.303 +		cd $SRCISO_DIR
   7.304 +		info "Make md5sum file for sources"
   7.305 +		find * -not -type d | grep -v md5sum | xargs md5sum > md5sum
   7.306 +		cd $WORKING
   7.307  	fi
   7.308  	
   7.309  }
   7.310  
   7.311 -backup_all()
   7.312 -{
   7.313 -	if [ "${BACKUP_ALL}" = "yes" ]; then
   7.314 -		[ -d $SRCISO_DIR ] || ln -sf $SOURCES_REPOSITORY $SRCISO_DIR
   7.315 -		[ -d $PKGISO_DIR ] || ln -sf $PACKAGES_REPOSITORY $PKGISO_DIR
   7.316 -	fi
   7.317 -}
   7.318 -
   7.319  imgcommon () {
   7.320  	
   7.321  	build_modules
   7.322 @@ -438,16 +520,20 @@
   7.323  		fi
   7.324  	fi
   7.325  	
   7.326 -	[ -d $SRCISO_DIR ] && rm -r $SRCISO_DIR
   7.327 -	[ -d $PKGISO_DIR ] && rm -r $PKGISO_DIR
   7.328 -	
   7.329 -	if [ -d ${HG_DIR}/wok ]; then
   7.330 -		backup_pkg
   7.331 -		backup_src
   7.332 +	if [ "$DONT_UPDATE_MIRROR" = "no" ]; then
   7.333 +		[ -d $SRCISO_DIR ] && rm -r $SRCISO_DIR
   7.334 +		[ -d $PKGISO_DIR ] && rm -r $PKGISO_DIR	
   7.335 +		if [ -d ${HG_DIR}/wok-tank/repos/wok-tank/.hg ]; then
   7.336 +			WOK=${HG_DIR}/wok-tank/repos/wok-tank
   7.337 +			backup_pkg
   7.338 +			backup_src
   7.339 +		elif [ -d ${HG_DIR}/wok/repos/wok/.hg ]; then
   7.340 +			WOK=${HG_DIR}/wok/repos/wok
   7.341 +			backup_pkg
   7.342 +			backup_src
   7.343 +		fi
   7.344  	fi
   7.345  	
   7.346 -	backup_all
   7.347 -	
   7.348  	info "====> Making bootable image"
   7.349  
   7.350  	# Sanity checks
   7.351 @@ -496,11 +582,11 @@
   7.352  	fi
   7.353  
   7.354  	info "Creating ISO image..."
   7.355 -	genisoimage -R -l -f -o $IMGNAME -b boot/isolinux/isolinux.bin \
   7.356 +	genisoimage -R -l -f -V $VOLUME_ID -o $IMGNAME -b boot/isolinux/isolinux.bin \
   7.357  	-c boot/isolinux/boot.cat -no-emul-boot -boot-load-size 4 \
   7.358  	-uid 0 -gid 0 \
   7.359  	-udf -allow-limited-size -iso-level 3 \
   7.360 -	-V "SliTaz" -input-charset utf-8 -boot-info-table $ISODIR
   7.361 +	-P $PUBLISHER -input-charset utf-8 -boot-info-table $ISODIR
   7.362  	if [ -x /usr/bin/isohybrid ]; then
   7.363  		info "Creating hybrid ISO..."
   7.364  		isohybrid "${IMGNAME}"