Skip to content

Commit 049eee1

Browse files
committed
fix: make sure buildkite-agent.service is not terminated by OOM
Fixes #882 Set OOMScoreAdjust to -1000 disabling OOM killing of buildkite-agent processes. https://www.freedesktop.org/software/systemd/man/latest/systemd.exec.html#OOMScoreAdjust=
1 parent 0a0d218 commit 049eee1

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

packer/linux/conf/buildkite-agent/systemd/buildkite-agent.service

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,10 @@ RestartForceExitStatus=SIGPIPE
2121
TimeoutStartSec=10
2222
TimeoutStopSec=0
2323
KillMode=process
24+
# https://www.freedesktop.org/software/systemd/man/latest/systemd.exec.html#OOMScoreAdjust=
25+
# Set to -1000 to disable OOM killing of processes of buildkite-agent service
26+
# managing EC2 instance lifecycle
27+
OOMScoreAdjust=-1000
2428

2529
[Install]
2630
WantedBy=multi-user.target

0 commit comments

Comments
 (0)