You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The scale command begins to count at whatever value the last running container has at com.docker.compose.container-number when starting new containers.
Imagine the following: foo is scaled to 2, but foo_1 is stopped and removed. When scaling up, compose starts to create and run foo_3 instead of foo_1.
This is by design. There shouldn't be any documentation that says numbers should always start at 1. These numbers are really just to give the container a unique name.
We'd actually like to remove the sequential numbers (#1516), so I don't think we're going to be doing any work to have the numbers "fill in the gaps". This would make Compose even more prone to race conditions and would be additional API calls with no real benefit.
The
scale
command begins to count at whatever value the last running container has atcom.docker.compose.container-number
when starting new containers.Imagine the following:
foo
is scaled to 2, butfoo_1
is stopped and removed. When scaling up, compose starts to create and runfoo_3
instead offoo_1
.To reproduce:
The text was updated successfully, but these errors were encountered: