Luis Hector Chavez | dca9dd7 | 2018-06-12 19:56:30 | [diff] [blame] | 1 | # -*- coding: utf-8 -*- |
Chris Sosa | 76e44b9 | 2013-01-31 20:11:38 | [diff] [blame] | 2 | # Copyright (c) 2013 The Chromium OS Authors. All rights reserved. |
| 3 | # Use of this source code is governed by a BSD-style license that can be |
| 4 | # found in the LICENSE file. |
| 5 | |
| 6 | """Module contains a list of artifact name related constants and methods.""" |
| 7 | |
| 8 | ############ Artifact Names ############ |
| 9 | |
Chris Sosa | 6b0c617 | 2013-08-06 00:01:33 | [diff] [blame] | 10 | # Note these are the available 'artifacts' that are known to the devserver. If |
| 11 | # you just need to stage a file from gs directly, use the files api. See the |
| 12 | # stage documentation for more info. |
| 13 | |
Chris Sosa | 76e44b9 | 2013-01-31 20:11:38 | [diff] [blame] | 14 | #### Update payload names. #### |
| 15 | |
| 16 | # The name of artifact to stage a full update payload. |
| 17 | FULL_PAYLOAD = 'full_payload' |
| 18 | |
| 19 | # The name of the artifact to stage all delta payloads for a build. |
| 20 | DELTA_PAYLOADS = 'delta_payloads' |
| 21 | |
| 22 | # The payload containing stateful data not stored on the rootfs of the image. |
| 23 | STATEFUL_PAYLOAD = 'stateful' |
| 24 | |
| 25 | #### The following are the names of images to stages. #### |
| 26 | |
| 27 | # The base image i.e. the image without any test/developer enhancements. |
| 28 | BASE_IMAGE = 'base_image' |
| 29 | |
| 30 | # The recovery image - the image used to recover a chromiumos device. |
| 31 | RECOVERY_IMAGE = 'recovery_image' |
| 32 | |
Luis Hector Chavez | dca9dd7 | 2018-06-12 19:56:30 | [diff] [blame] | 33 | # The image that has been signed and can be pushed to regular Chrome OS users. |
| 34 | SIGNED_IMAGE = 'signed_image' |
| 35 | |
Chris Sosa | 76e44b9 | 2013-01-31 20:11:38 | [diff] [blame] | 36 | # The test image - the base image with both develolper and test enhancements. |
| 37 | TEST_IMAGE = 'test_image' |
| 38 | |
Chris Sosa | 7549080 | 2013-10-01 00:21:45 | [diff] [blame] | 39 | # The developer image - the base image with developer enhancements. |
| 40 | DEV_IMAGE = 'dev_image' |
| 41 | |
David Riley | 0655bab | 2017-11-02 17:44:26 | [diff] [blame] | 42 | # The name of artifact to stage a quick provision payload. |
| 43 | QUICK_PROVISION = 'quick_provision' |
| 44 | |
Chris Sosa | 76e44b9 | 2013-01-31 20:11:38 | [diff] [blame] | 45 | #### Autotest related packages. #### |
| 46 | |
| 47 | # Autotest -- the main autotest directory without the test_suites subdir. |
| 48 | AUTOTEST = 'autotest' |
| 49 | |
Simran Basi | ea0590d | 2014-10-29 18:31:26 | [diff] [blame] | 50 | # Control Files -- the autotest control files without the test_suites subdir. |
| 51 | CONTROL_FILES = 'control_files' |
| 52 | |
| 53 | # Autotest Packages-- the autotest packages subdirectory. |
| 54 | AUTOTEST_PACKAGES = 'autotest_packages' |
| 55 | |
Simran Basi | 6459bba | 2015-02-04 22:47:23 | [diff] [blame] | 56 | # Autotest Server Package. |
| 57 | AUTOTEST_SERVER_PACKAGE = 'autotest_server_package' |
| 58 | |
Chris Sosa | 76e44b9 | 2013-01-31 20:11:38 | [diff] [blame] | 59 | # Test Suites - just the test suites control files from the autotest directory. |
| 60 | TEST_SUITES = 'test_suites' |
| 61 | |
| 62 | # AU Suite - The control files for the autotest autoupdate suite. |
| 63 | AU_SUITE = 'au_suite' |
| 64 | |
Chris Sosa | 968a106 | 2013-08-03 00:42:50 | [diff] [blame] | 65 | # AU Suite - The control files for the paygen autoupdate suite (depends |
| 66 | # on channel defined in devserver_constants). |
| 67 | PAYGEN_AU_SUITE_TEMPLATE = 'paygen_au_%(channel)s_suite' |
Chris Sosa | 5d1b079 | 2013-07-31 17:54:52 | [diff] [blame] | 68 | |
Chris Sosa | 76e44b9 | 2013-01-31 20:11:38 | [diff] [blame] | 69 | #### Miscellaneous artifacts. #### |
| 70 | |
| 71 | # Firmware tarball. |
| 72 | FIRMWARE = 'firmware' |
| 73 | |
| 74 | # Tarball containing debug symbols for the given build. |
| 75 | SYMBOLS = 'symbols' |
| 76 | |
Dan Shi | 55d0f97 | 2016-10-04 18:45:00 | [diff] [blame] | 77 | # A compressed tarball containing only sym files of debug symbols for the |
| 78 | # given build. |
| 79 | SYMBOLS_ONLY = 'symbols_only' |
| 80 | |
beeps | c3d0f87 | 2013-08-01 04:50:40 | [diff] [blame] | 81 | # The factory test image. |
| 82 | FACTORY_IMAGE = 'factory_image' |
Chris Sosa | 76e44b9 | 2013-01-31 20:11:38 | [diff] [blame] | 83 | |
Mike Frysinger | a0e6a28 | 2016-09-01 21:29:08 | [diff] [blame] | 84 | # The factory shim image. |
| 85 | FACTORY_SHIM_IMAGE = 'factory_shim_image' |
| 86 | |
Justin Giorgi | b759052 | 2017-02-07 21:36:24 | [diff] [blame] | 87 | #### Libiota Artifacts. These are in the same namespace as the above. #### |
| 88 | |
| 89 | # Archive with test binaries for flashing to the DUT. |
| 90 | LIBIOTA_TEST_BINARIES = 'libiota_test_binaries' |
| 91 | |
| 92 | # Utilities required for managing the DUT. |
| 93 | LIBIOTA_BOARD_UTILS = 'libiota_board_utils' |
| 94 | |
Gabe Black | 3b56720 | 2015-09-23 21:07:59 | [diff] [blame] | 95 | #### Android artifacts. These are in a different namespace from the above. #### |
| 96 | |
| 97 | # Various android images stored in a zip file (including boot and system). |
| 98 | # For example, shamu-img-2284311.zip contains boot.img, cache.img, recovery.img, |
| 99 | # system.img and userdata.img. fastboot can use the zip file to update the dut |
| 100 | # in a single command. Therefore, devserver does not unzip the zip file to avoid |
| 101 | # unnecessary load on the devserver. |
| 102 | ANDROID_ZIP_IMAGES = 'zip_images' |
| 103 | |
| 104 | # Radio image. |
| 105 | ANDROID_RADIO_IMAGE = 'radio_image' |
| 106 | |
| 107 | # Bootloader image. |
| 108 | ANDROID_BOOTLOADER_IMAGE = 'bootloader_image' |
| 109 | |
| 110 | # fastboot, utility to flash image to Android device. |
| 111 | ANDROID_FASTBOOT = 'fastboot' |
| 112 | |
| 113 | # Test zip file for Android build, e.g., shamu-tests-2284311.zip |
| 114 | ANDROID_TEST_ZIP = 'test_zip' |
| 115 | |
Dan Shi | 74136ae | 2015-12-01 22:40:06 | [diff] [blame] | 116 | # Zip file of vendor partitions used by Brillo device. |
| 117 | ANDROID_VENDOR_PARTITION_ZIP = 'vendor_partitions' |
| 118 | |
Simran Basi | 05be721 | 2016-03-16 20:08:23 | [diff] [blame] | 119 | # Zip file of native tests used by Android devices. |
| 120 | ANDROID_NATIVETESTS_ZIP = 'nativetests' |
Ralph Nathan | 6c7fe5e | 2016-06-22 22:50:10 | [diff] [blame] | 121 | ANDROID_CONTINUOUS_NATIVE_TESTS_ZIP = 'continuous_native_tests' |
Justin Giorgi | bb32ac4 | 2016-08-04 17:34:35 | [diff] [blame] | 122 | ANDROID_CONTINUOUS_INSTRUMENTATION_TESTS_ZIP = ( |
| 123 | 'continuous_instrumentation_tests') |
Justin Giorgi | 4faa890 | 2016-08-20 02:54:30 | [diff] [blame] | 124 | ANDROID_CTS_ZIP = 'android-cts' |
Simran Basi | 05be721 | 2016-03-16 20:08:23 | [diff] [blame] | 125 | |
Justin Giorgi | 576c154 | 2016-06-24 15:24:20 | [diff] [blame] | 126 | # Zip file including all target files and images |
| 127 | ANDROID_TARGET_FILES_ZIP = 'target_files' |
| 128 | |
| 129 | # Zip file containing DTB for emulators |
| 130 | ANDROID_DTB_ZIP = 'dtb' |
| 131 | |
Satoshi Niwa | 5e3ed5e | 2018-06-25 07:03:33 | [diff] [blame] | 132 | # Zip file containing push_to_device.py and tools it depends on |
| 133 | ANDROID_PUSH_TO_DEVICE_ZIP = 'push_to_device_zip' |
| 134 | |
Qijiang Fan | 31beb7f | 2018-06-26 08:09:00 | [diff] [blame] | 135 | # Zip file containing selinux policy files. |
| 136 | ANDROID_SEPOLICY_ZIP = 'sepolicy.zip' |
| 137 | |
Chris Sosa | 76e44b9 | 2013-01-31 20:11:38 | [diff] [blame] | 138 | # In general, downloading one artifact usually indicates that the caller will |
| 139 | # want to download other artifacts later. The following map explicitly defines |
| 140 | # this relationship. Specifically: |
| 141 | # If X is requested, all items in Y should also get triggered for download. |
Dan Shi | 6c2b2a2 | 2016-03-04 23:52:19 | [diff] [blame] | 142 | CROS_REQUESTED_TO_OPTIONAL_MAP = { |
Simran Basi | 4243a86 | 2014-12-12 20:48:33 | [diff] [blame] | 143 | TEST_SUITES: [CONTROL_FILES, AUTOTEST_PACKAGES], |
Chris Sosa | 76e44b9 | 2013-01-31 20:11:38 | [diff] [blame] | 144 | } |
Dan Shi | 6c2b2a2 | 2016-03-04 23:52:19 | [diff] [blame] | 145 | # Launch Control builds do not support autotest package. |
| 146 | ANDROID_REQUESTED_TO_OPTIONAL_MAP = { |
| 147 | TEST_SUITES: [CONTROL_FILES], |
| 148 | } |
Dan Shi | 2f13686 | 2016-02-11 23:38:38 | [diff] [blame] | 149 | |
| 150 | # Map between the artifact name and the folder after it's unzipped. |
| 151 | ARTIFACT_UNZIP_FOLDER_MAP = { |
| 152 | ANDROID_TEST_ZIP: 'DATA', |
| 153 | } |