I hit a little snag today while trying to connect to MAMP using the OS X Terminal. I must admit I’m very new to the command line, so this may be obvious to many but it wasn’t to me.
Failed Connection
ssh root@localhost
This was throwing an error telling me that port 22 wasn’t available. I know that out of the box MAMP uses port 8888 for apache, so I added that port into the SSH command.
Successful Connection
ssh root@localhost -p 8889
That did the trick! Hopefully it saves some time for other command line newbies like me out there.