DEV Community

Trevor
Trevor

Posted on

From your local server (Xampp) to Google Cloud VM

My university friend needed help on deploying to GCP, however, it made me such all over the internet until I found a solution. Have decided to share it so it can be of help to some else out there. This is a brief one but will update it with screenshots when I settle down.

In case you have a website or web app developed using HTML template, PHP, and MSQL database, you can freely host it on google cloud with the same setup as your local computer in a few minutes. Let's break down the steps:

  1. Deploy a LAMP Stack VM from the marketplace using Deployment Manager
  2. Navigate into the /var/www/html folder, delete the default index.html file 3. Using SSH connection, connect your VM to your local machine 4. Copy all files in Xampp into VM /var/www/html folder
  3. Access phpmyadmin of the VM by adding /phpmyadmin after its External IP 6. Export local database content to VM database

Top comments (0)