removed dependency on known_hosts file
This commit is contained in:
@@ -19,9 +19,8 @@ RUN apt-get update && apt-get install -y rsync openssh-client
|
||||
|
||||
COPY docker_dev/shared/id_rsa /root/.ssh/id_rsa
|
||||
COPY docker_dev/shared/id_rsa.pub /root/.ssh/id_rsa.pub
|
||||
COPY docker_dev/shared/known_hosts /root/.ssh/known_hosts
|
||||
|
||||
RUN chmod 600 /root/.ssh/id_rsa /root/.ssh/id_rsa.pub /root/.ssh/known_hosts
|
||||
RUN chmod 600 /root/.ssh/id_rsa /root/.ssh/id_rsa.pub
|
||||
|
||||
|
||||
# Shared Volumes
|
||||
|
||||
@@ -72,10 +72,11 @@ Targets=
|
||||
Targets="${Targets} cvtt@cloud21.cvtt.vpn:/opt/store/cvtt/md_archive/crypto"
|
||||
Targets="${Targets} cvtt@hs01.cvtt.vpn:/works/cvtt/md_archive/crypto"
|
||||
|
||||
|
||||
for tgt in ${Targets}
|
||||
do
|
||||
Cmd="/usr/bin/rsync -ahv ${Source} ${tgt}"
|
||||
Cmd="/usr/bin/rsync -ahv"
|
||||
Cmd+=" -e 'ssh -o StrictHostKeyChecking=no -o UserKnownHostsFile=/dev/null'"
|
||||
Cmd+=" ${Source} ${tgt}"
|
||||
echo $Cmd
|
||||
eval $Cmd
|
||||
done
|
||||
|
||||
Reference in New Issue
Block a user