Skip to content
This repository has been archived by the owner on Jan 21, 2020. It is now read-only.

Scale Group size down to 0 #717

Open
wongwill86 opened this issue Oct 9, 2017 · 1 comment
Open

Scale Group size down to 0 #717

wongwill86 opened this issue Oct 9, 2017 · 1 comment

Comments

@wongwill86
Copy link

Hello,

There are cases in which I would like a group to be scaled down to 0, i.e. for autoscaling. but right now i think https://github.com/docker/infrakit/blob/master/pkg/plugin/group/group.go#L344 is preventing me from doing that.

Group swarm-workers at 0 instancesCRIT[10-05|22:23:28] error executing                          module=main cmd=infrakit err="Allocation must not be blank" fn=main.main
Allocation must not be blank

I also tried using destroy-instances but all i get is:

infrakit group destroy-instances swarm-workers
Initiated.

but the instances are never destroyed.

obviously i can destroy the group altogether but when i want to scale back up again i would then have to recommit the groups file which isn't ideal.

It would be nice if we can scale the group down to 0.

Thanks!

@kaufers
Copy link
Contributor

kaufers commented Oct 9, 2017

Also, can we commit a group of 0 size?

The use case is that our scripts always want to commit a workers group, even if it is of size 0. We would like the group to exist so that we could statically define in in a LB configuration (ie, we want to the config to always include group/workers and group/managers in the backend nodes, even if workers has 0 members).

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants