Copy/Transfer files from local mac to local linux using python

186 Views Asked by At

I am trying to automate copy/transfer a file from my local mac machine to a local nanopi-neo-linux machine. The two machine are connected via serial cable using VCP driver of Silicon Labs

scp [email protected]:/path/to/myfile.txt /Users/Jamie/local/path/to/myfile.txt

scp and ssh requires the host address/IP addres of the nanopi-neo-linux but I cannot get it without accessing it. I am accessing different nanopi-neo-linux machines so the IP address is dynamic.

Is there a way to directly copy/transfer a file without getting the IP address? or is it possible to directly extract the host address/IP address of nanopi-neo-linux so I can make it a variable?

0

There are 0 best solutions below