How to ssh with Amonite supplying the password in advance

93 views Asked by At

Problem: I need to access a command line API on a Remote machine.

I am playing with Scala Amonite libs, i wonder if there is a way to ssh and supply the password, so that i can do it from within an application and not have to enter the pass in the middle of it.

1

There are 1 answers

0
Aron T On BEST ANSWER

It's best to use public key authentication not passwords. It's a best practice regardless, & solves your problem of ssh from inside a script without having to provide a password.