Skip to content

Commit 77f13d0

Browse files
committed
Update Blog “exposing-an-application-using-ingress-and-tls-termination-on-kubernetes-in-hpe-greenlake-for-private-cloud-enterprise”
1 parent 9291f6f commit 77f13d0

File tree

2 files changed

+19
-12
lines changed

2 files changed

+19
-12
lines changed

content/blog/exposing-an-application-using-ingress-and-tls-termination-on-kubernetes-in-hpe-greenlake-for-private-cloud-enterprise.md

Lines changed: 19 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
2-
title: Exposing an application using Ingress and TLS termination on Kubernetes
3-
in HPE GreenLake for Private Cloud Enterprise
4-
date: 2024-02-21T09:22:08.283Z
2+
title: Exposing applications using Ingress and TLS termination on Kubernetes in
3+
HPE GreenLake for Private Cloud Enterprise
4+
date: 2024-03-14T13:35:56.941Z
55
author: Guoping Jia
66
authorimage: /img/guoping.png
77
disable: false
@@ -20,15 +20,17 @@ tags:
2020
---
2121
<style> li { font-size: 27px; line-height: 33px; max-width: none; } </style>
2222

23-
This blog post describes the process to expose an application that's deployed and runs on Kubernetes in HPE GreenLake for Private Cloud Enterprise to the external world.
24-
A Nginx app that serves as a Web server that prints out a customized application name will be used as a sample app to expose. The application itself will be deployed as
25-
the service type of *ClusterIP*, running on the port 80 over HTTP. Using cert-manager and TLS termination on configured MetalLB load balancer, the application will be exposed over HTTPS.
23+
This blog post describes the process to expose applications that are deployed and run on Kubernetes (K8s) in HPE GreenLake for Private Cloud Enterprise to the external world.
24+
Three Nginx apps that serve as Web servers and each prints out a customized message will be used as sample applications to expose. The applications themselves will be deployed as
25+
the service types of *ClusterIP*, running on the port 80 over HTTP. Using cert-manager and TLS termination on configured MetalLB load balancer, the applications will be exposed over HTTPS.
2626

2727
### Overview
2828

2929
[HPE GreenLake for Private Cloud Enterprise: Containers](https://www.hpe.com/us/en/greenlake/containers.html), one of the HPE GreenLake cloud services available on the HPE GreenLake for Private Cloud Enterprise, allows customers to create a Kubernetes (K8s) cluster, view details about existing clusters, and deploy containerized applications to the cluster. It provides an enterprise-grade container management service using open source K8s.
3030

31-
When application workloads get deployed to the K8s cluster, you can create services to expose the applications. By default, a service is created with the service type of *ClusterIP* that supports internal connectivity between different components of the application. In HPE GreenLake for Private Cloud Enterprise: Containers, you can create services with the type of NodePort for the application workloads deployed in K8s clusters using the label hpecp.hpe.com/hpecp-internal-gateway=true. The services will be automatically exposed to a container platform gateway host with assigned ports. The deployed workloads will become accessible externally using the gateway host name and the assigned ports as access URLs. For both service type, *ClusterIP* and NodePort , applications themselves run on HTTP. There is one common requirement to expose the applications to be accessed securely over HTTPS. This requires to get a valid SSL/TLS certificate in K8s and work with load balancers and Ingress.
31+
When application workloads get deployed to the K8s cluster, you can create services to expose the applications. By default, a service is created with the service type of *ClusterIP* that supports internal connectivity between different components of the application. In HPE GreenLake for Private Cloud Enterprise: Containers, you can create services with the type of NodePort for the application workloads deployed in K8s clusters using the label hpecp.hpe.com/hpecp-internal-gateway=true. The services will be automatically exposed to a container platform gateway host with assigned ports. The deployed workloads will become accessible externally using the gateway host name and the assigned ports as access URLs. For both service type, *ClusterIP* and NodePort , applications themselves run on HTTP. There is one common requirement to expose the applications to be accessed securely over HTTPS. This requires to get a valid SSL/TLS certificate in K8s and work with load balancers and Ingress.
32+
33+
![](/img/tls-termination-s.png)
3234

3335
This blog post, I
3436

@@ -37,10 +39,15 @@ This blog post, I
3739
Before starting, make sure you have the following:
3840

3941
* A K8s cluster, being provisioned in HPE GreenLake for Private Cloud Enterprise
40-
* The kubectl CLI tool, together with the kubeconfig file for accessing the K8s cluster
41-
* The optional openssl CLI tool, for validating the generated certificates
42+
* The *kubectl* CLI tool, together with the kubeconfig file for accessing the K8s cluster
43+
* The Helm CLI tool, version 3.12.0 or later
44+
* A domain and a list of subdomain to generate the SSL certificate and host your applications in the cluster
45+
46+
### Set up load balancer with MetalLB
47+
48+
You can install and set up the load balancer by following up the blog post [Setting up the load balancer with MetalLB](https://developer.hpe.com/blog/set-up-load-balancer-with-metallb-in-hpe-greenlake-for-private-cloud-enterprise/).
4249

43-
### Set up load balancer
50+
Here is the deployed MetalLB to the namespace *metallb-system* in the cluster:
4451

4552
```shell
4653
$ kubectl get all -n metallb-system
@@ -66,13 +73,13 @@ NAME DESIRED CURRENT READY AGE
6673
replicaset.apps/controller-57b4fdc957 1 1 1 22m
6774
```
6875

76+
Here is the range of virtual IP addresses, *"10.6.115.251-10.6.115.254"*, defined in the CRD resource *IPAddressPool*, and the layer 2 service IP address announcement in the CRD resource *L2Advertisement*:
77+
6978
```shell
7079
$ kubectl get ipaddresspools -n metallb-system
7180
NAME AUTO ASSIGN AVOID BUGGY IPS ADDRESSES
7281
cfe-pool true false ["10.6.115.251-10.6.115.254"]
73-
```
7482

75-
```shell
7683
$ kubectl get l2advertisements -n metallb-system
7784
NAME IPADDRESSPOOLS IPADDRESSPOOL SELECTORS INTERFACES
7885
cfe-l2advert ["cfe-pool"]

static/img/tls-termination-s.png

158 KB
Loading

0 commit comments

Comments
 (0)