Create a local archive from a remote folder
ssh user@host tar czf - /source_path/ > /localdestination/archive.tar.gz
Restore a local archive to a remote folder
cat /localdestination/archive.tar.gz | ssh user@host "tar zxvf -"
# - or -
cat /localdestination/archive.tar.gz | ssh user@host "cd /dest_path/; tar zxvf -"