Here's the thing.
Docker errors with OOM on container even if there's enough free memory. Docker allows to disable OOM kills for those containers that are memory-bound by adjusting container host config (https://docs.docker.com/engine/admin/resource_constraints/#limit-a-containers-access-to-memory). So, all our functions are memory bound (not sure if we follow same limitation as Docker - not less than 4MB RAM) why not use this feature, in any case we'd kill container right after timeout exceeds.
Env: Ubuntu server 16.04 10GB RAM, 2 vCPU, 200GB HDD
Function:
- required RAM: up to 2GB
- container size 2.5GB
This is 3 lines of code fix, but i want to get an input from all: @carimura @rdallman @treeder @hibooboo2.
Here's the thing.
Docker errors with OOM on container even if there's enough free memory. Docker allows to disable OOM kills for those containers that are memory-bound by adjusting container host config (https://docs.docker.com/engine/admin/resource_constraints/#limit-a-containers-access-to-memory). So, all our functions are memory bound (not sure if we follow same limitation as Docker - not less than 4MB RAM) why not use this feature, in any case we'd kill container right after timeout exceeds.
Env: Ubuntu server 16.04 10GB RAM, 2 vCPU, 200GB HDD
Function:
This is 3 lines of code fix, but i want to get an input from all: @carimura @rdallman @treeder @hibooboo2.