diff options
author | ivan <ivan> | 2004-05-10 11:10:59 +0000 |
---|---|---|
committer | ivan <ivan> | 2004-05-10 11:10:59 +0000 |
commit | 8334916f36ee80dfa648cbc76258b4e2fda499e0 (patch) | |
tree | 022cd923af39f4dbc3bbb04486c05c65090ca2a9 /bin | |
parent | 04cf34ec20fd25f071867ba81e0efcfab36498d5 (diff) |
make postfix export commands configrable
Diffstat (limited to 'bin')
-rwxr-xr-x | bin/postfix.export | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/bin/postfix.export b/bin/postfix.export index 64d973837..dbb08ceb9 100755 --- a/bin/postfix.export +++ b/bin/postfix.export @@ -99,7 +99,7 @@ foreach my $export ( @exports ) { } ) or die "rsync to $machine failed: ". join(" / ", $rsync->err); # warn $rsync->out; - ssh("$user\@$machine", "newaliases"); + ssh("$user\@$machine", $export->option('newaliases') || 'newaliases'); # ssh("$user\@$machine", "postfix reload"); $rsync->exec( { @@ -107,8 +107,9 @@ foreach my $export ( @exports ) { dest => "$user\@$machine:". $export->option('virtual'), } ) or die "rsync to $machine failed: ". join(" / ", $rsync->err); # warn $rsync->out; - ssh("$user\@$machine", "postmap hash:/etc/postfix/virtual"); - ssh("$user\@$machine", "postfix reload"); + ssh("$user\@$machine", $export->option('postmap') + || 'postmap hash:/etc/postfix/virtual'); + ssh("$user\@$machine", $export->option('reload') || 'postfix reload'); } |