【问题标题】:How to run pod with existing statefulset in kubernetes cluster?如何在 Kubernetes 集群中使用现有的 statefulset 运行 pod?
【发布时间】:2019-04-11 15:40:18
【问题描述】:

我使用这个命令来启动我的 statefulset:

kubectl scale statefulset my-set --replicas=1

但是 pod 没有运行。

如何使用现有的状态集“my-set”启动 pod?

【问题讨论】:

  • 这个命令给你什么信息?
  • 抱歉没有执行正确的补丁。

标签: kubernetes scale kubernetes-statefulset


【解决方案1】:

您可以通过不同方式扩展有状态集:

kubectl scale --replicas=1 statefulset/my-set

kubectl scale sts my-set --replicas=1

kubectl patch sts my-set -p '{"spec":{"replicas":1}}'

【讨论】:

    猜你喜欢
    • 1970-01-01
    • 2021-09-08
    • 2023-01-10
    • 1970-01-01
    • 2023-04-04
    • 2022-07-22
    • 2021-07-22
    • 2021-09-26
    • 2021-12-25
    相关资源
    最近更新 更多