kind: Service
apiVersion: v1
metadata:
  name: elasticsearch-service
spec:
  selector:
    app: elasticsearch
  ports:
    - protocol: TCP
      port: 9200
      targetPort: 9200
      name: elastic-9200
    - protocol: TCP
      port: 9300
      targetPort: 9300
      name: elastic-9300
  type: ClusterIP