apiVersion: v1
kind: Service
metadata:
  name: mongo-master
  labels:
    app: mongodb
    role: master
    tier: backend
spec:
  type: LoadBalancer
  ports:
    # the port that this service should serve on
  - port: 27017
  selector:
    app: mongodb
    role: master
    tier: backend