Laravel Forge cannot connect to server
We have a Digital Ocean server managed through Laravel Forge and several WordPress sites hosted on the server. Last week all the sites went down and a WordPress error message “Your PHP installation appears to be missing the MySQL extension which is required by WordPress.” We hadn’t touched the server in quite some time and my assumption was that there was an update of the php version that caused a conflict.
I’m a bit of a noob but managed to resolve this by logging into the Digital Ocean console and updating the MySQL on the server. Afterwards there were some issues on the Wordpress sites that wouldn’t allow media to be uploaded or plugins to be updated. After a bit of research and investigation, I saw that forge wasn’t connected to the server and it seemed to be because the root password had expired. I updated the server root password and this resolved those issues.
Since then, our FTP access to the forge server has not worked and it appears to be because forge cannot connect to the sever. If I try to create a new SSH key in Laravel forge I get a message saying “We were unable to add a SSH key to your server” and details about adding a particular key to /home/forge/.ssh/authorizedkeys file and the /root/.ssh/authorizedkeys file, although these already exist. I contacted support at Laravel Forge and was told “When forge tries to connect to the server as user forge we get asked for a password, we won’t be able to access your server until you resolve this”
Talked to Digital Ocean support about this and they didn’t really have a solution. The one thing suggested was to go to the sshd_config file and change PasswordAuthentication to ‘no’. I have tried this and it forge still can’t connect to the server.
Does anyone have a potential solution for us to reestablish the connection and FTP?