如何与Podman Pod和容器一起使用持久卷

发布于 2025-02-06 06:52:14 字数 65 浏览 1 评论 0原文

我想在Podman Pod中运行两个容器。这两个容器都将使用相同的持续音量。运行每个容器或运行POD时,我会使用吗?

I want to run two containers in podman pod. Both of these containers will use same persistent volume. Do I use --volume when I run each container OR when I run pod.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

丑疤怪 2025-02-13 06:52:14

这取决于,您是否要为两个容器安装到同一位置的音量吗?如果是这样,您可以将其安装到Pod上,并且两者都可以将其安装在它上,否则,您可以将其分别安装在每个容器上,而无需将其安装到整个POD上。

It depends, do you want the volume mounted to the same place for both containers? If so, you can mount it to the pod and both will have it, otherwise, you can mount it to each container separately without mounting it to the entire pod.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文