From 8de9d28f6528c9272da5eccb9321a60dc324ce9c Mon Sep 17 00:00:00 2001 From: paulr Date: Mon, 12 Jul 2010 11:18:42 +1000 Subject: [PATCH] wrote a quick install script, and made a global config file for where to find files... --- bin/pbdc | 2 +- bin/pbdc-bacula | 2 +- bin/pbdc-bacula.php | 7 ++++--- bin/pbdc.php | 6 +++--- install.sh | 33 +++++++++++++++++++++++++++++++++ 5 files changed, 42 insertions(+), 8 deletions(-) create mode 100644 install.sh diff --git a/bin/pbdc b/bin/pbdc index 1868fda..9e42b07 100644 --- a/bin/pbdc +++ b/bin/pbdc @@ -2,4 +2,4 @@ . /etc/pbdc.conf -php $BASE_DIR/pbdc.php $* \ No newline at end of file +php $BASE_DIR/bin/pbdc.php $* \ No newline at end of file diff --git a/bin/pbdc-bacula b/bin/pbdc-bacula index c85e579..f26a430 100644 --- a/bin/pbdc-bacula +++ b/bin/pbdc-bacula @@ -2,4 +2,4 @@ . /etc/pbdc.conf -php $BASE_DIR/pbdc-bacula.php $* \ No newline at end of file +php $BASE_DIR/bin/pbdc-bacula.php $* \ No newline at end of file diff --git a/bin/pbdc-bacula.php b/bin/pbdc-bacula.php index ac2ebcc..5225d49 100644 --- a/bin/pbdc-bacula.php +++ b/bin/pbdc-bacula.php @@ -1,7 +1,8 @@ > /etc/pbdc.conf << EOF +BASE_DIR=$install_base +BASE_LIB=$install_base/lib/ +BASE_DATA=$install_base/db/ +BACULA_USER="$user_id" + +export BACULA_USER BASE_DATA BASE_LIB BASE_DIR +EOF + +cp -rp bin/* $install_base/bin +cp -rp lib/* $install_base/lib +chown -R $install_base \ No newline at end of file -- 1.7.0.4