OLD | NEW |
1 #!/bin/bash | 1 #!/bin/bash |
2 | 2 |
3 # Copyright (c) 2010 The Chromium OS Authors. All rights reserved. | 3 # Copyright (c) 2010 The Chromium OS Authors. All rights reserved. |
4 # Use of this source code is governed by a BSD-style license that can be | 4 # Use of this source code is governed by a BSD-style license that can be |
5 # found in the LICENSE file. | 5 # found in the LICENSE file. |
6 | 6 |
7 echo "Applying patch to init scripts." | 7 echo "Applying patch to init scripts." |
8 pushd ${ROOT_FS_DIR} | |
9 | 8 |
10 touch ${ROOT_FS_DIR}/root/.factory_test | 9 touch ${ROOT_FS_DIR}/root/.factory_test |
11 patch -d ${ROOT_FS_DIR} -Np1 <<EOF | 10 patch -d ${ROOT_FS_DIR} -Np1 <<EOF |
12 --- old/etc/init/ui.conf 2010-04-28 21:28:38.886069000 -0700 | 11 --- old/etc/init/ui.conf 2010-04-28 21:28:38.886069000 -0700 |
13 +++ new/etc/init/ui.conf 2010-04-28 21:29:42.676163000 -0700 | 12 +++ new/etc/init/ui.conf 2010-04-28 21:29:42.676163000 -0700 |
14 @@ -5,7 +5,7 @@ | 13 @@ -5,7 +5,7 @@ |
15 description "Chrome OS user interface" | 14 description "Chrome OS user interface" |
16 author "chromium-os-dev@googlegroups.com" | 15 author "chromium-os-dev@googlegroups.com" |
17 | 16 |
18 -start on stopping startup | 17 -start on stopping startup |
(...skipping 20 matching lines...) Expand all Loading... |
39 | 38 |
40 cat > ${ROOT_FS_DIR}/etc/init/factory.conf <<EOF | 39 cat > ${ROOT_FS_DIR}/etc/init/factory.conf <<EOF |
41 # Copyright (c) 2010 The Chromium OS Authors. All rights reserved. | 40 # Copyright (c) 2010 The Chromium OS Authors. All rights reserved. |
42 # Use of this source code is governed by a BSD-style license that can be | 41 # Use of this source code is governed by a BSD-style license that can be |
43 # found in the LICENSE file. | 42 # found in the LICENSE file. |
44 | 43 |
45 description "Chrome OS factory startup stub" | 44 description "Chrome OS factory startup stub" |
46 author "chromium-os-dev@googlegroups.com" | 45 author "chromium-os-dev@googlegroups.com" |
47 | 46 |
48 start on started udev | 47 start on started udev |
| 48 stop on starting halt or starting reboot |
49 | 49 |
50 script | 50 script |
51 | |
52 cd /usr/local/autotest | 51 cd /usr/local/autotest |
| 52 eval \$(./factory_startx.sh) |
53 date >> /var/log/factory.log | 53 date >> /var/log/factory.log |
54 if [ ! -e factory_started ]; then | 54 if [ ! -e factory_started ]; then |
55 touch factory_started | 55 touch factory_started |
56 cp -f site_tests/suite_Factory/control.full control | 56 cp -f site_tests/suite_Factory/control.ui control |
57 ./bin/autotest control >> /var/log/factory.log 2>&1 | 57 ./bin/autotest control >> /var/log/factory.log 2>&1 |
58 else | 58 else |
59 ./tools/autotest >> /var/log/factory.log 2>&1 | 59 ./tools/autotest >> /var/log/factory.log 2>&1 |
60 fi | 60 fi |
61 end script | 61 end script |
62 EOF | 62 EOF |
63 | 63 |
64 cat > ${ROOT_FS_DIR}/etc/init/factorylog.conf <<EOF | 64 cat > ${ROOT_FS_DIR}/etc/init/factorylog.conf <<EOF |
65 # Copyright (c) 2010 The Chromium OS Authors. All rights reserved. | 65 # Copyright (c) 2010 The Chromium OS Authors. All rights reserved. |
66 # Use of this source code is governed by a BSD-style license that can be | 66 # Use of this source code is governed by a BSD-style license that can be |
67 # found in the LICENSE file. | 67 # found in the LICENSE file. |
68 | 68 |
69 start on started factory | 69 start on started factory |
70 stop on starting halt or starting reboot | 70 stop on starting halt or starting reboot |
71 | 71 |
72 respawn | 72 respawn |
73 script | 73 script |
74 tail -n 48 -F /var/log/factory.log > /dev/tty1 | 74 tail -n 48 -F /var/log/factory.log > /dev/tty3 |
75 end script | 75 end script |
76 EOF | 76 EOF |
77 | 77 |
78 popd | 78 patch -d ${ROOT_FS_DIR} -Np1 <<EOF |
| 79 diff --git old/etc/init/software-update.conf new/etc/init/software-update.conf |
| 80 index 28c9086..9ebf2b9 100644 |
| 81 --- old/etc/init/software-update.conf |
| 82 +++ new/etc/init/software-update.conf |
| 83 @@ -7,7 +7,7 @@ |
| 84 # |
| 85 # when dump-boot-stats has run, start up software update check. |
| 86 |
| 87 -start on stopped dump-boot-stats |
| 88 +start on never |
| 89 |
| 90 respawn |
| 91 EOF |
OLD | NEW |