Merge pull request #479 from 3dwardch3ng/res/local-path-provisioner
refactor local-path-provisioner
This commit is contained in:
@@ -5,43 +5,3 @@ metadata:
|
|||||||
provisioner: rancher.io/local-path
|
provisioner: rancher.io/local-path
|
||||||
volumeBindingMode: WaitForFirstConsumer
|
volumeBindingMode: WaitForFirstConsumer
|
||||||
reclaimPolicy: Retain
|
reclaimPolicy: Retain
|
||||||
---
|
|
||||||
kind: ConfigMap
|
|
||||||
apiVersion: v1
|
|
||||||
metadata:
|
|
||||||
name: local-path-config
|
|
||||||
namespace: local-path-storage
|
|
||||||
data:
|
|
||||||
config.json: |-
|
|
||||||
{
|
|
||||||
"nodePathMap": [
|
|
||||||
{
|
|
||||||
"node": "DEFAULT_PATH_FOR_NON_LISTED_NODES",
|
|
||||||
"paths": [
|
|
||||||
"/opt/local-path-provisioner"]
|
|
||||||
}
|
|
||||||
]
|
|
||||||
}
|
|
||||||
setup: |-
|
|
||||||
#!/bin/sh
|
|
||||||
set -eu
|
|
||||||
mkdir -m 0777 -p "$VOL_DIR"
|
|
||||||
teardown: |-
|
|
||||||
#!/bin/sh
|
|
||||||
set -eu
|
|
||||||
rm -rf "$VOL_DIR"
|
|
||||||
helperPod.yaml: |-
|
|
||||||
apiVersion: v1
|
|
||||||
kind: Pod
|
|
||||||
metadata:
|
|
||||||
name: helper-pod
|
|
||||||
spec:
|
|
||||||
priorityClassName: system-node-critical
|
|
||||||
tolerations:
|
|
||||||
- key: node.kubernetes.io/disk-pressure
|
|
||||||
operator: Exists
|
|
||||||
effect: NoSchedule
|
|
||||||
containers:
|
|
||||||
- name: helper-pod
|
|
||||||
image: busybox
|
|
||||||
imagePullPolicy: IfNotPresent
|
|
||||||
Reference in New Issue
Block a user