Skip to content

Commit

Permalink
Explicitely set ulimits for mq to ERL_MAX_PORTS (metabrainz#258)
Browse files Browse the repository at this point in the history
On Linux ERL_MAX_PORTS defaults to 65,536. But the Docker container for
the service `mq` rather uses the host ulimits. When ulimits is infinite,
it can make the container to take a very long time to start while using
a lot of CPU for nothing. It depends on the host settings.

This patch explicitely sets ulimits to 65,536 as recommended for `mq`.

See docker-library/rabbitmq#545 for details.
  • Loading branch information
yvanzo authored and danielunderwood committed Oct 24, 2023
1 parent 78cbcb9 commit c39240f
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -113,6 +113,8 @@ services:
max-size: "10m"
max-file: "10"
restart: unless-stopped
ulimits:
nofile: 65536
volumes:
- mqdata:/var/lib/rabbitmq
expose:
Expand Down

0 comments on commit c39240f

Please sign in to comment.