You can use labels and selectors for this purpose.
First add labels to the nodes:
kubectl local nodes node-a podwants=feature1-nodea
kubectl local nodes node-b podwants=feature1-nodeb
A nodeSelector can then be set in the Pod definitions spec.
apiVersion: v1
kind: Pod
metadata:
name: nginx
labels:
app: my-app
spec:
nodeSelector:
podwants: feature1-nodea
container:
- name: nginx
image: nginx:1.8
ports:
- containerPort: 80
And a define a service in the following manner:
kind: Service
apiVersion: v1
metadata:
name: web-svc
spec:
selector:
app: my-app
ports:
- protocol: TCP
port: 80
targetPort: 80
Add CoreDNS to your cluster to discover the available Services in other Pods.
WEB_SVC_SERVICE_HOST=x.x.x.x
WEB_SVC_SERVICE_PORT=80