|
generating Package download entries automatically: msg#00011package-management.wpkg.user
Hi I've made some shell scripts for our samba server to automatically generate the package download entries for our environment which is configured like this: 1. [wpkg] samba share pointing to /usr/wpkg, where wpkg.js is located. 2. pkg directory in [wpkg] share where every package gets its own directory. e.g. Acrobat Reader is in [wpkg]\pkg\acrobat 3. Soft linked /usr/wpkg/pkg to Apaches DocumentRoot/pkg, so you can get packages like this: http://apache/pkg/acrobat/[filename.ext] 4. Made an Unix shell script called md5gen.sh which can be called in /usr/wpkg/pkg. This will output XML for use in packages.xml for every package in this directory. It will do some kind of paging with the output so you can cut&paste it into the right place in the packages.xml file. Further automation can be done by automatically generating the whole packages.xml (maybe by having standard install.js scripts in every package or thelike to allow standard <install> cmds). The urlprefix variable in md5gen.sh should point to your URL prefix for the package download urls. --[md5gen.sh]-----------8<----------------------------------------------- #!/bin/sh # generate WPKG xml code for downloading files urlprefix="http://www.mikisoft.com/pkg" for packname in *; do echo "Package: $packname" echo cd $packname for i in * ; do sum=`md5 -q "$i"` echo "<file name=\"$i\" timeout=\"600\" md5=\"$sum\">" echo " <source url=\"$urlprefix/$packname/$i\" />" echo "</file>" done cd - echo -n "Show next entry? <Enter>=Yes <Ctrl>+<c>=No " echo read bla done ------------------------------------------------->8--------------------- Hope its useful for someone. :) Greets, Andre
|
|
| <Prev in Thread] | Current Thread | [Next in Thread> |
|---|---|---|
| Previous by Date: | Re[2]: Make Firefox the default browser?: 00011, Jean-Jacques Moulis |
|---|---|
| Next by Date: | Re: Package Download patch: 00011, Stian Husemoen |
| Previous by Thread: | Re: Make Firefox the default browser?i: 00011, Matt Miller |
| Next by Thread: | Package download patch improved: 00011, Andre Ilie |
| Indexes: | [Date] [Thread] [Top] [All Lists] |
| News | FAQ | advertise |