vorm Kopieren mal gucken obs da is
authorMaximilian Wilhelm <max@rfc2324.org>
Tue, 4 Oct 2005 15:09:57 +0000 (15:09 +0000)
committerMaximilian Wilhelm <max@rfc2324.org>
Tue, 4 Oct 2005 15:09:57 +0000 (15:09 +0000)
files/server/RBM/sshKeySync/Merge.pm

index 2189a92..c8f1b96 100644 (file)
@@ -485,14 +485,19 @@ sub publish_known_hosts() {
 
        print " * Publishing ssh_known_hosts files:\n" if ( $config->{verbose} );
        print "    - global ssh_known_hosts files...\n" if ( $config->{verbose} );
-       unless ( copy( "$config->{base_dir}/ssh_known_hosts", "$config->{base_dir}/pub/" ) )
-       {
+       unless ( -f "$config->{base_dir}/ssh_known_hosts" ) {
+               print STDERR "Global ssh_known_hosts file does not exist.\n";
+       }
+       unless ( copy( "$config->{base_dir}/ssh_known_hosts", "$config->{base_dir}/pub/" ) ) {
                print STDERR "Error, while copying global ssh_known_hosts file to public dir.\n";
        }
 
        foreach my $domain (keys %${domains}) {
                if ( $domains->{$domain}->get_common_outfile() ) {
                        print "    - ssh_known_hosts file for domain ${domain}...\n" if ( $config->{verbose} );
+                       unless ( -f "$config->{base_dir}/$domain/ssh_known_hosts" ) {
+                               print STDERR "There is no ssh_known_hosts file for domain $domain\n";
+                       }
                        unless ( copy( "$config->{base_dir}/$domain/ssh_known_hosts", "$config->{base_dir}/pub/ssh_known_hosts.${domain}" ) ) {
                                print STDERR "Error while copying file...\n";
                        }