Network Policy and GKE

Network Policy and GKE

You can enable network policy enforcement when you create a GKE cluster or enable it for an existing cluster. You can also disable network policy for an existing cluster. Once you have enabled network policy in your cluster, you can create a network policy by using the Kubernetes Network Policy API.

Hi everyone, this time it's another basic configuration revisit and describe the concept of Network Policy in Kubernetes, especially if we want to use it in our GKE environment.

What is Network Policy?

NetworkPolicies are an application-centric construct which allow you to specify how a [pod_]( is allowed to communicate with various network “entities” (we use the word “entity” here to avoid overloading the more common terms such as “endpoints” and “services”, which have specific Kubernetes connotations) over the network. — [](

In a summary, we can create a whitelist of ingress and egress for our selected pods. It's similar to how we are able to create firewall policy in GCP while maintaining the Deny-All and then create higher priority firewall rules to whitelist selected policy we decide to. Or in a more simple way, which port we allow to go in (ingress) or to go out (egress).

Now it is particularly easy to imagine the firewall policy, however if I am a newcomer that wants to test Kubernetes, the idea of creating a firewall policy within the Kubernetes cluster seems quite daunting (Or at least that how I feel back then :D)

ingress egress network-policies kubernetes gke

Bootstrap 5 Complete Course with Examples

Bootstrap 5 Tutorial - Bootstrap 5 Crash Course for Beginners

Nest.JS Tutorial for Beginners

Hello Vue 3: A First Look at Vue 3 and the Composition API

Building a simple Applications with Vue 3

Deno Crash Course: Explore Deno and Create a full REST API with Deno

How to Build a Real-time Chat App with Deno and WebSockets

Convert HTML to Markdown Online

HTML entity encoder decoder Online

50+ Useful Kubernetes Tools for 2020 - Part 2

Our original Kubernetes tool list was so popular that we've curated another great list of tools to help you improve your functionality with the platform.

Improving Kubernetes Security with Open Policy Agent (OPA)

Get started with Open Policy Agent (OPA) and enforce policies automatically in your organization across your Kubernetes clusters at scale. OPA provides technology that helps unify policy enforcement across a wide range of software and enable or empower administrators with more control over their systems.

Generating Kubernetes Network Policies Automatically

Generating Kubernetes Network Policies Automatically By Sniffing Network Traffic. This blog post is about an experiment to automate creation of Kubernetes Network Policies based on actual network traffic captured from applications running on a Kubernetes cluster.

Supporting the Evolving Ingress Specification in Kubernetes 1.18

Earlier this year, the Kubernetes team released Kubernetes 1.18, which extended Ingress. In this blog post, we’ll walk through what’s new in the new Ingress specification, what it means for your applications, and how to upgrade to an ingress controller that supports this new specification. What is Kubernetes Ingress When deploying your applications in Kubernetes, one of the first challenges many people encounter is how to get traffic into their cluster.

What is Kubernetes Ingress and How to setup Ingress?

Whenever you want to expose any service which is running inside Kubernetes then there are a couple of ways to do it but the easiest one is to have an Ingress.