--- builds_bin/update_repos 2016/03/05 16:25:14 1.80 +++ builds_bin/update_repos 2016/03/08 10:49:22 1.82 @@ -45,7 +45,7 @@ my $distrepo = { '8' => { active => 1 keyname => 'SME Server 7 signing key ', checksum => 'sha256', }, - '10' => { active => 0, + '10' => { active => 1, centos => 7, archs => [ 'x86_64' ], repo => '/build/smeserver/repo/testing/10/', @@ -53,7 +53,7 @@ my $distrepo = { '8' => { active => 1 community => '/build/builds/smeserver-10-contribs/', stage => '/build/smeserver/stage/10/', sign => 1, - keyname => 'SME Server 7 signing key ', + keyname => 'Koozali SME Server signing key (10) ', checksum => 'sha256', }, }; @@ -162,8 +162,16 @@ foreach my $ver ( sort { $a <=> $b } key } next unless -d $adir; opendir DIR, $adir or next; - process_rpm("$adir$_", $ver, $baserepo->{$dir}) foreach readdir DIR; + my @txt = grep { /\.rpm$/ && -f "$adir/$_" } readdir DIR; closedir DIR; + if (scalar(@txt)) { + opendir DIR, $adir or next; + process_rpm("$adir$_", $ver, $baserepo->{$dir}) foreach readdir DIR; + closedir DIR; + } elsif ($baserepo->{$dir} eq 'epel') { + # EPEL 7 uses a structure with subfolders of first letter of package + find( { wanted => sub { process_rpm($_, $ver, $baserepo->{$dir}) if ($_ =~ m/\.rpm$/);}, no_chdir => 1, follow_fast => 1 }, $adir ); + } last unless $dir =~ m{~A}; } }