Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(838)

Side by Side Diff: image_to_live.sh

Issue 6277015: Passes cache location to tests and runs the tests in parallel. (Closed) Base URL: http://git.chromium.org/git/crosutils.git@master
Patch Set: Fix sudo issues again. Created 9 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 #!/bin/bash 1 #!/bin/bash
2 2
3 # Copyright (c) 2009-2010 The Chromium OS Authors. All rights reserved. 3 # Copyright (c) 2009-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 # Script to update an image onto a live running ChromiumOS instance. 7 # Script to update an image onto a live running ChromiumOS instance.
8 8
9 # Load common constants. This should be the first executable line. 9 # Load common constants. This should be the first executable line.
10 # The path to common.sh should be relative to your script's location. 10 # The path to common.sh should be relative to your script's location.
11 11
12 . "$(dirname $0)/common.sh" 12 . "$(dirname $0)/common.sh"
13 . "$(dirname $0)/remote_access.sh" 13 . "$(dirname $0)/remote_access.sh"
14 14
15 # Flags to control image_to_live. 15 # Flags to control image_to_live.
16 DEFINE_boolean ignore_hostname ${FLAGS_TRUE} \ 16 DEFINE_boolean ignore_hostname ${FLAGS_TRUE} \
17 "Ignore existing AU hostname on running instance use this hostname." 17 "Ignore existing AU hostname on running instance use this hostname."
18 DEFINE_boolean ignore_version ${FLAGS_TRUE} \ 18 DEFINE_boolean ignore_version ${FLAGS_TRUE} \
19 "Ignore existing version on running instance and always update." 19 "Ignore existing version on running instance and always update."
20 DEFINE_string server_log "dev_server.log" \ 20 DEFINE_string server_log "dev_server.log" \
21 "Path to log for the devserver." 21 "Path to log for the devserver."
22 DEFINE_boolean update "${FLAGS_TRUE}" \ 22 DEFINE_boolean update "${FLAGS_TRUE}" \
23 "Perform update of root partition." 23 "Perform update of root partition."
24 DEFINE_boolean update_known_hosts ${FLAGS_FALSE} \ 24 DEFINE_boolean update_known_hosts ${FLAGS_FALSE} \
25 "Update your known_hosts with the new remote instance's key." 25 "Update your known_hosts with the new remote instance's key."
26 DEFINE_string update_log "update_engine.log" \ 26 DEFINE_string update_log "update_engine.log" \
27 "Path to log for the update_engine." 27 "Path to log for the update_engine."
28 DEFINE_string update_url "" "Full url of an update image."
28 DEFINE_boolean verify ${FLAGS_TRUE} "Verify image on device after update." 29 DEFINE_boolean verify ${FLAGS_TRUE} "Verify image on device after update."
29 30
30 # Flags for devserver. 31 # Flags for devserver.
31 DEFINE_string archive_dir "" \ 32 DEFINE_string archive_dir "" \
32 "Update using the test image in the image.zip in this directory." a 33 "Update using the test image in the image.zip in this directory." a
33 DEFINE_string board "" "Override the board reported by the target" 34 DEFINE_string board "" "Override the board reported by the target"
34 DEFINE_integer devserver_port 8080 \ 35 DEFINE_integer devserver_port 8080 \
35 "Port to use for devserver." 36 "Port to use for devserver."
36 DEFINE_boolean for_vm ${FLAGS_FALSE} "Image is for a vm." 37 DEFINE_boolean for_vm ${FLAGS_FALSE} "Image is for a vm."
37 DEFINE_string image "" \ 38 DEFINE_string image "" \
38 "Update with this image path that is in this source checkout." i 39 "Update with this image path that is in this source checkout." i
39 DEFINE_string payload "" \ 40 DEFINE_string payload "" \
40 "Update with this update payload, ignoring specified images." 41 "Update with this update payload, ignoring specified images."
41 DEFINE_string proxy_port "" \ 42 DEFINE_string proxy_port "" \
42 "Have the client request from this proxy instead of devserver." 43 "Have the client request from this proxy instead of devserver."
43 DEFINE_string src_image "" \ 44 DEFINE_string src_image "" \
44 "Create a delta update by passing in the image on the remote machine." 45 "Create a delta update by passing in the image on the remote machine."
45 DEFINE_boolean update_stateful ${FLAGS_TRUE} \ 46 DEFINE_boolean update_stateful ${FLAGS_TRUE} \
46 "Perform update of stateful partition e.g. /var /usr/local." 47 "Perform update of stateful partition e.g. /var /usr/local."
47 DEFINE_string update_url "" "Full url of an update image."
48 48
49 # Flags for stateful update. 49 # Flags for stateful update.
50 DEFINE_string stateful_update_flag "" \ 50 DEFINE_string stateful_update_flag "" \
51 "Flag to pass to stateful update e.g. old, clean, etc." s 51 "Flag to pass to stateful update e.g. old, clean, etc." s
52 52
53 UPDATER_BIN="/usr/bin/update_engine_client" 53 UPDATER_BIN="/usr/bin/update_engine_client"
54 UPDATER_IDLE="UPDATE_STATUS_IDLE" 54 UPDATER_IDLE="UPDATE_STATUS_IDLE"
55 UPDATER_NEED_REBOOT="UPDATE_STATUS_UPDATED_NEED_REBOOT" 55 UPDATER_NEED_REBOOT="UPDATE_STATUS_UPDATED_NEED_REBOOT"
56 UPDATER_UPDATE_CHECK="UPDATE_STATUS_CHECKING_FOR_UPDATE" 56 UPDATER_UPDATE_CHECK="UPDATE_STATUS_CHECKING_FOR_UPDATE"
57 UPDATER_DOWNLOADING="UPDATE_STATUS_DOWNLOADING" 57 UPDATER_DOWNLOADING="UPDATE_STATUS_DOWNLOADING"
(...skipping 354 matching lines...) Expand 10 before | Expand all | Expand 10 after
412 local release_description=$(echo ${REMOTE_OUT} | cut -d '=' -f 2) 412 local release_description=$(echo ${REMOTE_OUT} | cut -d '=' -f 2)
413 info "Update was successful and rebooted to $release_description" 413 info "Update was successful and rebooted to $release_description"
414 fi 414 fi
415 415
416 print_time_elapsed 416 print_time_elapsed
417 417
418 exit 0 418 exit 0
419 } 419 }
420 420
421 main $@ 421 main $@
OLDNEW
« bin/cros_au_test_harness.py ('K') | « bin/cros_run_vm_update ('k') | lib/cros_build_lib.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698