Docker Community Forums

Share and learn in the Docker community.

Swarm API - how to specify image affinity?


(Hstang9876) #1

Hi,

I’ve been looking for documentation on how to construct a REST call to Swarm so we can specifiy image affinity. Does any know how?

The docs mention using docker CLI via -e affinity:image=…, but how does this look in the payload body of a create container call?