Attachment 'instance.patch'

Download

   1 diff -r fa6e150cec23 contrib/createinstance/README.txt
   2 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
   3 +++ b/contrib/createinstance/README.txt	Sun May 06 18:24:13 2007 +0200
   4 @@ -0,0 +1,29 @@
   5 +README Wiki Instance Creation
   6 +
   7 +After you have downloaded and installed MoinMoin, you will want to "have a wiki".
   8 +You can use the contributed "createinstance.sh" bash script to install the instance.
   9 +
  10 +*How to use*
  11 +
  12 + 1. Copy the script to your home directory (or $HOME/bin)
  13 +
  14 + 2. Edit the script
  15 +
  16 +You should define the following variables inside the script:
  17 +
  18 +The path of MoinMoin shared files:
  19 +SHARE=/usr/share/moin
  20 +
  21 +Define the user and the group of the web server:
  22 +USER=www-data
  23 +GROUP=www-data
  24 +
  25 + 3. Make it executable: 
  26 +    "chmod u+x createinstance.sh"
  27 +
  28 + 4. Think about where you want the instance to be located. Like:
  29 +    "/usr/local/share/moin-instance"
  30 +
  31 + 4. Run the script with superuser rights like:
  32 +    "sudo ./createinstance.sh /usr/local/share/moin-instance"
  33 + 
  34 diff -r fa6e150cec23 contrib/createinstance/createinstance.sh
  35 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
  36 +++ b/contrib/createinstance/createinstance.sh	Sun May 06 18:40:08 2007 +0200
  37 @@ -0,0 +1,38 @@
  38 +#!/bin/bash
  39 +
  40 +# path of MoinMoin shared files
  41 +SHARE=/usr/share/moin
  42 +
  43 +# path to target instance location
  44 +INSTANCE=$1
  45 +
  46 +# the user and the group of the web server.
  47 +USER=www-data
  48 +GROUP=www-data
  49 +
  50 +if [ ! $1 ]
  51 +then
  52 +  echo "You must specify an instance (relative or absolute path)"
  53 +  exit
  54 +fi
  55 +
  56 +if [[ -e $1 || -d $1 ]]
  57 +then
  58 +  echo "$1 already exists"
  59 +  exit
  60 +fi
  61 +
  62 +mkdir -p $INSTANCE
  63 +cp -R $SHARE/data $INSTANCE
  64 +cp -R $SHARE/underlay $INSTANCE
  65 +cp $SHARE/config/wikiconfig.py $INSTANCE
  66 +
  67 +chown -R $USER:$GROUP $INSTANCE
  68 +chmod -R ug+rwX $INSTANCE
  69 +chmod -R o-rwx $INSTANCE
  70 +
  71 +if [ $? ]
  72 +then
  73 +  echo "Done."
  74 +fi
  75 +
  76 

Attached Files

To refer to attachments on a page, use attachment:filename, as shown below in the list of files. Do NOT use the URL of the [get] link, since this is subject to change and can break easily.
  • [get | view] (2007-05-06 16:42:08, 1.8 KB) [[attachment:instance.patch]]
 All files | Selected Files: delete move to page copy to page

You are not allowed to attach a file to this page.