apiVersion: v1
kind: Service
metadata:
  name: test-api
  namespace: demo-k8s
spec:
  type: ClusterIP
  ports:
  - port: 80
    targetPort: http
    name: http
  selector:
    app.kubernetes.io/name: test
    app.kubernetes.io/component: api
