make a use of our wrapper

This commit is contained in:
belliash 2012-01-17 11:49:40 +01:00
parent 7ee37f3b1a
commit b30948a880
2 changed files with 5 additions and 7 deletions

2
ezsync
View File

@ -88,7 +88,7 @@ fi
# Initialize EzBuild environment # Initialize EzBuild environment
makeCoreDirectories || die "EzBuild was unable to create all necessary directories!" 1 makeCoreDirectories || die "EzBuild was unable to create all necessary directories!" 1
EZNOTIFY="yes" EZNOTIFY="yes"
makeSshWrapper || die "EzBuild was unable to create a wrapper file to SSH" 1 prepareSshWrappers || die "EzBuild was unable to create a wrapper files to SSH" 1
trap 'die "Process killed! This may lead into unexpected problems!"' 1 2 3 9 15 17 18 23 trap 'die "Process killed! This may lead into unexpected problems!"' 1 2 3 9 15 17 18 23
# Load necessary public keys # Load necessary public keys

View File

@ -4,13 +4,11 @@
#------------------------------------------------------------------------------- #-------------------------------------------------------------------------------
# Creates SSH Wrapper for use with unknown hosts (requires key authentication) # Prepares SSH Wrappers for use with unknown hosts (requires key authentication)
#------------------------------------------------------------------------------- #-------------------------------------------------------------------------------
function makeSshWrapper() { function prepareSshWrappers() {
echo "#!/bin/bash" > ${BINDIR}/ssh_wrapper.sh run "cp ${EZROOT}/files/ssh_wrapper.sh ${BINDIR}/ssh_wrapper.sh" || return 1
echo "exec ssh -o UserKnownHostsFile=/dev/null -o StrictHostKeyChecking=no \ run "chmod +x ${BINDIR}/ssh_wrapper.sh" || return 1
\"\$@\"" >> ${BINDIR}/ssh_wrapper.sh
chmod +x ${BINDIR}/ssh_wrapper.sh || return 1
export GIT_SSH="${BINDIR}/ssh_wrapper.sh" export GIT_SSH="${BINDIR}/ssh_wrapper.sh"
export SVN_SSH="${BINDIR}/ssh_wrapper.sh" export SVN_SSH="${BINDIR}/ssh_wrapper.sh"
return 0 return 0