简体   繁体   English

同步守护进程

[英]Syncing daemonset

Let's say I have a daemonset running in my k8s cluster, and each pod created by the daemonset creates and writes to a directory on the node where it's running.假设我的 k8s 集群中有一个 daemonset 正在运行,该 daemonset 创建的每个 pod 都会创建并写入运行它的节点上的一个目录。 Is there a way to automatically sync the folders with one in the masters?有没有办法自动将文件夹与主文件夹中的文件夹同步? Given I have a multi-master cluster.鉴于我有一个多主集群。

You can have a persistent volume that has ReadWriteMany access mode so that all daemonsets can share the same set of data between them.您可以拥有一个具有ReadWriteMany访问模式的持久卷,以便所有守护进程可以在它们之间共享相同的数据集。

A simple example is here: http://snippi.com/s/qpge73r一个简单的例子在这里: http : //snippi.com/s/qpge73r

Edit: as @matt commented few drivers support that as here https://kubernetes.io/docs/concepts/storage/persistent-volumes/#access-modes编辑:正如@matt 评论的,很少有驱动程序支持这里https://kubernetes.io/docs/concepts/storage/persistent-volumes/#access-modes

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM