mirror of
https://github.com/bjw-s-labs/helm-charts.git
synced 2025-07-04 00:47:04 +02:00
feat(common): Release 2.0.0 (#189)
This commit is contained in:
parent
8a42d212af
commit
98677d85b2
56 changed files with 1192 additions and 1804 deletions
88
docs/common-library/storage/globalOptions.md
Normal file
88
docs/common-library/storage/globalOptions.md
Normal file
|
@ -0,0 +1,88 @@
|
|||
# Global Options
|
||||
|
||||
The following options are available for all persistence types:
|
||||
|
||||
## enabled
|
||||
|
||||
Enables or disables the persistence item. Defaults to `true`.
|
||||
|
||||
## type
|
||||
|
||||
Sets the persistence type
|
||||
|
||||
Valid options are:
|
||||
|
||||
- [`configMap`](types/configmap.md)
|
||||
- [`custom`](types/custom.md)
|
||||
- [`emptyDir`](types/emptyDir.md)
|
||||
- [`hostPath`](types/hostPath.md)
|
||||
- [`nfs`](types/nfs-share.md)
|
||||
- [`persistentVolumeClaim`](types/persistentVolumeClaim.md)
|
||||
- [`secret`](types/secret.md)
|
||||
|
||||
## globalMounts
|
||||
|
||||
Configure mounts to all controllers and containers. By default the persistence item
|
||||
will be mounted to `/<name_of_the_peristence_item>`.
|
||||
|
||||
**Example**
|
||||
|
||||
```yaml
|
||||
globalMounts:
|
||||
- path: /config
|
||||
readOnly: false
|
||||
```
|
||||
|
||||
### path
|
||||
|
||||
Where to mount the volume in the main container. Defaults to `/<name_of_the_volume>`
|
||||
|
||||
### readOnly
|
||||
|
||||
Specify if the volume should be mounted read-only
|
||||
|
||||
### subPath
|
||||
|
||||
Specifies a sub-path inside the referenced volume instead of its root.
|
||||
|
||||
## advancedMounts
|
||||
|
||||
Explicitly configure mounts for specific controllers and containers.
|
||||
|
||||
**Example**
|
||||
|
||||
```yaml
|
||||
advancedMounts:
|
||||
main: # (1)
|
||||
main: # (2)
|
||||
- path: /data/config.yaml
|
||||
readOnly: true
|
||||
subPath: config.yaml
|
||||
second-container: # (3)
|
||||
- path: /appdata/config
|
||||
readOnly: true
|
||||
|
||||
second-controller: # (4)
|
||||
main: # (5)
|
||||
- path: /data/config.yaml
|
||||
readOnly: false
|
||||
subPath: config.yaml
|
||||
```
|
||||
|
||||
1. the controller with the "main" identifier
|
||||
2. the container with the "main" identifier
|
||||
3. the container with the "second-container" identifier
|
||||
4. the controller with the "second-controller" identifier
|
||||
5. the container with the "main" identifier
|
||||
|
||||
### path
|
||||
|
||||
Where to mount the volume in the main container. Defaults to `/<name_of_the_volume>`
|
||||
|
||||
### readOnly
|
||||
|
||||
Specify if the volume should be mounted read-only
|
||||
|
||||
### subPath
|
||||
|
||||
Specifies a sub-path inside the referenced volume instead of its root.
|
6
docs/common-library/storage/permissions.md
Normal file
6
docs/common-library/storage/permissions.md
Normal file
|
@ -0,0 +1,6 @@
|
|||
# Permissions
|
||||
|
||||
Charts do not modify file or folder permissions on volumes out of the box.
|
||||
|
||||
This means that you will have to make sure that your storage can be written to
|
||||
by the application.
|
31
docs/common-library/storage/types/configmap.md
Normal file
31
docs/common-library/storage/types/configmap.md
Normal file
|
@ -0,0 +1,31 @@
|
|||
---
|
||||
hide:
|
||||
- toc
|
||||
---
|
||||
|
||||
# ConfigMap
|
||||
|
||||
In order to mount a configMap to a mount point within the Pod you can use the
|
||||
`configMap` type persistence item.
|
||||
|
||||
| Field | Mandatory | Docs / Description |
|
||||
| ------------- | --------- | -------------------------------------------------------------------------- |
|
||||
| `name` | Yes | Which configMap should be mounted. Supports Helm templating. |
|
||||
| `defaultMode` | No | The default file access permission bit. |
|
||||
| `items` | No | Specify item-specific configuration. Will be passed 1:1 to the volumeSpec. |
|
||||
|
||||
!!! note
|
||||
|
||||
Even if not specified, the configMap will be read-only.
|
||||
|
||||
## Minimal configuration
|
||||
|
||||
```yaml
|
||||
persistence:
|
||||
config:
|
||||
enabled: true
|
||||
type: configMap
|
||||
name: mySettings
|
||||
```
|
||||
|
||||
This will mount the contents of the pre-existing `mySettings` configMap to `/config`.
|
34
docs/common-library/storage/types/custom.md
Normal file
34
docs/common-library/storage/types/custom.md
Normal file
|
@ -0,0 +1,34 @@
|
|||
---
|
||||
hide:
|
||||
- toc
|
||||
---
|
||||
|
||||
# Custom
|
||||
|
||||
When you wish to specify a custom volume, you can use the `custom` type.
|
||||
This can be used for example to mount configMap or Secret objects.
|
||||
|
||||
See the [Kubernetes docs](https://kubernetes.io/docs/concepts/storage/volumes/)
|
||||
for more information.
|
||||
|
||||
| Field | Mandatory | Docs / Description |
|
||||
| ------------ | --------- | -------------------------------- |
|
||||
| `volumeSpec` | Yes | Define the raw Volume spec here. |
|
||||
|
||||
## Minimal configuration
|
||||
|
||||
```yaml
|
||||
persistence:
|
||||
config:
|
||||
enabled: true
|
||||
type: custom
|
||||
volumeSpec:
|
||||
downwardAPI:
|
||||
items:
|
||||
- path: "labels"
|
||||
fieldRef:
|
||||
fieldPath: metadata.labels
|
||||
- path: "annotations"
|
||||
fieldRef:
|
||||
fieldPath: metadata.annotations
|
||||
```
|
28
docs/common-library/storage/types/emptyDir.md
Normal file
28
docs/common-library/storage/types/emptyDir.md
Normal file
|
@ -0,0 +1,28 @@
|
|||
---
|
||||
hide:
|
||||
- toc
|
||||
---
|
||||
|
||||
# Empty Dir
|
||||
|
||||
Sometimes you need to share some data between containers, or need some
|
||||
scratch space. That is where an emptyDir can come in.
|
||||
|
||||
See the [Kubernetes docs](https://kubernetes.io/docs/concepts/storage/volumes/#emptydir)
|
||||
for more information.
|
||||
|
||||
| Field | Mandatory | Docs / Description |
|
||||
| ----------- | --------- | ---------------------------------------------------------------------------------------------------------------- |
|
||||
| `medium` | No | Set this to `Memory` to mount a tmpfs (RAM-backed filesystem) instead of the storage medium that backs the node. |
|
||||
| `sizeLimit` | No | If the `SizeMemoryBackedVolumes` feature gate is enabled, you can specify a size for memory backed volumes. |
|
||||
|
||||
## Minimal configuration
|
||||
|
||||
```yaml
|
||||
persistence:
|
||||
config:
|
||||
enabled: true
|
||||
type: emptyDir
|
||||
```
|
||||
|
||||
This will create an ephemeral emptyDir volume and mount it to `/config`.
|
32
docs/common-library/storage/types/hostPath.md
Normal file
32
docs/common-library/storage/types/hostPath.md
Normal file
|
@ -0,0 +1,32 @@
|
|||
---
|
||||
hide:
|
||||
- toc
|
||||
---
|
||||
|
||||
# Host path
|
||||
|
||||
In order to mount a path from the node where the Pod is running you can use a
|
||||
`hostPath` type persistence item.
|
||||
|
||||
This can also be used to mount an attached USB device to a Pod. Note that
|
||||
this will most likely also require setting an elevated `securityContext`.
|
||||
|
||||
See the [Kubernetes docs](https://kubernetes.io/docs/concepts/storage/volumes/#hostpath)
|
||||
for more information.
|
||||
|
||||
| Field | Mandatory | Docs / Description |
|
||||
| -------------- | --------- | ----------------------------------------------------------------------------------------------------------------- |
|
||||
| `hostPath` | Yes | Which path on the host should be mounted. |
|
||||
| `hostPathType` | No | Specifying a hostPathType adds a check before trying to mount the path. See Kubernetes documentation for options. |
|
||||
|
||||
## Minimal configuration
|
||||
|
||||
```yaml
|
||||
persistence:
|
||||
config:
|
||||
enabled: true
|
||||
type: hostPath
|
||||
hostPath: /dev
|
||||
```
|
||||
|
||||
This will mount the `/dev` folder from the underlying host to `/dev` in the container.
|
32
docs/common-library/storage/types/nfs-share.md
Normal file
32
docs/common-library/storage/types/nfs-share.md
Normal file
|
@ -0,0 +1,32 @@
|
|||
---
|
||||
hide:
|
||||
- toc
|
||||
---
|
||||
|
||||
# NFS Share
|
||||
|
||||
To mount an NFS share to your Pod you can either pre-create a persistentVolumeClaim
|
||||
referring to it, or you can specify an inline NFS volume:
|
||||
|
||||
!!! note
|
||||
|
||||
Mounting an NFS share this way does not allow for specifying mount options.
|
||||
If you require these, you must create a PVC to mount the share.
|
||||
|
||||
| Field | Mandatory | Docs / Description |
|
||||
| -------- | --------- | ------------------------------------------ |
|
||||
| `server` | Yes | Host name or IP address of the NFS server. |
|
||||
| `path` | Yes | The path on the server to mount. |
|
||||
|
||||
## Minimal configuration
|
||||
|
||||
```yaml
|
||||
persistence:
|
||||
config:
|
||||
enabled: true
|
||||
type: nfs
|
||||
server: 10.10.0.8
|
||||
path: /tank/nas/library
|
||||
```
|
||||
|
||||
This will mount the NFS share `/tank/nas/library` on server `10.10.0.8` to `/config`.
|
57
docs/common-library/storage/types/persistentVolumeClaim.md
Normal file
57
docs/common-library/storage/types/persistentVolumeClaim.md
Normal file
|
@ -0,0 +1,57 @@
|
|||
# Persistent Volume Claim
|
||||
|
||||
This is probably the most common storage type, therefore it is also the
|
||||
default when no `type` is specified.
|
||||
|
||||
It can be attached in two ways.
|
||||
|
||||
- [Dynamically provisioned](#dynamically-provisioned)
|
||||
- [Existing claim](#existing-claim)
|
||||
|
||||
## Dynamically provisioned
|
||||
|
||||
Charts can be configured to create the required persistentVolumeClaim
|
||||
manifests on the fly.
|
||||
|
||||
| Field | Mandatory | Docs / Description |
|
||||
| -------------- | --------- | ------------------------------------------------------------------------------------ |
|
||||
| `accessMode` | Yes | [link](https://kubernetes.io/docs/concepts/storage/persistent-volumes/#access-modes) |
|
||||
| `size` | Yes | [link](https://kubernetes.io/docs/concepts/storage/persistent-volumes/#resources) |
|
||||
| `nameOverride` | No | Override the name suffix that is used for this volume. |
|
||||
| `storageClass` | No | Storage class to use for this volume. |
|
||||
| `retain` | No | Set to true to retain the PVC upon `helm uninstall`. |
|
||||
|
||||
### Minimal configuration
|
||||
|
||||
```yaml
|
||||
persistence:
|
||||
config:
|
||||
enabled: true
|
||||
type: persistentVolumeClaim
|
||||
accessMode: ReadWriteOnce
|
||||
size: 1Gi
|
||||
```
|
||||
|
||||
This will create a 1Gi RWO PVC named `RELEASE-NAME-config` with the default
|
||||
storageClass, which will mount to `/config`.
|
||||
|
||||
## Existing claim
|
||||
|
||||
Charts can be configured to attach to a pre-existing persistentVolumeClaim.
|
||||
|
||||
| Field | Mandatory | Docs / Description |
|
||||
| --------------- | --------- | ------------------------------------------------------ |
|
||||
| `existingClaim` | Yes | Name of the existing PVC |
|
||||
| `nameOverride` | No | Override the name suffix that is used for this volume. |
|
||||
|
||||
### Minimal configuration
|
||||
|
||||
```yaml
|
||||
persistence:
|
||||
config:
|
||||
enabled: true
|
||||
type: persistentVolumeClaim
|
||||
existingClaim: myAppData
|
||||
```
|
||||
|
||||
This will mount an existing PVC named `myAppData` to `/config`.
|
31
docs/common-library/storage/types/secret.md
Normal file
31
docs/common-library/storage/types/secret.md
Normal file
|
@ -0,0 +1,31 @@
|
|||
---
|
||||
hide:
|
||||
- toc
|
||||
---
|
||||
|
||||
# Secret
|
||||
|
||||
In order to mount a Secret to a mount point within the Pod you can use the
|
||||
`secret` type persistence item.
|
||||
|
||||
| Field | Mandatory | Docs / Description |
|
||||
| ------------- | --------- | -------------------------------------------------------------------------- |
|
||||
| `name` | Yes | Which Secret should be mounted. Supports Helm templating. |
|
||||
| `defaultMode` | No | The default file access permission bit. |
|
||||
| `items` | No | Specify item-specific configuration. Will be passed 1:1 to the volumeSpec. |
|
||||
|
||||
!!! note
|
||||
|
||||
Even if not specified, the Secret will be read-only.
|
||||
|
||||
## Minimal configuration
|
||||
|
||||
```yaml
|
||||
persistence:
|
||||
config:
|
||||
enabled: true
|
||||
type: secret
|
||||
name: mySecret
|
||||
```
|
||||
|
||||
This will mount the contents of the pre-existing `mySecret` Secret to `/config`.
|
Loading…
Add table
Add a link
Reference in a new issue