Chris Browne cbbrowne at lists.slony.info
Thu Nov 22 09:47:05 PST 2007
Update of /home/cvsd/slony1/slony1-engine/tools
In directory main.slony.info:/tmp/cvs-serv16051

Modified Files:
	configure-replication.sh configure-replication.txt 
Log Message:
Add in SLONIKCONFDIR to allow the gentle user to specify a directory
in which to place the slonik files.  This will enable using this tool
for automated processes.


Index: configure-replication.sh
===================================================================
RCS file: /home/cvsd/slony1/slony1-engine/tools/configure-replication.sh,v
retrieving revision 1.3
retrieving revision 1.4
diff -C2 -d -r1.3 -r1.4
*** configure-replication.sh	2 Nov 2007 15:31:43 -0000	1.3
--- configure-replication.sh	22 Nov 2007 17:47:03 -0000	1.4
***************
*** 36,39 ****
--- 36,47 ----
  PORT5=${PORT5:-${PGPORT:-"5432"}}
  
+ 
+ tmpdir=`mktemp -d -t slonytest-temp.XXXXXX`
+ if [ $MY_MKTEMP_IS_DECREPIT ] ; then
+        tmpdir=`mktemp -d /tmp/slonytest-temp.XXXXXX`
+ fi
+ mktmp=${SLONIKCONFDIR:-${tmpdir}}
+ mkdir -p ${mktmp}
+ 
  store_path()
  {
***************
*** 78,86 ****
  }
  
- mktmp=`mktemp -d -t slonytest-temp.XXXXXX`
- if [ $MY_MKTEMP_IS_DECREPIT ] ; then
-        mktmp=`mktemp -d /tmp/slonytest-temp.XXXXXX`
- fi
- 
  PREAMBLE=${mktmp}/preamble.slonik
  
--- 86,89 ----

Index: configure-replication.txt
===================================================================
RCS file: /home/cvsd/slony1/slony1-engine/tools/configure-replication.txt,v
retrieving revision 1.1
retrieving revision 1.2
diff -C2 -d -r1.1 -r1.2
*** configure-replication.txt	20 Oct 2006 16:01:01 -0000	1.1
--- configure-replication.txt	22 Nov 2007 17:47:03 -0000	1.2
***************
*** 33,36 ****
--- 33,40 ----
             namespace, such as public.my_sequence)
  
+   SLONIKCONFDIR - a directory in which to place the config files.  If
+      not set, a unique directory under /tmp will be created for this
+      purpose.
+ 
  Defaults are provided for ALL of these values, so that if you run
  configure-replication.sh without setting any environment variables,
***************
*** 52,57 ****
  provides if all your databases are on the same server!
  
! slonik config files are generated in a temp directory under /tmp.  The
! usage is thus:
  
  1.  preamble.slonik is a "preamble" containing connection info used by
--- 56,62 ----
  provides if all your databases are on the same server!
  
! slonik config files are generated in a temp directory under /tmp.
! (Or, if you set SLONIKCONFDIR, the directory you specify in that
! environment variable.)  The usage is thus:
  
  1.  preamble.slonik is a "preamble" containing connection info used by



More information about the Slony1-commit mailing list