blob: 8528dc72444b359d6e2c4bce94cb0fc90c130f5b [file] [log] [blame]
# Copyright (c) 2010 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 "Factory installer service"
# author "chromium-os-dev@googlegroups.com"
#
# when boot has finished, start up factory installer.
start on started system-services
# Use setsid to ensure that the script has the controlling terminal.
script
# If using a serial console, use that; otherwise use tty1.
if grep -q console=ttyS0 /proc/cmdline; then
tty=/dev/ttyS0
else
tty=/dev/tty1
fi
exec setsid sh -c "exec /usr/sbin/factory_install.sh <$tty >$tty 2>&1"
end script