surtur
2c3835d445
* add drone.slice (control resource usage) * restrict can be accessed by the service * adjust IO priority and NICEness of processes created withing the service * use "-p" with docker-compose invocation to specify a project that the newly-spawned containers belong to (best practice) * add commented override
15 lines
263 B
SYSTEMD
15 lines
263 B
SYSTEMD
# /etc/systemd/system/drone.slice
|
|
[Unit]
|
|
Description=Slice that limits drone.service resources
|
|
Before=slices.target
|
|
After=docker.service docker.slice
|
|
|
|
[Slice]
|
|
CPUAccounting=yes
|
|
CPUQuota=315%
|
|
|
|
MemoryAccounting=yes
|
|
MemoryHigh=4.1G
|
|
MemoryMax=4.2G
|
|
MemorySwapMax=200M
|