apiVersion: v1
kind: Service
metadata:
  name: postgres
  labels:
    app: postgres
spec:
  externalName: postgres
  type: NodePort
  ports:
    - name: postgres
      port: 5432
      nodePort: 30000
  selector:
    app: postgres