WordPress certified by bitnami on google cloud platform

Introduction

This article provides complete guide for hosting WordPress certified by Bitnami stack on Google cloud platform with DNS and SSL configuration for fully functional websites. Although many WordPress stacks are available on Google cloud platform, two most popular ones are – (i) WordPress Certified by Bitnami and (ii) WordPress click to deploy. We will go through following steps for hosting reliable, safe and fully functional wordpress websites (through this process, we will deploy WordPress Certified by Bitnamistack on Google Cloud compute engine).

Want to learn complete Web Development with certification? Enroll Now for Web Development Certification Training By Edureka and increase your chances to get hired by Top Tech Companies.

Before starting with this guide, you must have your Domain Name (e.g., example.com or example.in) registered. You may Register your Domain Name for most cost effective price at BigRock  or  Hostinger.

  1. Create Gmail Account

First of all, we need to create our google account (Gmail Account) because that Gmail will be required to sign up for Google Cloud Platform (GCP). We need Gmail for signing up with all the Google services. If you already have Gmail account, you may proceed to the next step. Create Gmail Account.

2. Create Free Trial GCP Account

After creating your Gmail Account, head over to Google Cloud Platform (GCP). Sign up for your Free Trial GCP Account. On GCP website, Click Get Started for Free button and follow the Account creation steps on the screen. Enter all required Personal Information details and Billing Information to create your GCP Account. You need to provide your credit card information for setting up billing account and verifying payment transaction. Rest assured, Google does not charge your credit card ever without you entering in an agreement to do so for some service. After GCP Account is set up, you can use all the technology resources available on the platform.

3. Deploy ‘WordPress certified by Bitnami’ Instance

Sign in to your GCP Account with your Gmail. Then go to Console. Click on Project menu on top and create new project by giving Project Name you like. By default, a project by name My First Project is created.

Then, click on the Hamburger icon (≡) on top left and click the menu Marketplace. Type WordPress on Search bar. Many WordPress solutions will be listed. Go to WordPress Certified by Bitnami. This is one of the best WordPress packages available.

Click Launch button which will take you to New WordPress Certified by Bitnami Deployment screen. Fill up your Zone and Disk size details or you may go with the defaults. Then click Deploy button. Deployment will take a couple of minutes and you will see details of your WordPress instance deployment on the right side. You may check your deployment here or as described in the next step.

4. Check your WordPress Deployment

Click on Hamburger icon (≡) on top left and select Deployment Manager. Select your WordPress Multisite Deployment. If you click on the Site Address URL, you will be redirected to the Sample page of your WordPress website. If you click on the Admin URL, you will be redirected to the WordPress Admin Login page. Here, fill up your Admin User ID and Admin Password from your Deployment details on gcp. Thereafter you will reach on Admin Dashboard of your WordPress multi-site. Here you will be building and making changes (edits) to your website(s) as Administrator, after all the following set up steps are complete.

5. Reserve static external IP Address

Now, Click on Hamburger icon (≡) on top left corner and select VPC Network >> External IP Addresses. Click on Reserve IP Address. Fill up all details and click Reserve. Here, change External IP Address Type from Ephemeral to Static. We do this because, when a stopped instance is started again, a new ephemeral external IP address is assigned to the instance, and we don’t want the IP Address to change each time our instance is restarted.

6. Create and Configure DNS Zone for your WordPress Hosting

Click again on Hamburger icon (≡) on top left corner of GCP screen and select Networking >> Network Services >>Cloud DNS. Here, click on Create Zone button. Fill up Zone name (usually your website domain name, in lower case, eg. example) and DNS Name (your domain name address, eg. example.com). Select Zone Type Public and DNS Sec OFF. Click Create. DNS Zone will be created.

Now create “A” Record and “C” Record:

To create “A” record, click on Add Record Set and fill the details- 

(i) DNS Name field – leave blank.

(ii) Record Type field – ‘A’.

(iii) In IPv4 field, type or paste External IP Address. Click Save.

To create “C” record, click on Add Record Set.  In DNS Name field, type subdomain “www”. In Canonical Name field, type alias this www Sub-Domain refers to (website Address, e.g., example.com).

7. Do Modification in DNS Zone of your Domain Name Provider/ Registrar   

Log in to Domain Name Registrar’s website and go to DNS Records or DNS Zone. Here, either change Name servers to point to your hosting or add the ‘A’ record of your hosting.

(i) Change Name Servers – Add all four Name Server Records of your hosting (as provided in DNS Zone of your deployment at GCP, e.g., ns-cloud-d1.googledomains.com, ns-cloud-d2.googledomains.com, ns-cloud-d3.googledomains.com, ns-cloud-d4.googledomains.com) replacing the existing Name Server records. Save Records.

(ii) Add the “A record” –  Click Add Records. Leave blank or type ‘@’ in ‘Host’ field (as specified by Domain Registrar). Type or paste external IP Address of your hosting (deployment on GCP) in ‘’DNS Name/ Points To/IP Address’’ field, as the case may  

8. Change Website Address and Home Address URL for your WordPress website

On your GCP console, click on Hamburger icon (≡) on top left corner and select Deployment Manager – Deployments. Select your Deployment and Open SSH from Right lower side of the screen. After getting SSH access of the server:

  • Type following command to open wp-config.php file in nano editor:

sudo -i
nano /opt/bitnami/apps/wordpress/htdocs/wp-config.php

In wp-config.php file, replace two lines with two other lines as follows:

REPLACE THIS:

define(‘WP_SITEURL’, ‘http://’ . $_SERVER[‘HTTP_HOST’] . ‘/’);
define(‘WP_HOME’, ‘http://’ . $_SERVER[‘HTTP_HOST’] . ‘/’);

WITH:

define(‘WP_HOME’,’http://example.com’);
define(‘WP_SITEURL’,’http://example.com’);

Replace “example.com” with your Domain Name. You may type https version of Domain Name if you are installing SSL certificate as in next step. Save and Exit.

  • Type following command to run the Bitnami HTTPS Configuration tool for SSL Certificate installation:

sudo /opt/bitnami/bncert-tool

Follow on screen instructions and prompts for SSL Certificate Installation and Auto Renewal.

  • In the resulting screen, you can enable/disable useful redirections for your stack.
  • Next, accept the list of changes proposed for your installation. If you reject the changes (by selecting ‘No’), you will go back to the Domains page.
  • Then, you will be prompted for your e-mail address, and to agree to the Let’s Encrypt Terms of Service. The e-mail is used for certificate expiration notifications.
  • Finally, the tool will perform the changes and once finished, your website will have a valid HTTPS certificate.

9. Install and activate Really Simple SSL WordPress Plugin to force ssl certificates on websites (How to install Really Simple SSL).

You may need to fix mixed content issue if you are using Elementor plugin on your website (How to fix mixed content issue in Elementor after moving to SSL).

10 Setup Mail SMTP 

Setup Mail SMTP for the WordPress websites to be able to send Emails either with:

Gmail API or Other Email service.

11. Final Words

Your WordPress Multisite is setup. Now Login as Administrator in WordPress eg. https://example.com/wp-admin/ . Go to Website Dashboard >> Settings and do required basic setup and save changes. Then, Install required Theme and Plugins and start building functional websites. All the Best. For any queries, please write to redfalconvp@gmail.com.

One final step, you may improve the security and performance of your Website (s) by signing up (Free Signup available) at Cloudflare and adding your website at cloudflare.com.

You may be interested in How to host and set up WordPress Multisite click to deploy on gcp.

That’s it! Keep editing and design stunning websites. All the best!

Leave a Reply