summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJim Hebert <jimhebert@chromium.org>2011-02-16 11:23:46 -0800
committerJim Hebert <jimhebert@chromium.org>2011-02-16 11:23:46 -0800
commit686dd5cefb172968b8491a941d124fbfeefe230f (patch)
treee57a585e6d5f307d676cd35afeb079314afce253
parent1a4620e9e3d45946a31e70407abb809327f88766 (diff)
downloadvboot-686dd5cefb172968b8491a941d124fbfeefe230f.tar.gz
Check in sample configs to document how to configure these tests.
Change-Id: I1c82426854d48f23bdf7c08ae5e37cd965a08089 BUG=chrome-os-partner:1991 TEST=Run the corresponding test scripts with these config files. Works. Review URL: http://codereview.chromium.org/6480121
-rw-r--r--scripts/image_signing/sample-test-configs/README4
-rwxr-xr-xscripts/image_signing/sample-test-configs/ensure_no_nonrelease_files.config (renamed from scripts/image_signing/ensure_no_nonrelease_files.config)0
-rw-r--r--scripts/image_signing/sample-test-configs/ensure_sane_lsb-release.config25
-rwxr-xr-xscripts/image_signing/sample-test-configs/ensure_secure_kernelparams.config38
4 files changed, 67 insertions, 0 deletions
diff --git a/scripts/image_signing/sample-test-configs/README b/scripts/image_signing/sample-test-configs/README
new file mode 100644
index 00000000..d60ad3d1
--- /dev/null
+++ b/scripts/image_signing/sample-test-configs/README
@@ -0,0 +1,4 @@
+These are sample configurations used with the test scripts located in the
+parent directory. Note that these are not maintained in this git with complete
+or necessarily current production data for Chrome OS. They serve to provide
+examples of the configuraiton syntax.
diff --git a/scripts/image_signing/ensure_no_nonrelease_files.config b/scripts/image_signing/sample-test-configs/ensure_no_nonrelease_files.config
index 1ca02f1a..1ca02f1a 100755
--- a/scripts/image_signing/ensure_no_nonrelease_files.config
+++ b/scripts/image_signing/sample-test-configs/ensure_no_nonrelease_files.config
diff --git a/scripts/image_signing/sample-test-configs/ensure_sane_lsb-release.config b/scripts/image_signing/sample-test-configs/ensure_sane_lsb-release.config
new file mode 100644
index 00000000..6811a018
--- /dev/null
+++ b/scripts/image_signing/sample-test-configs/ensure_sane_lsb-release.config
@@ -0,0 +1,25 @@
+#!/bin/bash
+
+# Copyright (c) 2011 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.
+
+expected_auserver="https://tools.google.com/service/update2"
+expected_release_name="Chrome OS"
+
+# List boards here
+expected_boards=(
+ x86-mario
+)
+
+# List track names here
+expected_release_tracks=(
+ beta-channel
+ dev-channel
+)
+
+# Associate board names with APPID's by creating a series
+# of variables here. Variables should be named based on
+# expected boards (above), with hyphens transposed to
+# underscores (to be legal in variable names).
+expected_appid_x86_mario="{87efface-864d-49a5-9bb3-4b050a7c227a}"
diff --git a/scripts/image_signing/sample-test-configs/ensure_secure_kernelparams.config b/scripts/image_signing/sample-test-configs/ensure_secure_kernelparams.config
new file mode 100755
index 00000000..c74bb0e3
--- /dev/null
+++ b/scripts/image_signing/sample-test-configs/ensure_secure_kernelparams.config
@@ -0,0 +1,38 @@
+#!/bin/bash
+
+# Copyright (c) 2011 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.
+
+#
+# COMMON
+#
+required_kparams_common=( quiet console=tty2 init=/sbin/init add_efi_memmap
+ boot=local rootwait ro noresume noswap i915.modeset=1
+ loglevel=1 cros_secure kern_guid=%U tpm_tis.force=1
+ tpm_tis.interrupts=0 root=/dev/dm-0
+ dm_verity.error_behavior=3 dm_verity.max_bios=-1
+ dm_verity.dev_wait=1 noinitrd )
+
+optional_kparams_common=( )
+
+# use "MAGIC_HASH" in place of the unpredictable sha1 hash, comparison
+# functions later take care of the rest.... This set of dmparams
+# taken from observation of current builds. In particular we may see
+# the size of the filesystem creep over time. That size is denoted by
+# the large number that appears a couple times in this string.
+required_dmparams_common="vroot none ro,0 1740800 verity /dev/sd%D%P \
+/dev/sd%D%P 1740800 1 sha1 MAGIC_HASH"
+
+
+#
+# x86-mario
+#
+required_kparams_x86_mario=( ${required_kparams_common[@]} )
+optional_kparams_x86_mario=( ${optional_kparams_common[@]} )
+required_dmparams_x86_mario="$required_dmparams_common"
+
+# Set up additional boards here. The "common" variables are
+# not directly consulted by the test script, they're only
+# here for your convenience in building up the board-specific
+# configuration variables like the 3 shown above.