Don't remove htdocs

This commit is contained in:
Bob Mottram 2014-09-26 15:25:44 +01:00
parent 7b95c2b528
commit 06544bcdd3
1 changed files with 2 additions and 4 deletions

View File

@ -1870,6 +1870,8 @@ function install_wiki {
if [ ! -d /var/www/$WIKI_DOMAIN_NAME ]; then if [ ! -d /var/www/$WIKI_DOMAIN_NAME ]; then
mkdir /var/www/$WIKI_DOMAIN_NAME mkdir /var/www/$WIKI_DOMAIN_NAME
fi
if [ ! -d /var/www/$WIKI_DOMAIN_NAME/htdocs ]; then
mkdir /var/www/$WIKI_DOMAIN_NAME/htdocs mkdir /var/www/$WIKI_DOMAIN_NAME/htdocs
fi fi
@ -1897,10 +1899,6 @@ function install_wiki {
tar -xzvf $WIKI_ARCHIVE tar -xzvf $WIKI_ARCHIVE
cd dokuwiki-* cd dokuwiki-*
if [ -f "/var/www/$WIKI_DOMAIN_NAME/htdocs" ]; then
rm -rf /var/www/$WIKI_DOMAIN_NAME/htdocs
fi
mv * /var/www/$WIKI_DOMAIN_NAME/htdocs/ mv * /var/www/$WIKI_DOMAIN_NAME/htdocs/
chmod -R 755 /var/www/$WIKI_DOMAIN_NAME/htdocs chmod -R 755 /var/www/$WIKI_DOMAIN_NAME/htdocs
chown -R www-data:www-data /var/www/$WIKI_DOMAIN_NAME/htdocs chown -R www-data:www-data /var/www/$WIKI_DOMAIN_NAME/htdocs