When it comes to horizontal autoscaling in Kubernetes, do yourself a favor and use KEDA!
See how you can scale your Kubernetes deployments based on custom metrics and Prometheus. Article #2 in the series about horizontal scaling in Kubernetes.
Horizontal Scaling in Kubernetes is one of the fundamental things you should do, when running applications in production. Learn about the basics in this series of articles about the scaling options in Kubernetes!