]> gitweb.fluxo.info Git - puppet-ikiwiki.git/commitdiff
Misc fixes
authorSilvio Rhatto <rhatto@riseup.net>
Mon, 25 Jan 2010 20:03:50 +0000 (18:03 -0200)
committerSilvio Rhatto <rhatto@riseup.net>
Mon, 25 Jan 2010 20:03:50 +0000 (18:03 -0200)
manifests/init.pp
templates/deploy.sh.erb

index 39acc0429264d8236916e9322ab6d0e5f4b91e82..2661953b17c43d200a3c2af4d55e2105ac02ac51 100644 (file)
@@ -19,6 +19,7 @@ class ikiwiki {
                   $adminuser = 'yourname', $adminemail = 'me@example.org', $instance = 'ikiwiki') {
 
     $desc = $decription ? {
+      ''      => $title,
       false   => $title,
       default => $description,
     }
index 69785d07cf7f4ef9f203687e04eb07cf071091a7..5386729706a22bf936fcd6a9dc98b3a2bff36c53 100644 (file)
@@ -6,7 +6,9 @@ BASE="<%= apache_sites_folder %>"
 SITE=$BASE/$NAME
 CONF="/etc/ikiwiki"
 OWNER="gitosis"
-GROUP="gitosis"
+WEB_GROUP="www-data"
+REPO_GROUP="gitosis"
+REPO="/var/git/repositories/$NAME.git"
 
 if [ -z "$INSTANCE" ]; then
   echo "Usage:`basename $0` <site> <instance>"
@@ -20,7 +22,7 @@ fi
 mkdir -p $SITE/"$INSTANCE"_src/
 
 # Create initial page
-echo > $SITE/"$INSTANCE"_src/index.mdw <<EOF
+echo > $SITE/"$INSTANCE"_src/index.mdwn <<EOF
 Welcome to your new wiki.
 
 All wikis are supposed to have a [[SandBox]], so this one does too.
@@ -31,10 +33,11 @@ This wiki is powered by [ikiwiki](http://ikiwiki.info).
 EOF
 
 # Create ikiwiki instance
-ikiwiki-makerepo git $SITE/"$INSTANCE"_src/ /var/git/repositories/$NAME.git
-touch /var/git/repositories/$NAME.git/git-daemon-export-ok
-( cd /var/git/repositories/$NAME.git && git --bare update-server-info )
+ikiwiki-makerepo git $SITE/"$INSTANCE"_src/ $REPO
+touch $REPO/git-daemon-export-ok
+( cd $REPO/$NAME.git && git --bare update-server-info )
 ikiwiki --setup /etc/ikiwiki/$NAME.setup
 
 # Set permissions
-chown -R $OWNER.$GROUP $SITE/"$INSTANCE"_src $SITE/$INSTANCE /var/git/repositories/$NAME.git
+chown -R $OWNER.$WEB_GROUP $SITE/"$INSTANCE"_src $SITE/$INSTANCE
+chown -R $OWNER.$REPO_GROUP $REPO