I am trying to copy a file from my gcp instance to Kaggle (I tried other servers/PCs only to face the same issue).
The issue is that when running the command:
scp -i ./key user@ip_address:/path/to/file /kaggle/working/file
I get:
bash: line 1: scp: command not found
I have figured that the issue has something to do with the environment that my gcp server is using because the following command works as it should, so all the permissions are in place and key is valid:
ssh -i ./key user@ip_address
And when connected I can use the scp command no problem. But what seems suspicious to me is that this command:
ssh -i ./key user@ip_address 'echo $PATH'
outputs:
$PATH:/opt/python/3.9.2/bin:$HOME/.local/bin
And does not clearly include /usr/bin/scp where I confirmed scp is located.
What can be done to fix this? Am I doing something wrong here?