如果服务是replicated模式(默认是replicated模式), 该属性可以用来指定在任意时间应该运行的容器副本数量。
version: "3.9" services: worker: image: dockersamples/examplevotingapp_worker networks: - frontend - backend deploy: mode: replicated replicas: 6 placement: max_replicas_per_node: 1
Last updated 3 years ago