Posts

Showing posts with the label gcloud

Google Cloud Platform Practice Series

Image
Introduction Google Cloud Platform (GCP) is a suite of cloud computing services provided by Google. It allows you to build, deploy, and scale applications, websites, and services on the same infrastructure that Google uses internally for its end-user products like Google Search, Gmail, and YouTube. Key Features of GCP Compute Services: Includes virtual machines (VMs) with Google Compute Engine, serverless computing with Google Cloud Functions, and container orchestration with Google Kubernetes Engine (GKE). Storage and Databases: Offers various storage options like Google Cloud Storage for object storage, Google Cloud SQL for managed relational databases, and Google Bigtable for NoSQL databases. Networking: Provides a global network infrastructure with services like Virtual Private Cloud (VPC), Cloud Load Balancing, and Cloud CDN for content delivery. Big Data and Machine Learning: Includes tools like BigQuery for data warehousing, Dataflow for stream and batch data processing, and AI

Kubernetes Practice Series

Image
Introduction Kubernetes (often abbreviated as K8s ) is an open-source system designed to automate the deployment, scaling, and management of containerized applications. This page serves as a collection of articles related to Kubernetes (K8s) , including theoretical concepts and practical guides on using Kubernetes to set up essential tools for the software development process. I will continue to update this series with new articles as ideas come to mind, to ensure the series becomes more comprehensive. The articles are arranged in increasing order of difficulty to make it easier for you to follow. If you have time, it's recommended that you start from the beginning of the series to acquire the necessary knowledge and information that will prepare you for the subsequent articles. Key Topics Covered in This Series Basic Knowledge : Fundamental concepts, common commands, etc. Resources : Pod, Deployment, Service, StatefulSet, Ingress, etc. Pod Autoscaler : Horizontal vs. Vertical sc

Helm for beginer - Deploy nginx to Google Kubernetes Engine

Image
Introduction Helm is a package manager for Kubernetes , which simplifies the process of deploying and managing applications on Kubernetes clusters. Helm uses a packaging format called charts , which are collections of files that describe a related set of Kubernetes resources. Key Components of Helm Charts : Helm packages are called charts. A chart is a collection of files that describe a related set of Kubernetes resources. A single chart might be used to deploy something simple, like a memcached pod, or something complex, like a full web app stack with HTTP servers , databases, caches, and so on. Values : Charts can be customized with values, which are configuration settings that specify how the chart should be installed on the cluster. These values can be set in a ` values.yaml ` file or passed on the command line. Releases : When you install a chart, a new release is created. This means that one chart can be installed multiple times into the same cluster, and each can be indep

Deploy React Application to Google Kubernetes Engine

Image
Introduction In this article, I will guide you through deploying a React Application to Google Kubernetes Engine (GKE) . Previously, I wrote an article about deploying a NodeJS Application to GKE , which you can refer to for some basic information before continuing. Steps to Follow The process is quite similar to deploying a NodeJS Application and includes the following steps: Create a React Application Build a Docker image Push the Docker image Deploy the Docker image to GKE You will notice that when working with Kubernetes , the main difference is in the step where you build the Docker image . Depending on the application you need to deploy, there are different ways to build the Docker image . However, the common point is that once you build the Docker image , you have completed almost half of the process. This is because the subsequent steps involving Kubernetes are entirely the same. Detailed Process 1. Create a React Application In this step, you can either use an existing R

Deploy NodeJS Typescript to Google App Engine

Image
Introduction In this guide, I will walk you through deploying a NodeJS Typescript application to Google App Engine (GAE) . GAE offers a straightforward and quick deployment process for various programming languages. If you're developing your NodeJS app using JavaScript , deploying it is pretty straightforward. However, if you're using Typescript , there's an extra step you'll need to take, which I'll explain here. Prerequisites Before we proceed, ensure you have the following: A Google Cloud account with Google App Engine enabled. The gcloud CLI installed. Creating a NodeJS Typescript Project First, create a file named ` src/main.ts ` with the following content: import express from 'express' const app = express () const port = 8080 app . get ( '/' , ( req , res ) => { res . send ( 'This is NodeJS Typescript Application! Current time is ' + Date . now ()) }) app . listen ( port , () => { console . log ( `Server is runn

Kubernetes Pod Cheatsheet

Image
Introduction This article is here to guide you on using Pod  in Kubernetes . I'll give you some concepts and commands that Kubernetes often uses to handle Pod . Pod Introduction A Pod is the smallest deployable unit in Kubernetes . Here are some key points about Pods: Multiple Containers : A Pod can contain more than one container, and there's no limit to how many containers you can run inside a Pod. These containers are relatively tightly coupled and share resources such as disk. Shared Resources : All the containers inside a Pod are connected via localhost and share the same memory space. They also share storage (volumes), IP address, and configuration information. Unique IP Address : Each Pod gets a unique IP address. Ephemeral Nature : Pods are ephemeral in nature; they can be created, deleted, and updated. Prerequisites Before we begin, make sure you have the following: For Kubernetes systems, you can use minikube or have permissions to provision resources on cloud pro

Using Terraform to Create VM Instances and Connect via SSH

Image
Introduction In the previous article, I introduced some basic concepts about Terraform , as well as the advantages of using Terraform . If you're not familiar with it yet, take a look to get some basic knowledge before diving into the next topics . In this article, I will guide you through writing Terraform files to deploy a Virtual Machine (VM) instance to the Google Cloud Provider . Creating a Service Account If you already have a Google Cloud account with the necessary permissions, you can log in to work with Terraform as I instructed in the previous article. However, if for some reason you can't log in, or if you need a better authentication method, you can create a Service Account to use. In simple terms, a Google Cloud account is allowed to create Service Accounts . Each Service Account is assigned roles , and each role has corresponding permissions allowing the Service Account to perform specific tasks based on permissions . To create a Service Account , use th