[dovecot-cvs] dovecot/doc mkcert.sh,1.7,1.7.2.1

cras at dovecot.org cras at dovecot.org
Fri Jun 9 14:04:07 EEST 2006


Update of /var/lib/cvs/dovecot/doc
In directory talvi:/tmp/cvs-serv7701

Modified Files:
      Tag: branch_1_0
	mkcert.sh 
Log Message:
If cert/key directories don't exist, exit immediately instead of just
priting the errors.



Index: mkcert.sh
===================================================================
RCS file: /var/lib/cvs/dovecot/doc/mkcert.sh,v
retrieving revision 1.7
retrieving revision 1.7.2.1
diff -u -d -r1.7 -r1.7.2.1
--- mkcert.sh	23 Jul 2004 00:05:58 -0000	1.7
+++ mkcert.sh	9 Jun 2006 11:04:05 -0000	1.7.2.1
@@ -7,15 +7,20 @@
 SSLDIR=${SSLDIR-/etc/ssl}
 OPENSSLCONFIG=${OPENSSLCONFIG-dovecot-openssl.cnf}
 
-CERTFILE=$SSLDIR/certs/dovecot.pem
-KEYFILE=$SSLDIR/private/dovecot.pem
+CERTDIR=$SSLDIR/certs
+KEYDIR=$SSLDIR/private
 
-if [ ! -d $SSLDIR/certs ]; then
+CERTFILE=$CERTDIR/dovecot.pem
+KEYFILE=$KEYDIR/dovecot.pem
+
+if [ ! -d $CERTDIR ]; then
   echo "$SSLDIR/certs directory doesn't exist"
+  exit 1
 fi
 
-if [ ! -d $SSLDIR/private ]; then
+if [ ! -d $KEYDIR ]; then
   echo "$SSLDIR/private directory doesn't exist"
+  exit 1
 fi
 
 if [ -f $CERTFILE ]; then



More information about the dovecot-cvs mailing list