2019-02-07 09:59:26 +00:00
|
|
|
---
|
2018-01-09 18:59:50 +00:00
|
|
|
kind: DaemonSet
|
2019-06-19 09:05:44 +00:00
|
|
|
apiVersion: apps/v1
|
2018-01-09 18:59:50 +00:00
|
|
|
metadata:
|
2018-03-18 14:08:39 +00:00
|
|
|
name: csi-cephfsplugin
|
2018-01-09 18:59:50 +00:00
|
|
|
spec:
|
|
|
|
selector:
|
|
|
|
matchLabels:
|
2018-03-18 14:08:39 +00:00
|
|
|
app: csi-cephfsplugin
|
2018-01-09 18:59:50 +00:00
|
|
|
template:
|
|
|
|
metadata:
|
|
|
|
labels:
|
2018-03-18 14:08:39 +00:00
|
|
|
app: csi-cephfsplugin
|
2018-01-09 18:59:50 +00:00
|
|
|
spec:
|
2021-04-05 11:43:45 +00:00
|
|
|
serviceAccountName: cephfs-csi-nodeplugin
|
2020-05-05 08:27:38 +00:00
|
|
|
priorityClassName: system-node-critical
|
2018-01-09 18:59:50 +00:00
|
|
|
hostNetwork: true
|
2022-03-31 13:29:33 +00:00
|
|
|
hostPID: true
|
2018-09-19 14:37:58 +00:00
|
|
|
# to use e.g. Rook orchestrated cluster, and mons' FQDN is
|
|
|
|
# resolved through k8s service, set dns policy to cluster first
|
2019-02-07 09:59:26 +00:00
|
|
|
dnsPolicy: ClusterFirstWithHostNet
|
2018-01-09 18:59:50 +00:00
|
|
|
containers:
|
|
|
|
- name: driver-registrar
|
2020-01-13 04:14:18 +00:00
|
|
|
# This is necessary only for systems with SELinux, where
|
|
|
|
# non-privileged sidecar containers cannot access unix domain socket
|
|
|
|
# created by privileged CSI driver container.
|
|
|
|
securityContext:
|
|
|
|
privileged: true
|
2022-04-12 05:45:44 +00:00
|
|
|
allowPrivilegeEscalation: true
|
2023-11-20 06:01:09 +00:00
|
|
|
image: registry.k8s.io/sig-storage/csi-node-driver-registrar:v2.9.1
|
2018-01-09 18:59:50 +00:00
|
|
|
args:
|
2022-07-26 04:52:19 +00:00
|
|
|
- "--v=1"
|
2019-01-22 16:31:55 +00:00
|
|
|
- "--csi-address=/csi/csi.sock"
|
2019-03-13 05:09:58 +00:00
|
|
|
- "--kubelet-registration-path=/var/lib/kubelet/plugins/cephfs.csi.ceph.com/csi.sock"
|
2018-01-09 18:59:50 +00:00
|
|
|
env:
|
|
|
|
- name: KUBE_NODE_NAME
|
|
|
|
valueFrom:
|
|
|
|
fieldRef:
|
|
|
|
fieldPath: spec.nodeName
|
|
|
|
volumeMounts:
|
2019-07-03 10:02:36 +00:00
|
|
|
- name: socket-dir
|
2019-01-22 16:31:55 +00:00
|
|
|
mountPath: /csi
|
2018-09-10 19:16:17 +00:00
|
|
|
- name: registration-dir
|
|
|
|
mountPath: /registration
|
2018-03-18 14:08:39 +00:00
|
|
|
- name: csi-cephfsplugin
|
2018-01-09 18:59:50 +00:00
|
|
|
securityContext:
|
|
|
|
privileged: true
|
|
|
|
capabilities:
|
|
|
|
add: ["SYS_ADMIN"]
|
|
|
|
allowPrivilegeEscalation: true
|
2019-05-24 11:03:33 +00:00
|
|
|
# for stable functionality replace canary with latest release version
|
|
|
|
image: quay.io/cephcsi/cephcsi:canary
|
2019-02-07 09:59:26 +00:00
|
|
|
args:
|
2018-01-09 18:59:50 +00:00
|
|
|
- "--nodeid=$(NODE_ID)"
|
2019-05-24 11:03:33 +00:00
|
|
|
- "--type=cephfs"
|
2019-08-14 06:42:17 +00:00
|
|
|
- "--nodeserver=true"
|
2018-01-09 18:59:50 +00:00
|
|
|
- "--endpoint=$(CSI_ENDPOINT)"
|
|
|
|
- "--v=5"
|
2019-03-13 05:09:58 +00:00
|
|
|
- "--drivername=cephfs.csi.ceph.com"
|
2021-03-25 11:14:46 +00:00
|
|
|
- "--enableprofiling=false"
|
2020-01-24 16:26:56 +00:00
|
|
|
# If topology based provisioning is desired, configure required
|
|
|
|
# node labels representing the nodes topology domain
|
2020-11-24 11:54:29 +00:00
|
|
|
# and pass the label names below, for CSI to consume and advertise
|
2020-01-24 16:26:56 +00:00
|
|
|
# its equivalent topology domain
|
|
|
|
# - "--domainlabels=failure-domain/region,failure-domain/zone"
|
2018-01-09 18:59:50 +00:00
|
|
|
env:
|
2019-08-21 09:28:02 +00:00
|
|
|
- name: POD_IP
|
|
|
|
valueFrom:
|
|
|
|
fieldRef:
|
|
|
|
fieldPath: status.podIP
|
2018-01-09 18:59:50 +00:00
|
|
|
- name: NODE_ID
|
|
|
|
valueFrom:
|
|
|
|
fieldRef:
|
|
|
|
fieldPath: spec.nodeName
|
|
|
|
- name: CSI_ENDPOINT
|
2019-03-18 06:50:06 +00:00
|
|
|
value: unix:///csi/csi.sock
|
2022-08-19 13:25:13 +00:00
|
|
|
- name: POD_NAMESPACE
|
|
|
|
valueFrom:
|
|
|
|
fieldRef:
|
|
|
|
fieldPath: metadata.namespace
|
|
|
|
# - name: KMS_CONFIGMAP_NAME
|
|
|
|
# value: encryptionConfig
|
2018-01-09 18:59:50 +00:00
|
|
|
imagePullPolicy: "IfNotPresent"
|
|
|
|
volumeMounts:
|
2019-07-03 10:02:36 +00:00
|
|
|
- name: socket-dir
|
2019-03-18 06:50:06 +00:00
|
|
|
mountPath: /csi
|
2019-07-03 10:02:36 +00:00
|
|
|
- name: mountpoint-dir
|
2018-01-09 18:59:50 +00:00
|
|
|
mountPath: /var/lib/kubelet/pods
|
2019-07-03 10:02:36 +00:00
|
|
|
mountPropagation: Bidirectional
|
|
|
|
- name: plugin-dir
|
|
|
|
mountPath: /var/lib/kubelet/plugins
|
2018-01-09 18:59:50 +00:00
|
|
|
mountPropagation: "Bidirectional"
|
2018-12-14 20:06:42 +00:00
|
|
|
- name: host-sys
|
|
|
|
mountPath: /sys
|
2021-08-02 14:57:11 +00:00
|
|
|
- name: etc-selinux
|
|
|
|
mountPath: /etc/selinux
|
|
|
|
readOnly: true
|
2018-03-22 15:51:39 +00:00
|
|
|
- name: lib-modules
|
|
|
|
mountPath: /lib/modules
|
2018-01-09 18:59:50 +00:00
|
|
|
readOnly: true
|
2018-03-22 15:51:39 +00:00
|
|
|
- name: host-dev
|
|
|
|
mountPath: /dev
|
2020-01-23 08:29:53 +00:00
|
|
|
- name: host-mount
|
|
|
|
mountPath: /run/mount
|
2021-08-26 05:28:02 +00:00
|
|
|
- name: ceph-config
|
|
|
|
mountPath: /etc/ceph/
|
2019-05-28 19:03:18 +00:00
|
|
|
- name: ceph-csi-config
|
|
|
|
mountPath: /etc/ceph-csi-config/
|
2019-06-25 19:29:17 +00:00
|
|
|
- name: keys-tmp-dir
|
|
|
|
mountPath: /tmp/csi/keys
|
2022-02-02 12:23:06 +00:00
|
|
|
- name: ceph-csi-mountinfo
|
|
|
|
mountPath: /csi/mountinfo
|
2022-08-19 13:25:13 +00:00
|
|
|
- name: ceph-csi-encryption-kms-config
|
|
|
|
mountPath: /etc/ceph-csi-encryption-kms-config/
|
2019-06-20 19:30:40 +00:00
|
|
|
- name: liveness-prometheus
|
2020-01-13 04:14:18 +00:00
|
|
|
securityContext:
|
|
|
|
privileged: true
|
2022-04-12 05:45:44 +00:00
|
|
|
allowPrivilegeEscalation: true
|
2019-06-20 19:30:40 +00:00
|
|
|
image: quay.io/cephcsi/cephcsi:canary
|
|
|
|
args:
|
|
|
|
- "--type=liveness"
|
|
|
|
- "--endpoint=$(CSI_ENDPOINT)"
|
2019-08-27 18:55:15 +00:00
|
|
|
- "--metricsport=8681"
|
2019-08-21 09:28:02 +00:00
|
|
|
- "--metricspath=/metrics"
|
2019-06-20 19:30:40 +00:00
|
|
|
- "--polltime=60s"
|
|
|
|
- "--timeout=3s"
|
|
|
|
env:
|
|
|
|
- name: CSI_ENDPOINT
|
|
|
|
value: unix:///csi/csi.sock
|
|
|
|
- name: POD_IP
|
|
|
|
valueFrom:
|
|
|
|
fieldRef:
|
|
|
|
fieldPath: status.podIP
|
|
|
|
volumeMounts:
|
|
|
|
- name: socket-dir
|
|
|
|
mountPath: /csi
|
|
|
|
imagePullPolicy: "IfNotPresent"
|
2018-01-09 18:59:50 +00:00
|
|
|
volumes:
|
2019-07-03 10:02:36 +00:00
|
|
|
- name: socket-dir
|
2018-01-09 18:59:50 +00:00
|
|
|
hostPath:
|
2019-03-13 05:09:58 +00:00
|
|
|
path: /var/lib/kubelet/plugins/cephfs.csi.ceph.com/
|
2018-01-09 18:59:50 +00:00
|
|
|
type: DirectoryOrCreate
|
2018-09-10 19:16:17 +00:00
|
|
|
- name: registration-dir
|
|
|
|
hostPath:
|
2018-12-04 20:08:11 +00:00
|
|
|
path: /var/lib/kubelet/plugins_registry/
|
2018-09-10 19:16:17 +00:00
|
|
|
type: Directory
|
2019-07-03 10:02:36 +00:00
|
|
|
- name: mountpoint-dir
|
2018-01-09 18:59:50 +00:00
|
|
|
hostPath:
|
|
|
|
path: /var/lib/kubelet/pods
|
2019-07-03 10:02:36 +00:00
|
|
|
type: DirectoryOrCreate
|
|
|
|
- name: plugin-dir
|
|
|
|
hostPath:
|
|
|
|
path: /var/lib/kubelet/plugins
|
2018-01-09 18:59:50 +00:00
|
|
|
type: Directory
|
|
|
|
- name: host-sys
|
|
|
|
hostPath:
|
|
|
|
path: /sys
|
2021-08-02 14:57:11 +00:00
|
|
|
- name: etc-selinux
|
|
|
|
hostPath:
|
|
|
|
path: /etc/selinux
|
2018-01-09 18:59:50 +00:00
|
|
|
- name: lib-modules
|
|
|
|
hostPath:
|
|
|
|
path: /lib/modules
|
2018-03-22 15:51:39 +00:00
|
|
|
- name: host-dev
|
|
|
|
hostPath:
|
|
|
|
path: /dev
|
2020-01-23 08:29:53 +00:00
|
|
|
- name: host-mount
|
|
|
|
hostPath:
|
|
|
|
path: /run/mount
|
2021-08-26 05:28:02 +00:00
|
|
|
- name: ceph-config
|
|
|
|
configMap:
|
|
|
|
name: ceph-config
|
2019-05-28 19:03:18 +00:00
|
|
|
- name: ceph-csi-config
|
|
|
|
configMap:
|
|
|
|
name: ceph-csi-config
|
2019-06-25 19:29:17 +00:00
|
|
|
- name: keys-tmp-dir
|
|
|
|
emptyDir: {
|
|
|
|
medium: "Memory"
|
|
|
|
}
|
2022-02-02 12:23:06 +00:00
|
|
|
- name: ceph-csi-mountinfo
|
|
|
|
hostPath:
|
|
|
|
path: /var/lib/kubelet/plugins/cephfs.csi.ceph.com/mountinfo
|
|
|
|
type: DirectoryOrCreate
|
2022-08-19 13:25:13 +00:00
|
|
|
- name: ceph-csi-encryption-kms-config
|
|
|
|
configMap:
|
|
|
|
name: ceph-csi-encryption-kms-config
|
2019-06-20 19:30:40 +00:00
|
|
|
---
|
2020-03-31 05:59:29 +00:00
|
|
|
# This is a service to expose the liveness metrics
|
2019-06-20 19:30:40 +00:00
|
|
|
apiVersion: v1
|
|
|
|
kind: Service
|
|
|
|
metadata:
|
2019-08-21 09:28:02 +00:00
|
|
|
name: csi-metrics-cephfsplugin
|
2019-06-20 19:30:40 +00:00
|
|
|
labels:
|
2019-08-21 09:28:02 +00:00
|
|
|
app: csi-metrics
|
2019-06-20 19:30:40 +00:00
|
|
|
spec:
|
|
|
|
ports:
|
|
|
|
- name: http-metrics
|
|
|
|
port: 8080
|
|
|
|
protocol: TCP
|
2019-08-27 18:55:15 +00:00
|
|
|
targetPort: 8681
|
2019-06-20 19:30:40 +00:00
|
|
|
selector:
|
|
|
|
app: csi-cephfsplugin
|