Skip to content

Commit

Permalink
Missing a 'sudo'
Browse files Browse the repository at this point in the history
  • Loading branch information
None committed Jun 28, 2017
1 parent cff68d5 commit 4b70890
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion config/user-data/hooks/03-edgerouter-backup.sh
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ sudo find /config/* | grep -v "/config/dhcpd.leases" | xargs tar cf /tmp/edgerou
echo "edgerouter-backup: Copying backup files to $SSH_USER@$SSH_HOST:$REPO_PATH"
sudo scp -q -i $SSH_KEYFILE -o UserKnownHostsFile=/dev/null -o StrictHostKeyChecking=no /tmp/edgerouter-backup-$FNAME_CONFIG $SSH_USER@$SSH_HOST:$REPO_PATH/$FNAME_CONFIG > /dev/null
sudo scp -q -i $SSH_KEYFILE -o UserKnownHostsFile=/dev/null -o StrictHostKeyChecking=no /tmp/edgerouter-backup-$FNAME_CLI $SSH_USER@$SSH_HOST:$REPO_PATH/$FNAME_CLI > /dev/null
sudo cat /tmp/edgerouter-backup-$FNAME_BACKUP | ssh -q -i $SSH_KEYFILE -o UserKnownHostsFile=/dev/null -o StrictHostKeyChecking=no $SSH_USER@$SSH_HOST "gzip -cnq9 > $REPO_PATH/$FNAME_BACKUP" > /dev/null
sudo cat /tmp/edgerouter-backup-$FNAME_BACKUP | sudo ssh -q -i $SSH_KEYFILE -o UserKnownHostsFile=/dev/null -o StrictHostKeyChecking=no $SSH_USER@$SSH_HOST "gzip -cnq9 > $REPO_PATH/$FNAME_BACKUP" > /dev/null

# git commit and git push on remote host
echo "edgerouter-backup: Triggering 'git commit'"
Expand Down

0 comments on commit 4b70890

Please sign in to comment.