26a1bcf372c74c8fcbc2dab11802ff0ac04dfeea
[csit.git] / resources / tools / testbed-setup / ansible / roles / tg_sut / templates / docker.service.j2
1 # {{ ansible_managed }}
2
3 [Unit]
4 Description=Docker Application Container Engine
5 Documentation=https://docs.docker.com
6 After=network-online.target docker.socket
7 Requires=docker.socket
8
9 [Service]
10 Type=notify
11 # the default is not to use systemd for cgroups because the delegate issues still
12 # exists and systemd currently does not support the cgroup feature set required
13 # for containers run by docker
14 {% if docker_daemon_environment %}
15 Environment="{{ docker_daemon_environment | join('" "') }}"
16 {% endif %}
17 ExecStart=/usr/bin/dockerd {{ docker_daemon_options | join(" ") }}
18 ExecReload=/bin/kill -s HUP $MAINPID
19 # Having non-zero Limit*s causes performance problems due to accounting overhead
20 # in the kernel. We recommend using cgroups to do container-local accounting.
21 LimitNOFILE=infinity
22 LimitNPROC=infinity
23 LimitCORE=infinity
24 # Uncomment TasksMax if your systemd version supports it.
25 # Only systemd 226 and above support this version.
26 TasksMax=infinity
27 TimeoutStartSec=0
28 # set delegate yes so that systemd does not reset the cgroups of docker containers
29 Delegate=yes
30 # kill only the docker process, not all processes in the cgroup
31 KillMode=process
32
33 [Install]
34 WantedBy=multi-user.target