[freeside-commits] branch FREESIDE_4_BRANCH updated. 5ef4305f01a1239db33026f345b461a7c032bb02
Ivan Kohler
ivan at freeside.biz
Wed Jul 3 13:19:53 AKDT 2024
The branch, FREESIDE_4_BRANCH has been updated
via 5ef4305f01a1239db33026f345b461a7c032bb02 (commit)
from 71266bdf19d0f16931abb1eee8e1b0fa65ce207a (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
- Log -----------------------------------------------------------------
commit 5ef4305f01a1239db33026f345b461a7c032bb02
Author: Ivan Kohler <ivan at freeside.biz>
Date: Wed Jul 3 14:19:52 2024 -0700
BIND local_zonepath override
diff --git a/FS/bin/freeside-bind-export b/FS/bin/freeside-bind-export
index a3bbd1ac5..9c5130b11 100755
--- a/FS/bin/freeside-bind-export
+++ b/FS/bin/freeside-bind-export
@@ -20,10 +20,10 @@ mkdir $spooldir, 0700 unless -d $spooldir;
my @exports = qsearch('part_export', { 'exporttype' => 'bind' } );
my @sexports = qsearch('part_export', { 'exporttype' => 'bind_slave' } );
-my $rsync = File::Rsync->new({
+my $rsync = File::Rsync->new(
rsh => 'ssh',
# dry_run => 1,
-});
+);
foreach my $export ( @exports ) {
@@ -50,7 +50,8 @@ foreach my $export ( @exports ) {
close CONF_HEADER;
}
- my $zonepath = $export->option('zonepath');
+ my $zonepath = $export->option('local_zonepath')
+ || $export->option('zonepath');
$zonepath =~ s/\/$//;
my @svc_domain = $export->svc_x;
@@ -112,18 +113,18 @@ END
}
- $rsync->exec( {
+ $rsync->exec(
src => "$prefix/",
recursive => 1,
dest => "root\@$machine:$zonepath/",
exclude => [qw( *.import named.conf.HEADER named.conf )],
- } ) or die "rsync to $machine failed: ". join(" / ", $rsync->err);
+ ) or die "rsync to $machine failed: ". join(" / ", $rsync->err);
# warn $rsync->out;
- $rsync->exec( {
+ $rsync->exec(
src => "$prefix/named.conf",
dest => "root\@$machine:". $export->option('named_conf'),
- } ) or die "rsync to $machine failed: ". join(" / ", $rsync->err);
+ ) or die "rsync to $machine failed: ". join(" / ", $rsync->err);
# warn $rsync->out;
ssh("root\@$machine", "$ndc_cmd reload");
@@ -177,10 +178,10 @@ END
}
- $rsync->exec( {
+ $rsync->exec(
src => "$prefix/named.conf",
dest => "root\@$machine:". $sexport->option('named_conf'),
- } ) or die "rsync to $machine failed: ". join(" / ", $rsync->err);
+ ) or die "rsync to $machine failed: ". join(" / ", $rsync->err);
# warn $rsync->out;
ssh("root\@$machine", "$ndc_cmd reload");
-----------------------------------------------------------------------
Summary of changes:
FS/bin/freeside-bind-export | 19 ++++++++++---------
1 file changed, 10 insertions(+), 9 deletions(-)
More information about the freeside-commits
mailing list