Re: [Users] Installing Hyper Journal without root rights

Arnost Valicek Arnost.Valicek a seznam.cz
Dom 16 Ott 2005 22:57:37 CEST


> In principle it's possible(Piergiorgio and Antlon please confirm. They
> programmed most of the installer btw). We've never tried (did we?). You will
> have to set some file permissions, create directories and do similar things
> manually, instead of using the makefile. Unfortunately this is undocumented
> but the config.sh and the Makefile are really simple. If you want to try we
> will help you as much as we can.
> Best,
> michele

Hi Michele,

I made  script which should install HJ in user directory (~/public_html/...).  It is attached to this email, you can see what I have tried. 
This has one bug -  sed command doesn't work - I must do "sed" work substitutions manualy. When I do that, setup script works.

My problems in setup.php - are some of them crucial?: 
* I don't know mysql superuser password.
* my system isn't running sendmail (mail can't be send)
* I have no Sesame repository


After going through setup.php steps, I tried index.php and this error appears get this error:
exception 'DbException' with message 'DB Error: no such table' in /home/arnost/public_html/hjournal/classes/class.Utils.php:488 Stack trace: #0 /home/arnost/public_html/hjournal/classes/class.Utils.php(522): Utils::doQuery('SELECT * FROM h...', Array) #1 /home/arnost/public_html/hjournal/classes/class.HomeComposerBoxes.php(103): Utils::doQueryAndReturnArray('SELECT * FROM h...') #2 /home/arnost/public_html/hj_server/index.php(82): HomeComposerBoxes->load(Array, NULL) #3 {main}

I looks that there is problem with database. Configuration file "configuration.xml" contains right database name, login and password.

Any idea how to solve that? Thanks for any help.


Arnost

---------------------------------------------
#!/bin/bash

SOURCE_DIR=$PWD
TARGET_DIR=/home/arnost/public_html/hjournal
SERVER_DIR=/home/arnost/public_html/hj_server
INSTALL_DIR=/home/arnost/public_html/hjournal
HTACCESS=$SERVER_DIR/.htaccess

INSTALL_DIR_NS=`echo $INSTALL_DIR | sed -e "s/\/$//"`

cp -rp $SOURCE_DIR/* $INSTALL_DIR
cp $INSTALL_DIR/www/config.dist.php $INSTALL_DIR/www/config.php
mkdir -p $INSTALL_DIR/cache
mkdir -p $INSTALL_DIR/upload
mkdir -p $INSTALL_DIR/www/tmp
mkdir -p $INSTALL_DIR/www/captchatmp
mkdir -p $INSTALL_DIR/www/home
mkdir -p $INSTALL_DIR/www/home/local/admin

mv $INSTALL_DIR/www/* $SERVER_DIR/

#configuration XML file
sed s/{ABS_PATH}/'$INSTALL_DIR_NS\/'/ $INSTALL_DIR/configuration.dist.xml > $INSTALL_DIR/configuration.xml.tmp
#cp $INSTALL_DIR/configuration.xml $INSTALL_DIR/configuration.xml.bak
mv $INSTALL_DIR/configuration.xml.tmp $INSTALL_DIR/configuration.xml

#config.php
sed s/{CONFIG_FILE}/'$INSTALL_DIR_NS'/ $SERVER_DIR/config.php > $SERVER_DIR/config.php.tmp
cp $SERVER_DIR/config.php $SERVER_DIR/config.php.bak
mv $SERVER_DIR/config.php.tmp $SERVER_DIR/config.php

#setup.php
sed s/{CONFIG_FILE}/'$INSTALL_DIR_NS'/ $SERVER_DIR/setup.dist.php > $SERVER_DIR/setup.php


#ughh
chmod -R a+rwX $INSTALL_DIR
chmod -R a+rwX $SERVER_DIR

#htaccess
echo '# --BEGIN-HJ-DO-NOT-REMOVE-THIS-LINE--' >> $HTACCESS
echo 'RewriteEngine On' >> $HTACCESS
echo 'RewriteCond %{QUERY_STRING} ^view=html$$' >> $HTACCESS
echo 'RewriteRule ^/$(HJ_RELATIVE_PATH)/([^./]+)$$ $(SERVER_ROOT)/$(HJ_RELATIVE_PATH)/viewContributionWindow.php?siglum=$$1 [L]' >> $HTACCESS
echo 'RewriteRule ^/$(HJ_RELATIVE_PATH)/([^./]+)$$ $(SERVER_ROOT)/$(HJ_RELATIVE_PATH)/viewContribution.php?id=$$1 [L]' >> $HTACCESS
echo '# --END-HJ-DO-NOT-REMOVE-THIS-LINE--' >> $HTACCESS



Maggiori informazioni sulla lista Users