| # Copyright 2018 The ChromiumOS Authors |
| # Use of this source code is governed by a BSD-style license that can be |
| # found in the LICENSE file. |
| |
| description "Starts bootlockbox daemon" |
| author "chromium-os-dev@chromium.org" |
| |
| start on started boot-services and started tpm_managerd |
| stop on hwsec-stop-clients-signal |
| |
| respawn |
| |
| oom score -100 |
| |
| tmpfiles /usr/lib/tmpfiles.d/bootlockbox.conf |
| |
| expect fork |
| |
| script |
| PROFILING_ARGS="" |
| if [ -d "/mnt/stateful_partition/unencrypted/profraws" ]; then |
| PROFILING_ARGS="-b /mnt/stateful_partition/unencrypted/profraws,,1" |
| fi |
| exec minijail0 --config /usr/share/minijail/bootlockboxd.conf \ |
| ${PROFILING_ARGS} \ |
| -- /usr/sbin/bootlockboxd |
| end script |
| |
| # Wait for the daemon to claim its D-Bus name. |
| post-start exec minijail0 -u bootlockboxd -G \ |
| /usr/bin/gdbus wait --system --timeout 15 org.chromium.BootLockbox |