blob: 94dda284f6dbf2ce7ae0d48a89e60a3466876cf6 [file] [log] [blame]
# Copyright 2019 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 "Initialize factory test environment"
author "chromium-os-dev@chromium.org"
# For factory test to perform early initialization. E.g. changing UI start
# parameters...
# Hint: ui.conf starts on "started boot-services", so this upstart job should
# always run before UI starts.
# This service should be woken up by emitting an "factory-init-event" event from
# an earlier service loading factory_utils.sh and checking is_factory_mode, for
# example factory-preinit.conf. Other factory related service can do "start on
# stopped factory-init" to prevent checking is_factory_mode.
# This service now is a post-hook of "startup", it will start right before it
# marked stopped (upstart "stopping" state). Also, because we want to hook some
# service and reload configuration for the needed of factory toolkit, this
# service should make srue all dependancies of "boot-services" except "startup"
# are already finished. That is, this task should be a critical section of the
# booting process.
start on factory-init-event and stopped boot-splash
task
exec /usr/local/factory/init/startup init