Access WordPress Database via SSH Tunnel on Mac

Jan 7, 2019
SSH, WordPress

To access the MySQL database behind a WordPress site that is hosted on the cloud from a remote Mac, it’s relatively simple: establish a SSH tunnel and then use any browser to visit the phpMyAdmin. First, establish the SSH tunnel to the host machine: ssh -N -L SOURCE-PORT: -i KEYFILE USERNAME@SERVER-IP Because by default phpMyAdmin is running on port 8888, the above commband becomes: ssh -N -L 8888: -i KEYFILE USERNAME@SERVER-IP Second, open browser and visit 127. ...