Next.js Discord

Discord Forum

Setting limits for a Next.js application within a Kubernetes cluster

Unanswered
Elm sawfly posted this in #help-forum
Open in Discord
Elm sawflyOP
Hello, we are currently addressing the operation of a Next.js application within a Kubernetes cluster. For a specific pod, we need to set suitable limits for both memory and CPU. In the official documentation, I haven't found any "advice," "tips," or "recommendations" regarding the dimensions to maintain these limits. Let's say we already have a few migrated PHP Symfony apps (I know) where the limits are quite at the lower edge, around 256MB. Does anyone have experience with environment configuration within Kubernetes?

1 Reply

i host on GCP k8s. minimum resource would be okay as it should be I/O bound app.
or off-load CPU intensive logics to Go, Rust and so on.
just watch there is no memory leak in case of self-hosting.

          resources:
            requests:

              cpu: 250m
              memory: 0.5Gi