What am I doing wrong with gcloud scp?

30 views Asked by At
> ls *log
java_error_in_idea_12001.log    java_error_in_idea_44386.log    jbr_err_pid12001.log        jbr_err_pid44386.log

> gcloud compute scp --zone "us-central1-c" java_error_in_idea_12001.log eric.kolotyluk@kolotyluk-dev1:foo.log
java_error_in_idea_12001.log

So far so good...

> gcloud compute ssh --zone "us-central1-a" "nginx-proxy-vpn" --project "forgerock-autoid"
Last login: Tue Oct 31 17:30:54 2023 from 65.113.98.10
[eric.kolotyluk@nginx-proxy-vpn ~]$ ls
[eric.kolotyluk@nginx-proxy-vpn ~]$ ls -la
total 60
drwx------.   3 eric.kolotyluk eric.kolotyluk    95 Oct 31 17:02 .
drwxr-xr-x. 682 root           root           28672 Oct 26 22:27 ..
-rw-------.   1 eric.kolotyluk eric.kolotyluk    59 Oct 31 17:27 .bash_history
-rw-r--r--.   1 eric.kolotyluk eric.kolotyluk    18 Jul 27  2021 .bash_logout
-rw-r--r--.   1 eric.kolotyluk eric.kolotyluk   141 Jul 27  2021 .bash_profile
-rw-r--r--.   1 eric.kolotyluk eric.kolotyluk   376 Jul 27  2021 .bashrc
drwx------.   2 eric.kolotyluk eric.kolotyluk    29 Oct 26 22:27 .ssh

Apparently this is a noop, and there are no warnings or error messages to indicate gcloud did nothing...

Is there something I am doing wrong?

1

There are 1 answers

1
codeangler On

You may need to include a full path to the destination.

> gcloud compute scp --zone "us-central1-c" java_error_in_idea_12001.log eric.kolotyluk@kolotyluk-dev1:~/foo.log