Changeset 1765 in ProjectBuilder
- Timestamp:
- Jun 1, 2013, 9:38:07 PM (12 years ago)
- Location:
- projects
- Files:
-
- 3 added
- 6 edited
Legend:
- Unmodified
- Added
- Removed
-
projects/casparbuster/devel/bin/cb
r1683 r1765 166 166 pb_log(2,"%cb: ",Dumper($cb)); 167 167 168 if (defined $plugin) {169 # Load plugins170 cb_plugin_load();171 }172 173 168 my $basedir = $cb->{'basedir'}->{$appname}; 174 169 eval { $basedir =~ s/(\$ENV.+\})/$1/eeg }; … … 184 179 my $precmd = ""; 185 180 if (! -f $db) { 186 $precmd = "CREATE TABLE dates (id INTEGER PRIMARY KEY AUTOINCREMENT, date INTEGER, file VARCHAR[65535], machine VARCHAR[65535] )";181 $precmd = "CREATE TABLE dates (id INTEGER PRIMARY KEY AUTOINCREMENT, date INTEGER, file VARCHAR[65535], machine VARCHAR[65535], mode VARCHAR[4], uid VARCHAR[5], gid VARCHAR[5])"; 187 182 } 188 183 … … 210 205 umask(0022); 211 206 pb_vcs_export(pb_vcs_get_uri($scheme,$basedir),$basedir,$dest); 207 208 # Load all plugins plus the additional manually defined 209 cb_plugin_load(); 210 if (defined $plugin) { 211 pb_conf_add("$basedir/plugins/$plugin") if (-f "$basedir/plugins/$plugin"); 212 } 212 213 213 214 # Now distribute to the right machines … … 239 240 240 241 pb_log(2,"Entering into cb_distribute with machine $machine\n"); 241 confess "No machine fiven to cb_distribute" if (not defined $machine);242 confess "No machine given to cb_distribute" if (not defined $machine); 242 243 243 244 # Use potentially a remote account if defined … … 274 275 $fullsource = "$machine/$source"; 275 276 pb_log(2,"fullsource is $fullsource\n"); 276 my ($dev,$ino,$mode,$nlink,$uid,$gid,$rdev,$size,$atime,$mtime,$ctime,$blksize,$blocks) = stat("$dest/$fullsource") || die "Unable to stat $fullsource: $!";277 277 my $type = 'files'; 278 278 if (-d $fullsource) { … … 281 281 die "ERROR: Only able to handle files or dirs with option --source\n" if ((! -d $fullsource) && (! -f $fullsource)); 282 282 283 # We should get uid/gid from elsewhere as they're probably wrong locally 284 $cbp->{"cb.source"}->{$type}->{$source}->{'uid'} = $uid; 285 $cbp->{"cb.source"}->{$type}->{$source}->{'gid'} = $gid; 286 $cbp->{"cb.source"}->{$type}->{$source}->{'mode'} = $mode; 287 $cbp->{"cb.source"}->{$type}->{$source}->{'mtime'} = $mtime; 283 cb_fill_cbp("cb.source","$dest/$fullsource",$type,$source) 288 284 } 289 285 … … 427 423 if (not $debug) { 428 424 # Reminder: sudo should be configured for this account as Defaults !requiretty for this to work 429 print $chan "sudo tar -C $path - x -f $tarfile $tbextract\n";425 print $chan "sudo tar -C $path --no-overwrite-dir -x -f $tarfile $tbextract\n"; 430 426 pb_log(0,"WARNING: $_\n") while (<$chan>); 431 427 } else { … … 497 493 return if ($targetname eq ""); 498 494 499 my ($dev,$ino,$mode,$nlink,$uid,$gid,$rdev,$size,$atime,$mtime,$ctime,$blksize,$blocks) = stat($File::Find::name); 500 die "Unable to stat $File::Find::name" if (not defined $mode); 501 # We should get uid/gid fro elsewhere as they're probably wrong locally 502 $cbp->{"cb.full"}->{$type}->{$targetname}->{'uid'} = $uid; 503 $cbp->{"cb.full"}->{$type}->{$targetname}->{'gid'} = $gid; 504 $cbp->{"cb.full"}->{$type}->{$targetname}->{'mode'} = sprintf("%04o",$mode & 07777); 505 $cbp->{"cb.full"}->{$type}->{$targetname}->{'mtime'} = $mtime; 506 pb_log(2,"Adding $File::Find::name ($uid,$gid,$mode) to cbp\n"); 507 } 495 cb_fill_cbp("cb.full",$File::Find::name,$type,$targetname) 496 } 497 498 sub cb_fill_cbp { 499 500 my $k = shift; 501 my $f = shift; 502 my $type = shift; 503 my $targetname = shift; 504 505 my ($dev,$ino,$mode,$nlink,$uid,$gid,$rdev,$size,$atime,$mtime,$ctime,$blksize,$blocks) = stat($f); 506 ($dev,$ino,$mode,$nlink,$uid,$gid,$rdev,$size,$atime,$mtime,$ctime,$blksize,$blocks) = lstat($f) if (not defined $mode); 507 die "Unable to stat $f" if (not defined $mode); 508 # We should get uid/gid from elsewhere as they're probably wrong locally 509 $cbp->{$k}->{$type}->{$targetname}->{'uid'} = $uid; 510 $cbp->{$k}->{$type}->{$targetname}->{'gid'} = $gid; 511 $cbp->{$k}->{$type}->{$targetname}->{'mode'} = sprintf("%04o",$mode & 07777); 512 $cbp->{$k}->{$type}->{$targetname}->{'mtime'} = $mtime; 513 pb_log(2,"Adding $f ($uid,$gid,$mode) to cbp\n"); 514 } -
projects/casparbuster/devel/etc/cb/plugins/shorewall.conf
r1679 r1765 20 20 #=cut 21 21 # 22 #cbpluginfiles shorewall = /etc/shorewall/*|root,root,060022 cbpluginfiles shorewall = /etc/shorewall/.+|root,root,0600 23 23 # 24 24 #=item B<cbplugindirs> … … 30 30 # 31 31 #=cut 32 #cbplugindirs shorewall = /etc/shorewall|root,root,075032 cbplugindirs shorewall = /etc/shorewall|root,root,0750 33 33 # 34 34 #=item B<cbplugindirsandfiles> … … 40 40 # 41 41 #=cut 42 #cbplugindirsandfiles shorewall =42 cbplugindirsandfiles shorewall = 43 43 # 44 44 #=item B<cbpluginpkgs> -
projects/casparbuster/devel/lib/CasparBuster/Plugin.pm
r1679 r1765 64 64 } 65 65 closedir(DIR); 66 67 my ($flist,$dlist,$dflist,$slist) = pb_conf_get_if("cbpluginfiles","cbplugindirs","cbplugindirsandfiles","cbppkgreload"); 68 if (defined $flist) { 69 foreach my $plugin (keys %$flist) { 70 foreach my $block (split(/;/,$flist->{$plugin})) { 71 pb_log(3,"block : $block\n"); 72 my ($name,$tmp) = split(/\|/,$block); 73 ($cbp->{'files'}->{$name}->{'uid'},$cbp->{'files'}->{$name}->{'gid'},$cbp->{'files'}->{$name}->{'mode'}) = split(/\,/,$tmp); 74 } 75 } 76 } 77 if (defined $dlist) { 78 foreach my $plugin (keys %$dlist) { 79 foreach my $block (split(/;/,$dlist->{$plugin})) { 80 pb_log(3,"block : $block\n"); 81 my ($name,$tmp) = split(/\|/,$block); 82 ($cbp->{'dirs'}->{$name}->{'uid'},$cbp->{'dirs'}->{$name}->{'gid'},$cbp->{'dirs'}->{$name}->{'mode'}) = split(/\,/,$tmp); 83 } 84 } 85 } 86 if (defined $dflist) { 87 foreach my $plugin (keys %$dflist) { 88 foreach my $block (split(/;/,$dflist->{$plugin})) { 89 pb_log(3,"block : $block\n"); 90 my ($name,$tmp) = split(/\|/,$block); 91 ($cbp->{'dirsandfiles'}->{$name}->{'uid'},$cbp->{'dirsandfiles'}->{$name}->{'gid'},$cbp->{'dirsandfiles'}->{$name}->{'mode'}) = split(/\,/,$tmp); 92 } 93 } 94 } 95 if (defined $slist) { 96 foreach my $plugin (keys %$slist) { 97 foreach my $name (split(/,/,$slist->{$plugin})) { 98 $cbp->{'reload'}->{$plugin}->{'restart'} = $name; 99 } 100 } 66 101 } 67 102 -
projects/mondorescue/pbconf/branches/3.0/pbfilter/debian.pbf
r1209 r1765 5 5 # 6 6 # PBDEBSTD is replaced by the Debian standard version 7 filter PBDEBSTD = 3. 8.07 filter PBDEBSTD = 3.9.4 8 8 9 9 # PBDEBCOMP is replaced by the Debian Compatibility value 10 filter PBDEBCOMP = 710 filter PBDEBCOMP = 9 11 11 12 12 -
projects/uuwl/pbconf/devel/pbfilter/debian.pbf
r1475 r1765 5 5 # 6 6 # PBDEBSTD is replaced by the Debian standard version 7 filter PBDEBSTD = 3. 8.07 filter PBDEBSTD = 3.9.4 8 8 9 9 # PBDEBCOMP is replaced by the Debian Compatibility value 10 filter PBDEBCOMP = 710 filter PBDEBCOMP = 9 11 11 12
Note:
See TracChangeset
for help on using the changeset viewer.