Allow container scheduling across availability zones

Registered by Ricardo Rocha

Container bays currently do not expose any information regarding the nodes availability zones (AZs).

A common use case is to have multiple instances of a container running on nodes in different zones.

Taking docker swarm as an example, the goal would be to use affinity filters based on labels to achieve this goal, something like:

docker run -it -d -p 80:80 --label nova.availability-zone=my-zone-a nginx
https://docs.docker.com/swarm/scheduler/filter/#use-an-affinity-filter

For this to be possible we need to add labels to the docker daemon configs, exposing availability zone information (taken from the nova instance metadata):
https://docs.docker.com/engine/userguide/labels-custom-metadata/#daemon-labels

There seem to be two changes required in magnum:

1. Add the availability zone label to the docker daemon configuration on the nodes

2. Get magnum (heat) to launch nodes across availability zones (from a predefined list, probably on the baymodel)

NOTE: As discussed at the team meeting, this blueprint requires a spec to start.

Blueprint information

Status:
Complete
Approver:
Spyros Trigazis
Priority:
Medium
Drafter:
Ricardo Rocha
Direction:
Approved
Assignee:
Ricardo Rocha
Definition:
Approved
Series goal:
Accepted for queens
Implementation:
Implemented
Milestone target:
milestone icon queens-3
Started by
Ricardo Rocha
Completed by
Spyros Trigazis

Related branches

Sprints

Whiteboard

---
strigazi @ Fri Feb 23 15:02:23 UTC 2018

Closing as implemented, users can create cluster with all the nodes in a *single* AZ with the label 'availability_zone'.
https://docs.openstack.org/magnum/latest/user/index.html#availability-zone
http://git.openstack.org/cgit/openstack/magnum/commit/doc/source/user/index.rst?id=53d386dc013337cbb52ac45994fb70af8d64820f

Let's create a new blueprint and probably write a spec for it.
---

http://lists.openstack.org/pipermail/openstack-dev/2016-March/088175.html
With that trick we should be able to spawn a ResourceGroup on several AZs. --mvelten

Gerrit topic: https://review.openstack.org/#q,topic:bp/magnum-availability-zones,n,z

Addressed by: https://review.openstack.org/527663
    Add label availability_zone

(?)

Work Items

This blueprint contains Public information 
Everyone can see this information.