Persistent volumes

This commit is contained in:
Dominik Chilla 2020-09-22 16:50:45 +02:00
parent 016ad28512
commit 4ddd03b075

View File

@ -15,6 +15,9 @@
* [devel](#namespace-devel) * [devel](#namespace-devel)
* [staging](#namespace-staging) * [staging](#namespace-staging)
* [prod](#namespace-prod) * [prod](#namespace-prod)
* [Persistent volumes](#pv)
* [Local provider](#pv-local)
* [Longhorn - distributed/lightweight provider](#pv-longhorn)
* [HELM charts](#helm) * [HELM charts](#helm)
* [Create a chart](#helm-create) * [Create a chart](#helm-create)
* [Install local chart without packaging](#helm-install-without-packaging) * [Install local chart without packaging](#helm-install-without-packaging)
@ -342,10 +345,16 @@ namespace-devel-limitranges.yaml:
apiVersion: v1 apiVersion: v1
kind: LimitRange kind: LimitRange
metadata: metadata:
name: limit-range-staging name: limit-range-devel
spec: spec:
limits: limits:
- max: - default:
cpu: 500m
memory: 1Gi
defaultRequest:
cpu: 10m
memory: 4Mi
max:
cpu: 500m cpu: 500m
memory: 1Gi memory: 1Gi
min: min:
@ -376,7 +385,13 @@ metadata:
name: limit-range-staging name: limit-range-staging
spec: spec:
limits: limits:
- max: - default:
cpu: 500m
memory: 1Gi
defaultRequest:
cpu: 10m
memory: 4Mi
max:
cpu: 500m cpu: 500m
memory: 1Gi memory: 1Gi
min: min:
@ -407,13 +422,25 @@ metadata:
name: limit-range-prod name: limit-range-prod
spec: spec:
limits: limits:
- min: - defaultRequest:
cpu: 10m cpu: 50m
memory: 4Mi
min:
cpu: 50m
memory: 4Mi memory: 4Mi
type: Container type: Container
``` ```
`kubectl apply -f namespace-prod-limitranges.yaml -n prod` `kubectl apply -f namespace-prod-limitranges.yaml -n prod`
# Persistent Volumes <a name="pv"></a>
## Local provider (local - ouf-of-the-box) <a name="pv-local"></a>
https://rancher.com/docs/k3s/latest/en/storage/
## Longhorn (lightweight/distributed) <a name="pv-longhorn"></a>
* Requirements: https://longhorn.io/docs/0.8.0/install/requirements/
* Install: https://rancher.com/docs/k3s/latest/en/storage/
# HELM charts <a name="helm"></a> # HELM charts <a name="helm"></a>
Docs: Docs:
* https://helm.sh/docs/intro/using_helm/ * https://helm.sh/docs/intro/using_helm/