Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to pass --device-cgroup-rule by docker-compose?

I need to use --device-cgroup-rule option, it works fine with docker run command, but I want to use it also in my docker-compose.yml file. But I didn't find it in the documentation. Is it possible at least?

like image 287
Petr Avatar asked Jan 29 '18 10:01

Petr


1 Answers

documented here https://docs.docker.com/compose/compose-file/compose-file-v2/#device_cgroup_rules

device_cgroup_rules:
  - 'c 1:3 mr'
  - 'a 7:* rmw'

it has been added quite recently it seems from the thread https://github.com/docker/compose/issues/5622

like image 69
Pierre-Alexis Ciavaldini Avatar answered Oct 03 '22 21:10

Pierre-Alexis Ciavaldini