Commit Graph

282 Commits

Author SHA1 Message Date
Chris Sosa
33146728ef Add ability to vm library to retry until we can ssh into it.
Change-Id: I4de388bb1af6cd4568cdc154971927941eb73800

BUG=7503
TEST=Ran test by closing vm's as they start up to see retry work.

Review URL: http://codereview.chromium.org/3598019
2010-10-07 15:58:24 -07:00
Chris Sosa
d8f50a931f Propagate return code correctly from tests.
Change-Id: I28c5f3e48646ec24813ef86f4cd16aac120cba5b

BUG=
TEST=Introduced artificial bug and checked return code
from test.

Review URL: http://codereview.chromium.org/3593010
2010-10-07 11:24:28 -07:00
Chris Sosa
224f7548b5 Revert "Close tree when smoke bvt fails."
This reverts commit d9bbe8792f.

TBR=Open tree.

Change-Id: I2d81711e4f995dbe025b7ed5f99fb4e4f7aba1c8
2010-10-06 17:40:51 -07:00
Chris Sosa
24680f0059 Add ability to test machines with au test harness.
Change-Id: I913acd95c49b1cf0fd666b49fb5ec1e24f0f83d1

BUG=7285
TEST=Ran through test against with two test images.

Review URL: http://codereview.chromium.org/3619009
2010-10-06 16:56:56 -07:00
Chris Sosa
2cc5cd4155 Add ctest that calls the au test harness.
Change-Id: Ief14528b7e98d792da4be39976ff0fe48219f93b

BUG=6913
TEST=Ran image_to_vm, cros_au_test_harness, and ctest using internal urls.

Review URL: http://codereview.chromium.org/3606008
2010-10-06 14:29:45 -07:00
Chris Sosa
d9bbe8792f Close tree when smoke bvt fails.
Change-Id: I01d613527777098616e8d5bd2b4b27bce240c02f

BUG=
TEST=Ran cbuildbot and prematurely killed autotest to show test failure.  CBuildbot fails saying that cros_run_vm_test smoke_Suite failed.

Review URL: http://codereview.chromium.org/3517010
2010-10-06 10:58:08 -07:00
Chris Sosa
c1b14b52d0 Add defaults for cros_make_image_bootable.
This will allow dev who didn't build an image to still use cros_make_image_bootable
to update their image -- including mod_image_for_test / image_to_vm.

Change-Id: I1ba4292223b28b21d5416745e7744641100fa4ad

BUG=7370
TEST=Ran image_to_vm with other image and image I built myself.  Also ran
cros_make_image_bootable directly on a the same two images.

Review URL: http://codereview.chromium.org/3569015
2010-10-05 13:23:50 -07:00
Chris Sosa
af33f8f8ae Add board option to au test harness so that this works for others without a default board and add ability to reference images without relative paths.
Change-Id: I4afa86fa7a6b772124de56114910a1ca5e3d4511

BUG=
TEST=Ran through update harness code and ran loman.

Review URL: http://codereview.chromium.org/3612004
2010-10-04 18:19:29 -07:00
Chris Sosa
3ede50ed4e Add enabling of local account. This should get the suite_Smoke to go green on the pfq.
Change-Id: Id480f45836a81d7d994b92d7a45d16208e1dd11c

BUG=
TEST=Ran locally.  Saw all tests pass.

Review URL: http://codereview.chromium.org/3567010
2010-10-01 14:12:26 -07:00
Paul Stewart
3da3113c01 Remove cros_copy_upgrade_server.sh
This script had a short painful life, constantly being brittle
and broken.  It is time for it to go.  Please use
cros_image_to_target.py instead.

BUG=none
TEST=none

Review URL: http://codereview.chromium.org/3536002
2010-10-01 11:22:23 -07:00
Paul Stewart
48d7d8bb7f Add sha256 to devserver clone updater output
BUG=none
TEST=none

Review URL: http://codereview.chromium.org/3572006
2010-09-30 18:16:21 -07:00
Chris Sosa
cb9e4fe449 Change hostname to localhost ip
TBR

Change-Id: I1a911da2df7cddda3eb35f6df23e203cd94c1ffe

BUG=
TEST=Locally.

Review URL: http://codereview.chromium.org/3536003
2010-09-30 18:02:09 -07:00
Chris Sosa
bccc7c1d03 Initial auto update engine test harness.
This harness has support for test on vm machines.  It takes a base image and target image path, creates an update-enabled vm image from the base image and performs updates using cros_run_vm_update (vm wrapper around image_to_live).  It uses --snapshot for updating vm's and keeps them on (like a real machine would) so that the VM image is clean on the next test.

The current check in has two test cases -- updates without clobbering the stateful partition and updates with clobbering the stateful partition.

Change-Id: I5406eadb39fa36601d17f8dd15625bd6a8b38c15

BUG=6911
TEST=Ran through tests.

Review URL: http://codereview.chromium.org/3554002
2010-09-30 15:06:15 -07:00
Chris Sosa
c2db26c796 Add methods to run vm tests on x86-pre-flight-queue.
Right now we're leaving error_ok=True until the tests are shown to work on builder.

Change-Id: I6b8c690a0da30948389fd4312032c78d87115364

BUG=6906
TEST=Ran through it locally.

Review URL: http://codereview.chromium.org/3591002
2010-09-30 14:25:25 -07:00
Kenneth Waters
e3049de00f build_image: Merge x86 and ARM where possible.
- I looked at all of the x86 and ARM paths through out build image scripts,
  these changes clean up stale comments, stale code, and unforks some small
  things.

BUG=none
TEST=Built images for x86-generic, arm-generic and tegra2-seaboard, booted tegra2-seaboard image.

Review URL: http://codereview.chromium.org/3448022

Change-Id: Ibad2774ff2cbf5f15528454506542b87e43e24a2
2010-09-30 14:20:34 -07:00
Chris Sosa
45bec936f6 Move vm constants into their own file. This will make it easier to share these constants.
Also fixed get latest image logic in image_to_vm and allowed for using the most recent image in cros_run_vm_test to follow other shell convention of using latest.

Change-Id: I60ed4c03d609500da7f6ae34ef57ba2e32f4b0bb

BUG=
TEST=Tested by running image_to_vm with --full and cros_run_vm_test with suite_Smoke

Review URL: http://codereview.chromium.org/3597001
2010-09-29 15:38:53 -07:00
Chris Sosa
3b65e8dd6f Add verify option to image_to_live.
Change-Id: I63f7ce38179b713bb26bed70d6fd392425595a81

BUG=
TEST=Ran with update vm script.

Review URL: http://codereview.chromium.org/3393019
2010-09-28 18:41:56 -07:00
Chris Sosa
f485c86416 Fix unit tests for cbuildbot.
Change-Id: I86b3eb5d7b421aaade85bd702b9089986c82cc76

BUG=
TEST=Re-ran unit tests with cbuildbot TOT.

Review URL: http://codereview.chromium.org/3441027
2010-09-28 13:08:40 -07:00
David James
70b297a263 Update cbuildbot.py to print manifests when we sync.
If cbuildbot.py printed out a manifest when it syncs, it would make it possible
for us to reproduce the build later by looking at what revisions the buildbot
was using. This is useful for debugging.

Change-Id: I186ad01eef0090b6c618cb7ad583085197474018

BUG=chromium-os:7069
TEST=Ran test suite with 3441027 patched in (Sosa's patch that fixes an unrelated issue with the unit tests)

Review URL: http://codereview.chromium.org/3461028
2010-09-25 23:25:18 -07:00
David James
7bf8d2715e Switch off repo sync --jobs, and turn on repo --trace.
repo sync --jobs doesn't check for errors, so we shouldn't use it in
automated scripts. repo --trace is needed so that we can diagnose
whether git is hanging.

BUG=chromium-os:7048, chromium-os:6774
TEST=Ran test suite

Change-Id: I9e68cfffe841a231f5fabef951ea2d45b81c1d5e

Review URL: http://codereview.chromium.org/3419024
2010-09-25 23:23:00 -07:00
Mandeep Singh Baines
ee49ac0ec5 loman: Add support for adding elements from default.xml
This is needed in order to do the right thing when adding projects
which require a revision attribute.

BUG=6811
TEST=Updated unittests and verified they pass.
Verified that I can add chromeos-kernel-next and revision gets set.

Change-Id: I12818dad464094cd50098170da3fcf38b1e32f17

Review URL: http://codereview.chromium.org/3400019
2010-09-24 08:27:50 -07:00
Kenneth Waters
9bc78b3acb make_image: Fake vmlinuz_hd.vblock on ARM.
- This unbreaks the devserver's update server for ARM.
- This also unforks some of build_image.

BUG=None
TEST=Installed to tegra2_seaboard from USB without --skip_vblock,
     updated tegra2_seaboard.

Review URL: http://codereview.chromium.org/3493004

Change-Id: I6e66344de51609393407934f78aa20f49974efef
2010-09-22 13:54:44 -07:00
Chris Sosa
8f6ee51c21 Add persist option to vm library.
BUG=
TEST=Tested by persisting, ctrl+c, continuing and using same vm.
Also without --persist

Review URL: http://codereview.chromium.org/3419014

Change-Id: I49e26eb86101e8b8b50e58a9f277d62d5fadc664
2010-09-22 11:51:52 -07:00
Chris Sosa
e8c3cdc91c cros_make_image_bootable is not compatible with restart_inside_chroot
restart_inside_chroot first assumes that the calling script is in
src/scripts.  Next any paths are not converted when passed so if
someone passes the most recent image, this will also not be interpreted
correctly.

Change-Id: Icb2dfc661eb84e134b4d8c5cf0354a6c1ab161f0

BUG=
TEST=Manually tested running outside chroot (getting error) and inside chroot.

Review URL: http://codereview.chromium.org/3421025
2010-09-21 17:45:15 -07:00
Chris Sosa
cc09f84b5e Update scripts for vm's
Change-Id: I63bdcaa3630c179d407310f6544c102f5353fa4d

BUG=5530
TEST=Ran both cros_run_vm_test and new script and had the latter update successfully.

Review URL: http://codereview.chromium.org/3427011
2010-09-21 17:09:51 -07:00
Paul Stewart
b0d5cf28e5 New application cros_image_to_target.py for ssh_tunnel upgrade
The RF testbed has hosts behind a one-way firewall, so the
conventional "image_to_live" script does not work.  My initial
attempt at solving this, 'cros_copy_upgrade_server', while
sometimes functional, was always quite brittle since it had
widely ranging dependencies which often changed in ways that
the authors could not predict would break our setup.

I've written from scratch a new script in python which uses
ssh tunnels to get around the problem of the firewall issue.
It also has retlatively minimal dependencies (stateful_update,
cros_generate_update_paylod, cgpt, get_latest_image.sh and
the testing keys) so hopefully it won't get blown away too
often.

BUG=none
TEST=Ran under chroot -- Need help testing

Review URL: http://codereview.chromium.org/3391008
2010-09-21 15:13:59 -07:00
Paul Stewart
fae37db122 Add "--mount" option to package_to_live
Optionally disable mount/remount during package install for
targets that are already mounted read-write.

BUG=none
TEST=rerun

Review URL: http://codereview.chromium.org/3439012
2010-09-21 13:19:48 -07:00
Kenneth Waters
ed54d93e2c build_image: Add verity support for ARM.
- Build a "kernel image" which contains a uboot script and a uboot kernel
  image.
- Fix some sd* assumptions.
- Remove cruft that has never done anything usefull from update_bootloaders

BUG=none
TEST=Built, booted, and updated on tegra2_dev-board

Review URL: http://codereview.chromium.org/3396011

Change-Id: I00ecf57faa5fe64c8e33dd4c042f1dbed806c10a
2010-09-21 10:29:54 -07:00
Paul Stewart
30d46e3c0d Re-do argument passing to match zbehan's change
zbehan's change: "run_remote_tests: destroy the with_spaces hack,
use the --args instead of -a (which doesn't work)", despite apparently
not working is in active use by others, both by folks using it on the
command line and by the script cros_run_wifi_tests.sh.  Fix the script
to match the new argument.

BUG=none
TEST=rerun

Review URL: http://codereview.chromium.org/3444010
2010-09-17 16:09:02 -07:00
Mandeep Singh Baines
6c6000b2c2 loman: don't report error when adding an exact duplicate.
BUG=5787
TEST=Updated and re-ran unittests.

Change-Id: I399e8cacde103f16b749dd83c57d03bcdf2e9475

Review URL: http://codereview.chromium.org/3385001
2010-09-14 10:19:50 -07:00
Paul Stewart
03b6ebf7d4 Add client_prefix (string) and old_prefix (bool) command line options
cros_copy_upgrade_server can now start the devserver with either prefix.
This is to help the migration from Memento to ChromeOSUpdateEngine.

BUG=none
TEST=none (yet)

Review URL: http://codereview.chromium.org/3304013
2010-09-13 13:28:14 -07:00
Mandeep Singh Baines
865a42edee loman: tool for updating local_manifest (initial commit)
BUG=5787
TEST=Ran unittests.

Change-Id: I6b8cc37eb2bf5f81f803f61b886106b6f08f3315

Review URL: http://codereview.chromium.org/3331013
2010-09-10 11:04:17 -07:00
Chris Sosa
7de6531962 Faster checkout and cleanup of old builds.
Change-Id: Id81fe4e7bd9cae7a51a45b6ea8a535c4ea9430f8

BUG=
TEST=Ran locally on top of previous build area.

Review URL: http://codereview.chromium.org/3337007
2010-09-02 15:10:48 -07:00
Paul Stewart
f9d7cf3ce0 remote_cp renamed to remote_cp_to. *shrug*
This function was renamed, so I renamed my reference to it.

BUG=none
TEST=Reran cros_package_to_live

Review URL: http://codereview.chromium.org/3331007
2010-09-01 18:32:37 -07:00
Nick Sanders
b801bec71a fix sign_to_ssd
Change-Id: If642d664163f36b79e3b6d845de0025cc3dc0372

BUG=6264
TEST="resign an image"

Review URL: http://codereview.chromium.org/3273011
2010-08-31 23:05:07 -07:00
Chris Sosa
e13960240b Fix cleanup so we don't have to clobber as much when failures occur
Change-Id: I120c49a38d2a17a2216296a68378fee7345f616a

TBR=petkov

Review URL: http://codereview.chromium.org/3255004
2010-08-30 22:37:28 -07:00
Chris Sosa
aaba25d817 Fix clobber. Strip any extra args and treat last arg as config.
Change-Id: I2bf951342c12d954bd1abbc8b878437c648b4ac7

TBR=Scottz
2010-08-30 20:28:11 -07:00
Chris Sosa
f0fcd1acfd Change config's to use .jail for cod[fg]'s
Change-Id: Ib7efb7d5a14371a3eb0dfa4a99992ea096146980

TBR=Config change:  Need to specify subnet for *.jail.
2010-08-30 18:52:46 -07:00
Ryan Cairns
1703423a77 Runs our BVT suite in a VM
Change-Id: I758c93596d5cbdd6b52b9acc82f4d6e19a326c9f

BUG=5518
TEST=Tested using all the options. All tests listed in the file pass.

Review URL: http://codereview.chromium.org/3107039
2010-08-30 17:03:50 -07:00
Chris Sosa
70e2c9e72a Move RunCommand, and Info/Warning/Die into common pylib
TEST=Ran all commands that used RunCommand or Die with
their associated unittests.

Review URL: http://codereview.chromium.org/3266004
2010-08-30 11:05:50 -07:00
Chris Sosa
1ec70345d9 Change clobber logic to be explicit
TEST=Tested with --clobber and without.

Change-Id: I6a938b3da673d97186cec79f25b22ea6176f1fdf

Review URL: http://codereview.chromium.org/3238012
2010-08-30 10:48:08 -07:00
Chris Sosa
0c13b46899 Move back to marking all until we have individual tree closing ready.
Review URL: http://codereview.chromium.org/3246003
2010-08-27 17:01:38 -07:00
Chris Sosa
0c156f9ccb TBR: Add replace to build_image 2010-08-27 13:11:56 -07:00
Chris Sosa
151a896d4b TBR: Fix missing enter_chroot's in pfq 2010-08-27 11:48:08 -07:00
Chris Sosa
6d58d427e3 Add all pfq configurations and add build_image / run_unit_tests.
BUG=5468
TEST=Ran default and ran x86-generic.  Took board values from master.cfg in buildbot

Review URL: http://codereview.chromium.org/3200006

Change-Id: I1d3e4216dc9ca9af0d9e8c1bfffabffa87f89b04
2010-08-27 10:04:31 -07:00
Chris Sosa
5208429f8e TBR: Fix circ dep issue with cbuildbot 2010-08-26 14:45:25 -07:00
Chris Sosa
4b9baf9fa1 Add ability for cbuildbot master to synchronize with cbuildbot slaves.
TEST=Ran several non-checked in unit tests (will check in later) and tested
with cbuildbot as it is now.
BUG=5989

Review URL: http://codereview.chromium.org/3165052

Change-Id: I867a597b34bbf63261b9d19b57cef9631100c339
2010-08-26 14:06:56 -07:00
Chris Sosa
6f7d6cef0e Fix case where there is nothing to uprev.
TEST=Ran unit tests.

Change-Id: Iafd9702c5364511d79667ecc296eaf68fc89a5fb

Review URL: http://codereview.chromium.org/3159047
2010-08-26 12:34:20 -07:00
Chris Sosa
5140c15674 Fix bug with git packages with no matching ebuild.
Change-Id: I45454c837807fbe6e5996b76087bbfe25d7155ce

Review URL: http://codereview.chromium.org/3171032
2010-08-26 11:18:25 -07:00
Chris Sosa
e9b94eefd0 CBuildbot - Adds ability to only rev packages given by the sourcestamp.
The buildbot drops a source stamp (repo1.git@commit1 repo2.git@commit2 ...).
If CBuildbot finds the source stamp, it uses it and revs only those packages.
If this file is either missing or set to "None", it assumes a Force Build
has been pressed and keeps the old behavior (attempts to mark all).

TEST=Ran with 3 states of revisions file.
BUG=5006

Review URL: http://codereview.chromium.org/3163030

Change-Id: I226fd3bec642224b31ce51eee34d028043964943
2010-08-26 10:55:27 -07:00
Mandeep Singh Baines
a87699b198 cbuildbot: fix to point to new url
BUG=6102
TEST=none

Change-Id: I69312fed2d0eb4934a964792b4af06160b8d8eb5

Review URL: http://codereview.chromium.org/3135049
2010-08-25 14:39:18 -07:00
Paul Stewart
e7c459dcdc package_to_live script pushes binary emerge package to remote device
This script allows us to test packages on development boxes which
might be behind a firewall in a way that prevents use of "gmerge".
In this model, images are built locally and then pushed onto the
client.

TEST=run on wifi testbed
BUG=none

Review URL: http://codereview.chromium.org/3111018
2010-08-25 10:44:16 -07:00
Will Drewry
537caa90c0 Clean up cros_make_image_bootable and image_to_vm
image_to_vm.sh was running chromeos-setimage.  This script
was not meant to be run outside of a CrOS environment, but
its use here predates the cros_make_image_bootable script.

The change converts the rehashing and imaging over to using
cros_make_image_bootable.  The vm image uses the usb boot target but defaults
the usb drive to sda3.

update_bootloaders is fixed to not clobber existing syslinux
templates.

cros_make_image_bootable flag override support was broken and this fixes it.

TEST=build a new image wtih rootfs checking and without and ensure both woth with image_to_vm.  Also make sure they still boot normally on available hardware.
BUG=chromium-os:5939

Review URL: http://codereview.chromium.org/3189018

Change-Id: Ib4ac25f1a76f25ac7ce4538614ba247df9caea91
2010-08-20 20:30:56 -05:00
Chris Sosa
a8a4803f4f Fix cbuildbot. Mistakenly used str.open instead of open
TEST=Test underway.

Review URL: http://codereview.chromium.org/3116029
2010-08-20 10:55:48 -07:00
Mandeep Singh Baines
2e9e668dc0 cbuildbot: fix typo
BUG=5937
TEST=none

Change-Id: I5b4a79fff4f3d263812e1dd0392e21ec3bede69d

Review URL: http://codereview.chromium.org/3175030
2010-08-20 08:08:43 -07:00
Chris Sosa
81dae09de0 Add a flag to pick up timestamp of commits and print information if found and add noclobber option for easier testing.
TEST=Ran cbuildbot with file.

Review URL: http://codereview.chromium.org/3174021
2010-08-19 18:03:06 -07:00
Chris Sosa
d26c87d176 Buildbots should not need to push changes unless they are a pre flight buildbot.
TEST=Ran cbuildbot twice.
BUG=5907

Review URL: http://codereview.chromium.org/3110027
2010-08-19 16:20:51 -07:00
Chris Sosa
1ee50d3ce2 Add repo sync all helper for non-pfq buildbots.
TEST=Ran script and re-ran cbuildbot to completion of sync.

Change-Id: I31fddca6f720fecb461a96c1ffa54d4923b3c1c4

Review URL: http://codereview.chromium.org/3166019
2010-08-18 21:25:05 -07:00
Chris Sosa
9a27b4099f Always re-configure to use ssh even on incremental checkouts
Change-Id: I0a729b14e34c61a8174edd63fb20066e0811128e

Review URL: http://codereview.chromium.org/3181025
2010-08-18 18:18:18 -07:00
Kenneth Waters
eca76464c7 make_image: Install u-boot scripts to ESP partition.
BUG=1150
TEST=Built image for tegra2_dev_board, and x86-generic

Review URL: http://codereview.chromium.org/3109018
2010-08-18 11:17:01 -07:00
Tan Gao
843b70acf4 Issue 5183: Create a developer shim for release builds
Change-Id: I14cd9dc365093c0450210d7853ad5f67ffa0ddd0

BUG=chromium-os:5183
TEST=1) manually built a dev install shim and verified it's only bootable when dev switch is ON

Review URL: http://codereview.chromium.org/3153001
2010-08-17 09:41:48 -07:00
Chris Sosa
82047a9d48 Add some information to cbuildbot output.
TEST=Ran cbuildbot locally.

Review URL: http://codereview.chromium.org/3137006

Change-Id: I8c80334480a4a2e4bb32234d323c0b129bed4692
2010-08-12 10:07:35 -07:00
Mandeep Singh Baines
6718164717 cbuildbot: use correct port
Ugh, it worked on my machine because of my .ssh/config but need to
explicitly specify port for it to work on buildbot.

TBR=sosa
BUG=5532
TEST=This change was in the previous location of cbuilbot.py and working
correctly.

Change-Id: Id53a76bcb5d43c37ac725267864048d833f5a6ee

Review URL: http://codereview.chromium.org/3144005
2010-08-11 10:29:56 -07:00
Chris Sosa
cd358fe1cb Adding cbuildbot to cros_utils. Leaving old version in repo until buildbot changes over.
TEST=Ran locally outside of chroot.  Required change to remove Exception OSError as
e because "as" is a Python 2.6'ism

Review URL: http://codereview.chromium.org/3146001
2010-08-09 19:33:22 -07:00
robotboy
508d08fdfb Add check for spaces in board and variant names.
Review URL: http://codereview.chromium.org/3084028
2010-08-09 13:29:30 -07:00
Will Drewry
6793ba78ca build_image,cros_make_image_bootable: fix missing arm argument
Adds arm_extra_bootargs to boot.desc and to cros_make_image_bootable.

TEST=tegra2 dev-board build_packages, build_image --fast worked
BUG=broken tree

Change-Id: Ifdfeda66f1eb5e5b1e618706eeba269f31fa9913

Review URL: http://codereview.chromium.org/3069031
2010-08-05 16:17:46 -05:00
Will Drewry
7ab698d713 build_image, mod_image_for_*: break out make_image_bootable
Breaks make_image_bootable out of build_image into a separate
script.  In addition, it make a helper .sh in the OUTPUT_DIR
to let make_image_bootable be re-run on an image with the same
arguments that were passed in via build_image.

This change also removes the use of the boot/ directory in
OUTPUT_DIR.

TEST=build_image verified; image_to_usb --test_image; booted l13
           build_image; image_to_vm; qemu booted
           build_image verified; image_to_usb; booted l13
BUG=chromium-os:5081

Review URL: http://codereview.chromium.org/3066037

Change-Id: I627d678089aa71c353347f387ad5b14063fd4e7b
2010-08-05 13:57:52 -05:00
J. Richard Barnette
138904ef93 Fix gsdcurl to correctly URL-quote a password passed via GSDCURL_PASSWORD
BUG=none
TEST=use this script with a (correct) password that includes punctuation such as one of these: $&+,/:;=?@

Review URL: http://codereview.chromium.org/3058046
2010-08-05 11:03:37 -07:00
bradnelson
2a0d4818f6 Dropping useless comment. Using getuser which is more correct.
Review URL: http://codereview.chromium.org/3005055
2010-08-04 13:15:23 -07:00
bradnelson
825074abc0 Making default to LOGNAME work correctly.
Modifying gsdcurl to accept username and password from the environment. Switching cros_download_latest_image to use gsdcurl

Merge branch 'master' of ssh://chromiumos-git/crosutils

Switching back to MixedCase. Wrong style guide...

Switching to match external style guide.

Dropping unneeded arg as per review.

Fixing copyright.

Making the prompts go to stderr. Renaming for tab completion.

Adding gsdcurl utility for pulling for Google Storage for Developers.

BUG=None
TEST=None

Review URL: http://codereview.chromium.org/3060043
2010-08-03 17:30:53 -07:00
robotboy
bd06106e80 Add checks that the board and variant names don't contain underscores.
Review URL: http://codereview.chromium.org/2878077
2010-08-03 13:31:52 -07:00
robotboy
465c39ab50 Move overlay_list to bin/cros_overlay_list.
This conforms to the new layout of scripts in which all scripts
other than make_chroot and enter_chroot are installed in the
chroot using an ebuild.

Review URL: http://codereview.chromium.org/3084012
2010-08-03 12:42:58 -07:00
Paul Stewart
e9e9ce49f9 Add independence to location of cros common.sh (will it move to bin/?)
BUG=none
TEST=reran script

Review URL: http://codereview.chromium.org/3064025
2010-07-30 17:50:16 -07:00
Nick Sanders
409703715b The current rekeying command is probably too complicated for ODMs to be happy with. I've added a script that wraps this.
I'd be OK just setting the defaults in the original command as well.

BUG=4246
TEST=ran it and image booted in normal mode.

Review URL: http://codereview.chromium.org/3008021
2010-07-23 16:55:28 -07:00
Paul Stewart
cfe2a1960c Fix move of shflags
BUG=verbal
TEST=Reran script

Review URL: http://codereview.chromium.org/3010008
2010-07-16 15:14:51 -07:00
Paul Stewart
335a8eb131 Add copyright and script description
BUG=none
TEST=Reran script looking for syntax errors

Review URL: http://codereview.chromium.org/2958009
2010-07-15 15:34:18 -07:00
Paul Stewart
bfe72ce842 Wrapper script around run_remote_tests that knows about test cells
This is a first pass.  I'll review this code myself and do more
testing, but I wanted to get folks a look at it to make sure I
was going in the right direction.

BUG=none
TEST=ran using both cell and hostname scenarios

Review URL: http://codereview.chromium.org/3007002
2010-07-15 15:32:46 -07:00
Paul Stewart
b3f323ed73 Clean up command line arguments and user output
Clean up command-line argument used to disable re-download of image bits down to the upgrade server.  This is now handed via a much more concise "--no_copy_archive" argument.  and user output output "fast restart" messages

Output information on how to run the "image_to_live.sh" client unconditionally (even if a client isn't being launched by this instance).

BUG=none
TEST=Reran commands, observed output

Review URL: http://codereview.chromium.org/2919009
2010-07-13 09:07:18 -07:00
Paul Stewart
bd2871a43a Fix duplicate sever-port bug
cros_copy_upgrade_server had a bug where it would always start servers
on port 8081 regrdless of whether that port was free.  This was a bug
in the "get next free port" code.

BUG=chromium-os:4776
TEST=Reran multiple instances at once, run netstat -nlt

Review URL: http://codereview.chromium.org/2975006
2010-07-13 07:59:15 -07:00
Gaurav Shah
561be04e50 Add a script to re-sign Chrome OS images with keys of our choosing.
Currently the output of build_image signs the kernel partition with the recovery keys on the final image. This script allows us to replace the kernel vblock and resign the kernel with the right set of keys (for example, using the normal boot path kernel keys, or the keys for factory install, etc.)

BUG=4623
TEST=Tested by running the script on one of the latest builbot images (801) and resigning with test kernel keys. The resulting image was dd-ed off to an SSD and was succesfully able to boot on one of our dev systems with our custom firmware with both dev mode and recovery mode turned off.

To test (can do outside chroot):

1) Download the latest image from the buildbot (I used build 801)
2) Run script with the following arguments and paths adjusted below

resign_image
 --from /path/to/chromiumos_image.bin \
 --datakey /path/to/vboot_reference/tests/devkeys/kernel_data_key.vbprivk \
 --keyblock /path/to/vboot_reference/tests/devkeys/kernel.keyblock \
 --vsubkey /path/to/vboot_reference/tests/devkeys/kernel_subkey.vbpubk \
 --vbutil_dir /path/to/vbutil/binaries
 --to image.out

This re-signs the image with the normal test keys (instead of recovery as done by build_image)

3) Copy the image to an SSD drive

dd if=image.out of=/dev/ssd [replace with the correct device]

4) Boot with the latest custom firmware in normal mode (recovery and dev mode turned off).
5) Profit!

Review URL: http://codereview.chromium.org/2938004
2010-07-09 18:33:39 -07:00
Kevin Degi
87336bdef6 Add scripts to update an existing image 2010-06-09 23:52:01 -07:00
Paul Stewart
7b7ccc7b0b Create a remote upgrade server to serve up images as a "proxy devserver". Uses devserver in "archive mode". This is useful in situations like the wireless test lab where the development machine is not accessible from the test machines.
Review URL: http://codereview.chromium.org/2724009
2010-06-09 16:22:23 -07:00