Rolling Updates

Hello, I want to ask why when ‘Update’ is configured in this way, two ‘groups’ will restart together, instead of waiting for’ one ‘to recover and then starting’ two '`

I found that my configuration seems to be unable to meet the requirements. What’s the good way? Canary can’t be used at present, because one node can only run one at most

job "example" {
  ...

  update {
    max_parallel     = 1
    health_check     = "task_states"
    healthy_deadline = "10m"
  }

  group "one" {
    count = 1
    ...
 
  }

  group "two" {
    count = 1
    ...
 
  }
}

Hi @x602, the update stanza applies to each group, not in an encompassing way across groups of the job. From the update stanza documentation,

The update stanza specifies the group’s update strategy. … If specified at the job level, the configuration will apply to all groups within the job.

To make use of the update, you’ll need to structure your job to have the rolling update-able tasks belong to the same group.

Thank you for your reply, but based on various questions, I need to assign and deploy instances to different physical machines, so I can’t write them to the same ‘Group’