Changing shared memory size in docker compose
It should be below service, I can verify it, but here is what offical documentation said
SHM_SIZE
Added in version 3.5 file format
Set the size of the /dev/shm partition for this build’s containers. Specify as an integer value representing the number of bytes or as a string expressing a byte value.
build: context: . shm_size: '2gb'
Here is test
version: '3.7'services: your_service: image: alpine command: ash -c "sleep 2 && df /dev/shm" shm_size: 2gb