When we run docker image and export too many ports, dockerd will output some errors like "too many open files", it is caused by max-file limitation. Now, we start dockerd using procd, just add a statement to fix this problem. Signed-off-by: Fuying Wang <805447391@qq.com>
13 lines
250 B
Bash
13 lines
250 B
Bash
#!/bin/sh /etc/rc.common
|
|
|
|
USE_PROCD=1
|
|
START=25
|
|
|
|
start_service() {
|
|
local nofile=$(cat /proc/sys/fs/nr_open)
|
|
|
|
procd_open_instance
|
|
procd_set_param command /usr/bin/dockerd
|
|
procd_set_param limits nofile="${nofile} ${nofile}"
|
|
procd_close_instance
|
|
}
|