Add MicroK8s, Helm and Dokku to the documentation
This commit is contained in:
parent
89c4799efa
commit
58bda7eef0
8 changed files with 160 additions and 67 deletions
26
README.md
26
README.md
|
|
@ -5,6 +5,7 @@
|
|||
[](https://github.com/byjg/docker-easy-haproxy/)
|
||||
[](https://opensource.byjg.com/opensource/licensing.html)
|
||||
[](https://github.com/byjg/docker-easy-haproxy/releases/)
|
||||
[](https://opensource.byjg.com/helm)
|
||||
|
||||

|
||||
|
||||
|
|
@ -47,18 +48,27 @@ The steps are:
|
|||
|
||||
For detailed instructions on how to use EasyHAProxy, follow the instructions for the platform you want to use:
|
||||
|
||||
| [Kubernetes](docs/kubernetes.md) | [Docker Swarm](docs/swarm.md) | [Docker](docs/docker.md) | [Static](docs/static.md)
|
||||
|:----------:|:------------:|:------:|:-------:
|
||||
|  |  |  | 
|
||||
[](docs/kubernetes.md)
|
||||
[](docs/swarm.md)
|
||||
[](docs/docker.md)
|
||||
[](docs/static.md)
|
||||
|
||||
Or you can install using tools:
|
||||
|
||||
[](docs/helm.md)
|
||||
[](docs/microk8s.md)
|
||||
[](docs/dokku.md)
|
||||
|
||||
## See EasyHAProxy in action
|
||||
|
||||
Click on the image to see the videos (use HD for better visualization)
|
||||
| | |
|
||||
|:----------:|:------------:|
|
||||
| [](https://youtu.be/ar8raFK0R1k) | [](https://youtu.be/xwIdj9mc2mU) |
|
||||
| [](https://youtu.be/uq7TuLIijks) | [](https://youtu.be/v9Q4M5Al7AQ) |
|
||||
| [](https://youtu.be/B_bYZnRTGJM) | [](https://youtu.be/JHqcq9crbDI) |
|
||||
|
||||
[](https://youtu.be/ar8raFK0R1k)
|
||||
[](https://youtu.be/xwIdj9mc2mU)
|
||||
[](https://youtu.be/uq7TuLIijks)
|
||||
[](https://youtu.be/v9Q4M5Al7AQ)
|
||||
[](https://youtu.be/B_bYZnRTGJM)
|
||||
[](https://youtu.be/JHqcq9crbDI)
|
||||
|
||||
[Here is the code](https://gist.github.com/byjg/e125e478a0562190176d69ea795fd3d4) applied in the examples above.
|
||||
|
||||
|
|
|
|||
7
docs/dokku.md
Normal file
7
docs/dokku.md
Normal file
|
|
@ -0,0 +1,7 @@
|
|||
# Dokku
|
||||
|
||||
Dokku is a Docker powered mini-Heroku in around 100 lines of Bash. It is the smallest PaaS implementation you've ever seen, weighing in at a little over 100 MB of memory usage and about 80 MB of disk space.
|
||||
|
||||
## Installing EasyHAProxy on Dokku
|
||||
|
||||
Please refer to the [official documentation](https://github.com/dokku/dokku/blob/master/docs/networking/proxies/haproxy.md).
|
||||
BIN
docs/easyhaproxy_dokku.png
Normal file
BIN
docs/easyhaproxy_dokku.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 8.8 KiB |
BIN
docs/easyhaproxy_helm.png
Normal file
BIN
docs/easyhaproxy_helm.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 5.7 KiB |
BIN
docs/easyhaproxy_microk8s.png
Normal file
BIN
docs/easyhaproxy_microk8s.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 4.1 KiB |
79
docs/helm.md
Normal file
79
docs/helm.md
Normal file
|
|
@ -0,0 +1,79 @@
|
|||
# Helm 3
|
||||
|
||||
Helm is a package manager for Kubernetes. It allows you to install and manage applications on Kubernetes.
|
||||
|
||||
## Setup EasyHAProxy with Helm 3
|
||||
|
||||
### 1) Identify the node where your EasyHAProxy container will run
|
||||
|
||||
EasyHAProxy will be limited to a single node. To understand that see [limitations](limitations.md) page.
|
||||
|
||||
```bash
|
||||
$ kubectl get nodes
|
||||
|
||||
NAME STATUS ROLES AGE VERSION
|
||||
node-01 Ready <none> 561d v1.21.13-3
|
||||
node-02 Ready <none> 561d v1.21.13-3
|
||||
```
|
||||
|
||||
Add the EasyHAProxy label to the node.
|
||||
|
||||
```bash
|
||||
kubectl label nodes node-01 "easyhaproxy/node=master"
|
||||
```
|
||||
|
||||
### 2) Install EasyHAProxy
|
||||
|
||||
Minimal configuration
|
||||
|
||||
```bash
|
||||
helm repo add byjg https://opensource.byjg.com/helm
|
||||
helm repo update byjg
|
||||
kubectl create namespace easyhaproxy
|
||||
|
||||
helm upgrade --install ingress byjg/easyhaproxy \
|
||||
--namespace easyhaproxy \
|
||||
--set resources.requests.cpu=100m \
|
||||
--set resources.requests.memory=128Mi
|
||||
```
|
||||
|
||||
Customizing Helm Values:
|
||||
|
||||
```yaml
|
||||
easyhaproxy:
|
||||
stats:
|
||||
username: admin
|
||||
password: password
|
||||
refresh: "10"
|
||||
customErrors: "true"
|
||||
sslMode: loose
|
||||
logLevel:
|
||||
certbot: DEBUG
|
||||
easyhaproxy: DEBUG
|
||||
haproxy: DEBUG
|
||||
letsencrypt:
|
||||
email: ""
|
||||
|
||||
service:
|
||||
create: false # If false, it will create a DaemonSet with hostPort. The easiest.
|
||||
type: ClusterIP # or NodePort
|
||||
annotations: {}
|
||||
|
||||
binding:
|
||||
ports:
|
||||
http: 80
|
||||
https: 443
|
||||
stats: 1936
|
||||
additionalPorts: []
|
||||
|
||||
# Make sure to create this
|
||||
masterNode:
|
||||
label: easyhaproxy/node
|
||||
values:
|
||||
- master
|
||||
```
|
||||
|
||||
For more parameters you can refer to the [Kubernetes](kubernetes.md) page.
|
||||
|
||||
----
|
||||
[Open source ByJG](http://opensource.byjg.com)
|
||||
|
|
@ -12,7 +12,7 @@ There are three installation modes:
|
|||
|
||||
To install EasyHAProxy in your cluster, follow these steps:
|
||||
|
||||
### 1) Identify the node where your EasyHAProxy container will run.
|
||||
### 1) Identify the node where your EasyHAProxy container will run
|
||||
|
||||
EasyHAProxy will be limited to a single node. To understand that see [limitations](limitations.md) page.
|
||||
|
||||
|
|
@ -30,11 +30,7 @@ Add the EasyHAProxy label to the node.
|
|||
kubectl label nodes node-01 "easyhaproxy/node=master"
|
||||
```
|
||||
|
||||
### 2) Install EasyHAProxy
|
||||
|
||||
You can install EasyHAProxy in a Kubernetes cluster using Kubernetes Manifest or Helm 3.
|
||||
|
||||
#### 2.1.) Using Kubernetes Manifest
|
||||
### 2) Install EasyHAProxy with Kubernetes Manifest
|
||||
|
||||
```bash
|
||||
kubectl create namespace easyhaproxy
|
||||
|
|
@ -45,57 +41,6 @@ kubectl apply -f \
|
|||
|
||||
If necessary, you can configure environment variables. To get a list of the variables, please follow the [docker container environment](docker-environment.md)
|
||||
|
||||
#### 2.2) Using HELM 3
|
||||
|
||||
Minimal configuration
|
||||
|
||||
```bash
|
||||
helm repo add byjg https://opensource.byjg.com/helm
|
||||
helm repo update byjg
|
||||
kubectl create namespace easyhaproxy
|
||||
|
||||
helm upgrade --install ingress byjg/easyhaproxy \
|
||||
--namespace easyhaproxy \
|
||||
--set resources.requests.cpu=100m \
|
||||
--set resources.requests.memory=128Mi
|
||||
```
|
||||
|
||||
Customizing Helm Values:
|
||||
|
||||
```yaml
|
||||
easyhaproxy:
|
||||
stats:
|
||||
username: admin
|
||||
password: password
|
||||
refresh: "10"
|
||||
customErrors: "true"
|
||||
sslMode: loose
|
||||
logLevel:
|
||||
certbot: DEBUG
|
||||
easyhaproxy: DEBUG
|
||||
haproxy: DEBUG
|
||||
letsencrypt:
|
||||
email: ""
|
||||
|
||||
service:
|
||||
create: false # If false, it will create a DaemonSet with hostPort. The easiest.
|
||||
type: ClusterIP # or NodePort
|
||||
annotations: {}
|
||||
|
||||
binding:
|
||||
ports:
|
||||
http: 80
|
||||
https: 443
|
||||
stats: 1936
|
||||
additionalPorts: []
|
||||
|
||||
# Make sure to create this
|
||||
masterNode:
|
||||
label: easyhaproxy/node
|
||||
values:
|
||||
- master
|
||||
```
|
||||
|
||||
## Running containers
|
||||
|
||||
Your container only requires creating an ingress with the annotation `kubernetes.io/ingress.class: easyhaproxy-ingress` pointing to your service.
|
||||
|
|
|
|||
52
docs/microk8s.md
Normal file
52
docs/microk8s.md
Normal file
|
|
@ -0,0 +1,52 @@
|
|||
# Microk8s Add-ons
|
||||
|
||||
Microk8s is a lightweight Kubernetes distribution that can run on a single machine. It is very easy to install and use.
|
||||
You can add custom addons to your Microk8s installation.
|
||||
Here are the steps to install EasyHAProxy on your Microk8s.
|
||||
|
||||
## Installing ByJG repository
|
||||
|
||||
Before install the addons, you need to add the ByJG repository to your Microk8s installation.
|
||||
|
||||
1. Access the microk8s host machine and run:
|
||||
|
||||
```shell
|
||||
microk8s addons repo add byjg https://github.com/byjg/microk8s-addons.git
|
||||
```
|
||||
|
||||
2. Check if it is installed:
|
||||
|
||||
```text
|
||||
$ microk8s status
|
||||
|
||||
microk8s is running
|
||||
...
|
||||
addons:
|
||||
...
|
||||
disabled:
|
||||
easyhaproxy # (byjg) EasyHAProxy can detect and configure HAProxy automatically based on ingress labels
|
||||
....
|
||||
```
|
||||
|
||||
## Installing EasyHAProxy addon
|
||||
|
||||
EasyHAProxy can detect and configure HAProxy automatically based on ingress labels.
|
||||
|
||||
Usage:
|
||||
|
||||
Install as a Daemonset
|
||||
|
||||
```shell
|
||||
microk8s enable easyhaproxy
|
||||
```
|
||||
|
||||
Install as a NodePort
|
||||
|
||||
```shell
|
||||
microk8s enable easyhaproxy --nodeport
|
||||
```
|
||||
|
||||
For more parameters you can refer to the [Kubernetes](kubernetes.md) page.
|
||||
|
||||
----
|
||||
[Open source ByJG](http://opensource.byjg.com)
|
||||
Loading…
Add table
Add a link
Reference in a new issue