GCP-CLOUD-TASK

MAYANK VARSHNEY
4 min readSep 11, 2020

--

Deployment of WordPress-Web Application by Integrating Google Cloud Platform with Kubernetes

# TASK DETAILS:

1.Create multi projects with dev and prod

2. Create VPC network for dev project

3.Create VPC network for prod project

4. Connect both the VPC network with VPC peering

5. Create a Kubernetes Cluster in dev project and launch a WordPress application with the Load balancer

6. Create a SQL server in prod project and create a database

7. Connect the SQL database with the application launched in the K8s cluster

🛑 I completed this project using Google Qwiklabs

Google Cloud Platform

Google Cloud Platform (GCP), offered by Google, is a suite of cloud computing services that runs on the same infrastructure that Google uses internally for its end-user products, such as Google Search, Gmail and YouTube.

  1. For building any kind of Infrastructure on Google Cloud Platform we have to build it under a project . So, I created one project named as cloudproject for both platforms as development and production .

2. Under these project we have to create two VPC ( Virtual Private Cloud ) one for WordPress deployment and second for MySQL Database Instance . I have created these VPC in different regions as VPC1 in us-central1 and VPC2 in us-east1 resp . As inside VPC we have to create subnet for networking actions of the instances . One more thing we have to do is attaching firewall rule which allows all traffic to come inside the VPC as Ingress Rule .

→Creating firewall rule for Ingress traffic :

3. Create a link between both the VPC networks using VPC Peering

4. Now both VPC got connected by VPC peering .Then we have build a kubernetes master slave architecture i.e cluster for deployment of WordPress application .For kubernetes we don’t need to create our own cluster and configure master and all because Google Cloud Platform provides Kubernetes As A Service by Google Kubernetes Engine .

To use Google Kubernetes Engine service we just have to tell the specifications in terms of Node Pool to them .Then they take all the responsibility further to create kubernetes cluster and about cluster management .

→ Creating Kubernetes Cluster for development platform :

5. Create a SQL server in the production project and create a database

6. Connect the SQL database to the web application launched in the Kubernetes cluster

7. Finally , copy the external IP of the kubernetes cluster and paste it to browser!

At last, we are done with the Deployment of WordPress-Web Application by Integrating Google Cloud Platform with Kubernetes.

Thank You!

--

--

MAYANK VARSHNEY
MAYANK VARSHNEY

Written by MAYANK VARSHNEY

I am a forward-thinking individual with exceptional skills in problem-solving, adaptive thinking, automation, and development.

No responses yet