My server has 2GB mem
I launched 2 containers in the server with docker-compose
Although I set the memory limiti, but it seems not work

docker-compose
hub:
mem_limit: 256m
image: selenium/hub
ports:
- "4444:4444"
test:
mem_limit: 256m
build: ./
links:
- hub
ports:
- "5900"
I'm not sure about this but try set mem_limit to 256000000 without using 'm'