| # Copyright (c) 2012 The Chromium OS Authors. All rights reserved. |
| # Use of this source code is governed by a BSD-style license that can be |
| # found in the LICENSE file. |
| |
| description "Simple Watchdog daemon" |
| author "chromium-os-dev@chromium.org" |
| |
| start on started boot-services |
| stop on stopping boot-services |
| respawn |
| |
| pre-start script |
| # Depending on kernel output strings is fragile. :/ |
| # Could monitor daisydog output instead? |
| # Only better since this conf file is part of daisydog ebuild. |
| if dmesg | fgrep -q 'Watchdog timed out' ; then |
| metrics_client -v HwWatchdogReboot |
| fi |
| end script |
| |
| exec nice -n -20 /sbin/minijail0 -u watchdog -g watchdog -- /usr/sbin/daisydog |