X-Git-Url: http://ftp.carnet.hr/carnet-debian/scm?a=blobdiff_plain;f=debian%2Fpostinst;h=97d8ac55c859af1ec2e00ad3d31cd20823efd96c;hb=refs%2Fheads%2Fsqueeze;hp=5a45d4f4726ca5cf40650fd7996ab57866a973af;hpb=76704136237b71819bea6552cbb84958d682536f;p=bacula-cn.git diff --git a/debian/postinst b/debian/postinst index 5a45d4f..97d8ac5 100644 --- a/debian/postinst +++ b/debian/postinst @@ -259,29 +259,19 @@ Console { Password = "$PASS_BCONSOLE" # password for bconsole(8) JobACL = $HOST, RestoreFiles ClientACL = $HOST-fd - StorageACL = $HOST-stor - PoolACL = $HOST-pool, tmp -} - -Pool { - Name = $HOST-pool - @/etc/bacula/include/pool-default.conf - Label Format = ${HOST}_ -} - -Storage { - Name = $HOST-stor - @/etc/bacula/include/storage-default.conf - Device = file_$HOST - Media Type = media_$HOST } Job { Name = "$HOST" Client = $HOST-fd - JobDefs = "Job_SysBackup" - Pool = $HOST-pool - Storage = $HOST-stor + JobDefs = "Job_TapeBackup" + Messages = messages-$HOST +} + +Messages { + Name = messages-$HOST + @/etc/bacula/include/messages-defaults.conf + mail = $EMAIL = all, !skipped } EOF @@ -304,7 +294,7 @@ EOF # Try to send it if [ -x "`which sendmail 2>/dev/null`" ]; then echo Mailing request from $REQUEST_FILE - if sendmail -t -oi < $REQUEST_FILE; then + if sendmail -t -oi -f "$EMAIL" < $REQUEST_FILE; then requestsent=1 fi fi @@ -324,6 +314,8 @@ load_config() { db_get bacula-cn/contact CONTACT=$RET + EMAIL=${CONTACT#*<} + EMAIL=${EMAIL%>*} PASS_FD=$( random_string ) PASS_BCONSOLE=$( random_string )