# TODO: Try out https://eksworkshop.com/scaling/test_hpa/

apiVersion: autoscaling/v2beta2
kind: HorizontalPodAutoscaler
metadata:
  name: endpoint-node
  namespace: cloud-phoenix-kata
spec:
  maxReplicas: 10
  minReplicas: 1
  scaleTargetRef:
    apiVersion: extensions/v1beta1
    kind: Deployment
    name: endpoint-node
  metrics:
  - type: Object
    object:
      metric:
        name: requests-per-second
      describedObject:
        apiVersion: networking.k8s.io/v1beta1
        kind: Ingress
        name: main-route
      target:
        type: Value
        value: 10
