I created 5 PODs with lable as tier=frontend as below :
Then I create with a replicaset with same label and mentioned number of replicas to 3. Immediately 2 pods were terminated to maintain the number of pods to 3.
So my question is on what based the pods were seleted to maintain and to delete? Is it some random selection or is it based on any reason?
Also is there any way I can check pods those are being managed by a particular replicaset, other than matching the prefix of replicaset name?