# Satefulsets replica scheduling question

**URL:** <https://discuss.kubernetes.io/t/satefulsets-replica-scheduling-question/10801>\
**Category:** General Discussions\
**Created:** [May 6, 2020, 6:58pm UTC](https://discuss.kubernetes.io/t/satefulsets-replica-scheduling-question/10801 "2020-05-06T18:58:59Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![kennthhz](https://sea2.discourse-cdn.com/flex016/user_avatar/discuss.kubernetes.io/kennthhz/32/4618_2.png) [@kennthhz](https://discuss.kubernetes.io/u/kennthhz)\
**Post date:** [May 6, 2020, 6:58pm UTC](https://discuss.kubernetes.io/t/satefulsets-replica-scheduling-question/10801/1 "2020-05-06T18:58:59Z")

</div>

Is there anyway I can tell Kuberbetes how to schedule the replicas in the statefulset? For example, I have nodes divided into 3 different availability zones (AZ). I have labeled these nodes accordingly. Now I want K8s to put 1 replica in each AZ based on node label. Thanks

---

<div class="post-metadata">

**Author:** ![mrbobbytables](https://sea2.discourse-cdn.com/flex016/user_avatar/discuss.kubernetes.io/mrbobbytables/32/7_2.png) [@mrbobbytables](https://discuss.kubernetes.io/u/mrbobbytables)\
**Post date:** [May 7, 2020, 12:54am UTC](https://discuss.kubernetes.io/t/satefulsets-replica-scheduling-question/10801/2 "2020-05-07T00:54:14Z")

</div>

Take a look at the docs on affinity and anti-affinity: [Assigning Pods to Nodes - Kubernetes](https://kubernetes.io/docs/concepts/configuration/assign-pod-node/) I think it’ll cover what your trying to do 🙂
