ruby on rails - How to copy Digital Ocean app folder to local machine? -
i'd copy contents of app folder digital ocean droplet local machine, because i've accidentally removed app local machine , need back.
i've tried following, example,
scp -r root@104.232.321.32:/path-to-app
which gave me following,
usage: scp [-12346bcpqrv] [-c cipher] [-f ssh_config] [-i identity_file] [-l limit] [-o ssh_option] [-p port] [-s program] [[user@]host1:]file1 ... [[user@]host2:]file2
how copy app local machine? need set destination scp work, destination can set copys local machine, /user/sites directory?
try:
scp -r root@104.232.321.32:/path-to-app .
this should copy current directory. do:
scp -r root@104.232.321.32:/path-to-app ~/project
to copy specific folder.
two tangential observations, way:
- stop using digitalocean droplet root. should make own user account on droplet , set ssh authentication.
- you should using git keep remote copy of project , local copy in sync, not
scp
(granted, may strange case, making sure you're aware).
Comments
Post a Comment