Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Updated Install Guides #49

Merged
merged 16 commits into from
May 2, 2023
4 changes: 4 additions & 0 deletions DESIGN.md
Original file line number Diff line number Diff line change
Expand Up @@ -107,3 +107,7 @@ having defaults set to a base of 2 seconds, and a maximum of 60 seconds.

The Synchronizer uses a jitter mechanism to avoid thrashing the NGINX Plus hosts. Each `core.ServerUpdateEvent` instance
is added to the "nkl-synchronizer" queue with a random jitter value between 250 and 750 milliseconds.

## Authors
- Steve Wagner - Solutions Architect - Community and Alliances @ F5, Inc.
- Chris Akker - Solutions Architect - Community and Alliances @ F5, Inc.
81 changes: 57 additions & 24 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,68 +1,95 @@
# nginx-k8s-loadbalancer

## Welcome to the Nginx Kubernetes Load Balancer project !

<br/>

This repo contains source code and documents for a new Kubernetes Controller, that provides TCP load balancing external to a Kubernetes Cluster running On Premises.
# Welcome to the Nginx Kubernetes Load Balancer Solution!

<br/>

>>**This is a replacement for a Cloud Providers "Service Type Loadbalancer", that is missing from On Premises Kubernetes Clusters.**
![Nginx K8s LB](docs/media/nkl-logo.png) | ![Nginx K8s LB](docs/media/nginx-2020.png)
--- | ---

<br/>

## Overview
This repo contains source code and documents for a new `Kubernetes Controller from Nginx`, that provides TCP and HTTP load balancing external to a Kubernetes Cluster running On Premises.

<br/>

- Create a new K8s Controller, that will monitor specified k8s Services, and then send API calls to an external Nginx Plus server to manage Nginx Upstream servers automatically.
- This will `synchronize` the K8s Service Endpoint list, with the Nginx LB server's Upstream server list.
- The primary use case is for tracking the NodePort IP:Port definitions for the Nginx Ingress Controller's `nginx-ingress Service`.
- With the Nginx Plus Server located external to the K8s cluster, this new controller LB function would provide an alternative TCP "Load Balancer Service" for On Premises K8s clusters, which do not have access to a Cloud providers "Service Type LoadBalancer".
- Make the solution a native Kubernetes Component, running, configured and managed with standard K8s commands.
>>**This is a replacement for a Cloud Providers `Service Type Loadbalancer`, that is not available for On Premises Kubernetes Clusters.**

<br/>
<br/>


## Reference Diagram
# Overview

- `NKL - Nginx Kubernetes Loadbalancer` is a new K8s Controller from Nginx, that monitors specified K8s Services, and then sends API calls to an external Nginx Plus server to manage Nginx Upstream servers dynamically.
- This will `synchronize` the K8s Service Endpoint list, with the Nginx LB Server's upstream list.
- The primary use case and Solution provided is for tracking the K8s` NodePort` IP:Port definitions for the Nginx Ingress Controller's `nginx-ingress Service`.
- NKL is a native Kubernetes Controller, running, configured and managed with standard K8s commands.
- NKL paired with the Nginx Plus Server located external to the K8s cluster, this new controller LB function will provide a `TCP Load Balancer Service` for On Premises K8s clusters, which do not have access to a Cloud providers "Service Type LoadBalancer".
- NKL paired with the Nginx Plus Server located external to the Cluster, using Nginx's advanced HTTP features, provide an `HTTP Load Balancer Service` for Enterprise traffic management solutions, such as:
- MultiCluster Active/Active Load Balancing
- Horizontal Cluster Scaling
- HTTP Split Clients - for A/B, Blue/Green, and Canary test and production traffic steering. Allows Cluster operations/maintainence like upgrades, patching, expansion and troubleshooting with no downtime or reloads
- Advanced TLS Processing - MutualTLS, OCSP, FIPS, dynamic cert loading
- Advanced Security features - Oauth, JWT, App Protect WAF Firewall, Rate and Bandwidth limits
- Nginx Java Script (NJS) for custom solutions
- Nginx Zone Sync of KeyVal data

<br/>

![NGINX LB Server](docs/media/nginxlb-nklv2.png)
## NKL Controller Software Design Overview - How it works

[NKL Controller DESIGN and Architecture](DESIGN.md)

<br/>

## Sample Screenshots of Runtime
## Reference Diagram for NKL TCP Load Balancer Service

<br/>

### Configuration with 2 Nginx LB Servers defined (HA):
![NKL Stream Diagram](docs/media/nkl-stream-diagram.png)

![NGINX LB ConfigMap](docs/media/nkl-pod-configmap.png)
<br/>

## Sample Screenshots of Solution at Runtime

<br/>

### Nginx LB Server Dashboard and Logging
![NGINX LB ConfigMap](docs/media/nkl-configmap.png)
### ConfigMap with 2 Nginx LB Servers defined for HA

<br/>

![NGINX LB Create Nodeport](docs/media/nkl-create-nodeport.png)
![NGINX LB Create Nodeport](docs/media/nkl-stream-create-nodeport.png)
### Nginx LB Server Dashboard, NodePort, and NKL Controller Logging

Legend:
- Red - kubectl commands
### Legend:
- Red - kubectl nodeport commands
- Blue - nodeport and upstreams for http traffic
- Indigo - nodeport and upstreams for https traffic
- Green - logs for api calls to LB Server #1
- Green - NKL log for api calls to LB Server #1
- Orange - Nginx LB Server upstream dashboard details
- Kubernetes Worker Nodes are 10.1.1.8 and 10.1.1.10

<br/>

## Requirements
The `Installation Guide` for TCP Loadbalancer Solution is located in the docs/tcp folder:

[TCP Installation Guide](docs/tcp/tcp-installation-guide.md)

<br/>

Please see the /docs folder for detailed documentation.
The `Installation Guide` for HTTP Loadbalancer Solution is located in the docs/http folder:

[HTTP Installation Guide](docs/http/http-installation-guide.md)

<br/>

## Installation
## Requirements

Please see the /docs folder for Installation Guide.
Please see the /docs folder and Installation Guides for detailed documentation.

<br/>

Expand All @@ -72,6 +99,12 @@ Read the [`CONTRIBUTING.md`](https://github.com/nginxinc/nginx-k8s-loadbalancer/

<br/>

## Authors
- Chris Akker - Solutions Architect - Community and Alliances @ F5, Inc.
- Steve Wagner - Solutions Architect - Community and Alliances @ F5, Inc.

<br/>

## License

[Apache License, Version 2.0](https://github.com/nginxinc/nginx-k8s-loadbalancer/blob/main/LICENSE)
Expand Down
Loading