]> git.sur5r.net Git - bacula/bacula/commitdiff
Apply patch from Thomas Mueller that adds db parameters to config file
authorKern Sibbald <kern@sibbald.com>
Wed, 11 Jun 2008 08:07:49 +0000 (08:07 +0000)
committerKern Sibbald <kern@sibbald.com>
Wed, 11 Jun 2008 08:07:49 +0000 (08:07 +0000)
git-svn-id: https://bacula.svn.sourceforge.net/svnroot/bacula/trunk@7127 91ce42f0-d328-0410-95d8-f526ca767f89

26 files changed:
regress/prototype.conf
regress/scripts/bacula-dir-2client.conf.in
regress/scripts/bacula-dir-2d.conf.in
regress/scripts/bacula-dir-fifo.conf.in
regress/scripts/bacula-dir-migration.conf.in
regress/scripts/bacula-dir-strip.conf.in
regress/scripts/bacula-dir-tape.conf.in
regress/scripts/bacula-dir-vtape.conf.in
regress/scripts/bacula-dir-win32-tape.conf.in
regress/scripts/bacula-dir.conf.accurate.in
regress/scripts/bacula-dir.conf.errors.in
regress/scripts/bacula-dir.conf.maxtime.in
regress/scripts/bacula-dir.conf.regexwhere.in
regress/scripts/bacula-dir.conf.testrunscript.in
regress/scripts/create_sed
regress/scripts/do_sed
regress/scripts/multi-client-bacula-dir.conf.in
regress/scripts/new-test-bacula-dir.conf.in
regress/scripts/regress-config
regress/scripts/test-bacula-dir.conf.in
regress/scripts/testa-bacula-dir.conf.in
regress/scripts/testb-bacula-dir.conf.in
regress/scripts/tls-auth-bacula-dir.conf.in
regress/scripts/tls-bacula-dir.conf.in
regress/scripts/win32-bacula-dir-tape.conf.in
regress/scripts/win32-bacula-dir.conf.in

index 5af6ba96f49392e7332eb13c912444a4a56b635f..47c14d55487d5dfd94964f5b6eae7aac08f22e59 100644 (file)
@@ -47,6 +47,11 @@ AUTOCHANGER_PATH="/usr/sbin/mtx"
 #WHICHDB="--with-postgresql"
 WHICHDB="--with-mysql" 
 
+# DB parameters
+db_name="regress"
+db_user="regress"
+db_password=
+
 # Set this if you use libdbi framework
 #LIBDBI="dbdriver = "dbi:postgresql"; dbaddress = 127.0.0.1; dbport = 5432"
 
index 05bfa5b38eb4644e0abcc4691cc2a01eccec950b..636cfaa43e595e3ae724357b66dddbdc8a3fc16a 100644 (file)
@@ -233,7 +233,7 @@ Storage {
 Catalog {
   Name = MyCatalog
   @libdbi@
-  dbname = regress; user = regress; password = ""
+  dbname = @db_name@; user = @db_user@; password = "@db_password@"
 }
 
 # Reasonable message delivery -- send most everything to email address
index 0fee4369db778e977f2df486fa2fb691ef543fde..8a4080bff809c29097e001e8b3cc3582cf3c53b8 100644 (file)
@@ -114,7 +114,7 @@ Storage {
 Catalog {
   Name = MyCatalog
   @libdbi@
-  dbname = regress; user = regress; password = ""
+  dbname = @db_name@; user = @db_user@; password = "@db_password@"
 }
 
 # Reasonable message delivery -- send most everything to email address
index edc1233c970cf05d77b109f0a8d6c32f87114a23..8da99203d435e7047c11a7f2e4dd794f2654f23c 100644 (file)
@@ -162,7 +162,7 @@ Storage {
 Catalog {
   Name = MyCatalog
   @libdbi@
-  dbname = regress; user = regress; password = ""
+  dbname = @db_name@; user = @db_user@; password = "@db_password@"
 }
 
 # Reasonable message delivery -- send most everything to email address
index 702cdd95563a5e724806b2fc1a254935b3a565f7..9f25ac994b3e37558f9d08c86406bfb708c4ccd6 100644 (file)
@@ -175,7 +175,7 @@ Storage {
 Catalog {
   Name = MyCatalog
   @libdbi@
-  dbname = regress; user = regress; password = ""
+  dbname = @db_name@; user = @db_user@; password = "@db_password@"
 }
 
 # Reasonable message delivery -- send most everything to email address
index 9dcc243ef4c4814df0569fa5d4c2f0c2883ca1c6..46e89dd6a52fc93fe2b25da8cf6d297aba8a9691 100644 (file)
@@ -168,7 +168,7 @@ Storage {
 Catalog {
   Name = MyCatalog
   @libdbi@
-  dbname = regress; user = regress; password = ""
+  dbname = @db_name@; user = @db_user@; password = "@db_password@"
 }
 
 # Reasonable message delivery -- send most everything to email address
index dd192c68a6c57e20093a096efb0b4f631369198c..5a581bbb8ebd71e045dd95c567762be46a93e36d 100644 (file)
@@ -202,7 +202,7 @@ Storage {
 Catalog {
   Name = MyCatalog
   @libdbi@
-  dbname = regress; user = regress; password = ""
+  dbname = @db_name@; user = @db_user@; password = "@db_password@"
 }
 
 # Reasonable message delivery -- send most everything to email address
index fb1f4011f159b041efc52c4f38cf8061e36ebef5..118f496739e836e9ca4992d4cf9742556b832e17 100644 (file)
@@ -306,7 +306,7 @@ Storage {
 Catalog {
   Name = MyCatalog
   @libdbi@
-  dbname = regress; user = regress; password = ""
+  dbname = @db_name@; user = @db_user@; password = "@db_password@"
 }
 
 # Reasonable message delivery -- send most everything to email address
index f4d572ef6becd8ac018f4c1f934498f0b5318484..082e7ecbf3cb6b00ba6ef305687f374b0e33085f 100644 (file)
@@ -104,7 +104,7 @@ Storage {
 Catalog {
   Name = MyCatalog
   @libdbi@
-  dbname = regress; user = regress; password = ""
+  dbname = @db_name@; user = @db_user@; password = "@db_password@"
 }
 
 # Reasonable message delivery -- send most everything to email address
index 5b145a9e64dc9bdfa36d7058240813aa6f154e50..1f6d99f4ce4295e92dc5483339fdf83ed2e54599 100644 (file)
@@ -123,7 +123,7 @@ Storage {
 Catalog {
   Name = MyCatalog
   @libdbi@
-  dbname = regress; user = regress; password = ""
+  dbname = @db_name@; user = @db_user@; password = "@db_password@"
 }
 
 
index eb84eba847be20ccfa67f594751a7c47ff764dad..5e57e3c7cf171d6bd547b33eb98b199d4d0c49cc 100644 (file)
@@ -205,7 +205,7 @@ Storage {
 Catalog {
   Name = MyCatalog
   @libdbi@
-  dbname = regress; user = regress; password = ""
+  dbname = @db_name@; user = @db_user@; password = "@db_password@"
 }
 
 
index 21e0f522db1ee7340f74ab102b0c6d17a91087e5..5f9d1da94d437fb4ec572f268b94410fb14d6ab0 100644 (file)
@@ -108,7 +108,7 @@ Storage {
 Catalog {
   Name = MyCatalog
   @libdbi@
-  dbname = regress; user = regress; password = ""
+  dbname = @db_name@; user = @db_user@; password = "@db_password@"
 }
 
 
index a67b71301a7e3943305fb563a7c4f27e51e05608..d1af63cefc832df388a51cd598be691e32cfa24d 100644 (file)
@@ -118,7 +118,7 @@ Storage {
 Catalog {
   Name = MyCatalog
   @libdbi@
-  dbname = regress; user = regress; password = ""
+  dbname = @db_name@; user = @db_user@; password = "@db_password@"
 }
 
 
index 34540bd167d15e174a617797e89a9cf3176b0579..617ab8ca17376926b4d8146a4ec79ed69a9abb3f 100644 (file)
@@ -228,7 +228,7 @@ Storage {
 Catalog {
   Name = MyCatalog
   @libdbi@
-  dbname = regress; user = regress; password = ""
+  dbname = @db_name@; user = @db_user@; password = "@db_password@"
 }
 
 
index 46475e3a2977a40e713cd486c92f5b2073d10678..350a31a2ea669a4b4c7faa57d1bd3611339b1ae5 100755 (executable)
@@ -8,7 +8,7 @@ mkdir -p ${cwd}/bin
 mkdir -p ${cwd}/tmp
 out="${cwd}/tmp/sed_tmp"
 
-# set the ports used by these tests
+# set ports and other default parameters
 BASEPORT=${BASEPORT:-8101}
 AUTOCHANGER_SCRIPT=${AUTOCHANGER_SCRIPT:-mtx-changer}
 LIBDBI=${LIBDBI:-}
@@ -17,6 +17,9 @@ srcdir=${BACULA_SOURCE}
 dirport=${BASEPORT}
 fdport=`expr ${BASEPORT} '+' 1`
 sdport=`expr ${BASEPORT} '+' 2`
+db_name=${db_name:-"regress"}
+db_user=${db_user:-"regress"}
+db_password=${db_password:-""}
 os=`uname -s`-`./scripts/get-os`
 dbengine=`echo ${WHICHDB} | sed -e 's/--with-//' -e 's/=.*//'`
 bversion=`sed -n -e 's/^.*VERSION.*"\(.*\)"$/\1/p' ${srcdir}/src/version.h`
@@ -65,3 +68,6 @@ echo "s%@win32_addr@%${WIN32_ADDR}%g" >>${out}
 echo "s%@win32_file@%${WIN32_FILE}%g" >>${out}
 echo "s%@win32_port@%${WIN32_PORT}%g" >>${out}
 echo "s%@win32_password@%${WIN32_PASSWORD}%g" >>${out}
+echo "s%@db_name@%${db_name}%g" >>${out}
+echo "s%@db_user@%${db_user}%g" >>${out}
+echo "s%@db_password@%${db_password}%g" >>${out}
index b23e054249dc063b3454410f35e3c25b82cdd6a6..ab5e7ed27d223b3c6d280f4fd6839a02b7b8ac76 100755 (executable)
@@ -57,6 +57,8 @@ sed -f ${out} ${cwd}/scripts/bacula-fd-2d.conf.in >${cwd}/scripts/bacula-fd-2d.c
 sed -f ${out} ${cwd}/scripts/bacula-sd-2d.conf.in >${cwd}/scripts/bacula-sd-2d.conf
 sed -f ${out} ${cwd}/scripts/bacula-dir-2d.conf.in >${cwd}/scripts/bacula-dir-2d.conf
 sed -f ${out} ${cwd}/scripts/bconsole-2d.conf.in >${cwd}/scripts/bconsole-2d.conf
+sed -f ${out} ${cwd}/scripts/regress-config.in >${cwd}/scripts/regress-config
+
 
 scripts/config_dart
 
index 59e97eeca2620b4288fb40e196888bc781d2956b..fad158694e98c6a935661d1f270ff346c899aba5 100644 (file)
@@ -325,7 +325,7 @@ Storage {
 Catalog {
   Name = MyCatalog
   @libdbi@
-  dbname = regress; user = regress; password = ""
+  dbname = @db_name@; user = @db_user@; password = "@db_password@"
 }
 
 # Reasonable message delivery -- send most everything to email address
index 38ce5586e36ad80286246f07d5efe88096cc6cf0..af690361505d8895b7174fdab26d1a2281605f4f 100644 (file)
@@ -440,7 +440,7 @@ Storage {
 Catalog {
   Name = MyCatalog
   @libdbi@
-  dbname = regress; user = regress; password = ""
+  dbname = @db_name@; user = @db_user@; password = "@db_password@"
 }
 
 # Reasonable message delivery -- send most everything to email address
index 5b589bd68f437a04ab6f52bdafc610bc7bbac84f..b6cb8bd2bf22c662fff4792056f239677204e6d8 100755 (executable)
@@ -27,3 +27,32 @@ CFLAGS="-g -O2 -Wall" \
     --with-baseport=${BASEPORT}
 
 exit 0
+#!/bin/sh
+#
+# This is the configuration script for regression testing
+#
+
+. ${1}/config
+
+CFLAGS="-g -O2 -Wall" \
+ ./configure \
+    --sbindir=${1}/bin \
+    --sysconfdir=${1}/bin \
+    --mandir=${1}/bin \
+    --with-pid-dir=${1}/working \
+    --with-subsys-dir=${1}/working \
+    --enable-smartalloc \
+    --disable-readline \
+    --with-working-dir=${1}/working \
+    --with-archivedir=${1}/tmp \
+    --with-dump-email=${EMAIL} \
+    --with-job-email=${EMAIL} \
+    --with-smtp-host=${SMTP_HOST} \
+    --with-db-name=regress \
+    --with-db-user=regress \
+    ${OPENSSL} \
+    ${TCPWRAPPERS} \
+    ${WHICHDB} \
+    --with-baseport=${BASEPORT}
+
+exit 0
index e1fe75e18d631e52203ef85c5e869519f4fb33ca..69833a437486946071aac564f965700a2e366e15 100644 (file)
@@ -261,7 +261,7 @@ Storage {
 Catalog {
   Name = MyCatalog
   @libdbi@
-  dbname = regress; user = regress; password = ""
+  dbname = @db_name@; user = @db_user@; password = "@db_password@"
 }
 
 # Reasonable message delivery -- send most everything to email address
index 4741e76829471d437cb62448cf22bd96be8fdc9c..cd956931f2071ed154607e983b7f2463d2e2691e 100644 (file)
@@ -103,7 +103,7 @@ Storage {
 Catalog {
   Name = MyCatalog
   @libdbi@
-  dbname = regress; user = regress; password = ""
+  dbname = @db_name@; user = @db_user@; password = "@db_password@"
 }
 
 # Reasonable message delivery -- send most everything to email address
index 5c9d838d192009eeaca0bb4f64df1adccce408cd..e85afacb75b59148f5c558db14605736c8f0f52b 100644 (file)
@@ -107,7 +107,7 @@ Storage {
 Catalog {
   Name = MyCatalog
   @libdbi@  
-  dbname = regress; user = regress; password = ""
+  dbname = @db_name@; user = @db_user@; password = "@db_password@"
 }
 
 # Reasonable message delivery -- send most everything to email address
index fcdfeb535b7e2dfa065c810c033eaaa3fe29fec4..01aee907c69da5b835a8071d72dfb4f5782110d3 100644 (file)
@@ -339,7 +339,7 @@ Storage {
 Catalog {
   Name = MyCatalog
   @libdbi@
-  dbname = regress; user = regress; password = ""
+  dbname = @db_name@; user = @db_user@; password = "@db_password@"
 }
 
 # Reasonable message delivery -- send most everything to email address
index aebf2b63b5195f30425f90ec3cf1f4f3d685a2e2..bd6c965a25d29d2d3c203deb1c4737a18f1088c4 100644 (file)
@@ -336,7 +336,7 @@ Storage {
 Catalog {
   Name = MyCatalog
   @libdbi@
-  dbname = regress; user = regress; password = ""
+  dbname = @db_name@; user = @db_user@; password = "@db_password@"
 }
 
 # Reasonable message delivery -- send most everything to email address
index 00a9364bb4632746a7dca213599d4be89eaf9d52..be11cb6355bad7a91221e65aa685f8a26423ecec 100644 (file)
@@ -118,7 +118,7 @@ Storage {
 Catalog {
   Name = MyCatalog
   @libdbi@
-  dbname = regress; user = regress; password = ""
+  dbname = @db_name@; user = @db_user@; password = "@db_password@"
 }
 
 # Reasonable message delivery -- send most everything to email address
index e605eac44611fa42772ada6ffe3fa11746165c49..4b8e901da6851f092a7e4715a36aa5faddd36c4f 100644 (file)
@@ -118,7 +118,7 @@ Storage {
 Catalog {
   Name = MyCatalog
   @libdbi@
-  dbname = regress; user = regress; password = ""
+  dbname = @db_name@; user = @db_user@; password = "@db_password@"
 }
 
 # Reasonable message delivery -- send most everything to email address