Here is a hint for those who are trying to connect to you MySQL database server using phpMyAdmin.
It is assumed that you have already setup your Google Cloud server, installed Apache, MySQL and phpMyAdmin.
Opening up phpMyAdmin for access from any machine is not a safe thing to do. Again, adding your IP to the phpMyAdmin.conf everytime is not advisable either.
The best thing to do is to create a tunnel connection to your server, using the following instructions.
When you access phpmyadmin before creating the tunnel, shows you an error message similar to the one on the left.
So, open the Cloud SDK Shell.
Then create a tunnel using the following command.
gcloud compute ssh <NAME-OF-INSTANCE-FOR-THE-TUNNEL>
--zone <ZONE-WHERE-YOUR-INSTANCE-IS-LOCATED> --ssh-flag="-L" --ssh-flag="8888:localhost:80"
eg., gcloud compute ssh myCentos-1
--zone us-central1-b--ssh-flag="-L" --ssh-flag="8888:localhost:80&…