Find out which before you touch the limit. Plot container_memory_working_set_bytes over a few restart cycles:
- Sawtooth that plateaus below the limit, then gets killed on a spike → the limit is genuinely too low.
- Steady climb that never plateaus → a leak; raising the limit only lengthens the interval between restarts.
For Node specifically, also set the heap ceiling below the container limit:
Otherwise V8 happily grows past 512Mi and the kernel kills the process before the garbage collector ever feels pressure.