Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to install sshpass on Mac?

Tags:

macos

ssh

sshpass

People also ask

How do I download Sshpass on Mac?

You can do this by going to Preferences > Downloads > Command Line Tools and clicking on the Install button. Once everything is installed and setup you can continue with the installation of sshpass. The sshpass program is an open source project, currently available on sourceforge.

How do I enable SSH on Mac?

To find the SSH command to use to log in to your Mac from another computer, choose Apple menu > System Preferences, click Sharing , then select Remote Login. The SSH command is shown below the “Remote Login: On” indicator. Allowing remote login to your Mac can make it less secure. See Set up your Mac to be secure.

How install Sshpass Linux?

Install sshpass on Linux Systems In RedHat/CentOS based systems, first you need to enable Epel repository on your system to install it using yum command as shown. On Debian/Ubuntu and its derivatives, you can install it using apt-get command as shown.

What is Sshpass program?

What is sshpass? sshpass is a command-line tool that allows you to do non-interactive ssh login. So how is sshpass different for ssh? Well, ssh uses direct TTY access to ensure that an interactive keyboard user issues the password.


There are instructions on how to install sshpass here:

https://gist.github.com/arunoda/7790979

For Mac you will need to install xcode and command line tools then use the unofficial Homewbrew command:

curl -L https://raw.githubusercontent.com/kadwanev/bigboybrew/master/Library/Formula/sshpass.rb > sshpass.rb && brew install sshpass.rb && rm sshpass.rb

Some years have passed and there is now a proper Homebrew Tap for sshpass, maintained by Aleks Hudochenkov. To install sshpass from this tap, run:

brew install hudochenkov/sshpass/sshpass

Another option in 2020 is this homebrew tap, maintained by esolitos

brew install esolitos/ipa/sshpass

Solution provided by lukesUbuntu from github works for me:

Just use brew

$ brew install http://git.io/sshpass.rb