Merge pull request #773 from bgilbert/kconfig

build_library: upload kernel config as release artifact
This commit is contained in:
Benjamin Gilbert 2017-11-09 12:34:31 -08:00 committed by GitHub
commit 243d565c73
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 11 additions and 1 deletions

View File

@ -425,6 +425,7 @@ finish_image() {
local pcr_policy="$6" local pcr_policy="$6"
local image_grub="$7" local image_grub="$7"
local image_shim="$8" local image_shim="$8"
local image_kconfig="$9"
local install_grub=0 local install_grub=0
local disk_img="${BUILD_DIR}/${image_name}" local disk_img="${BUILD_DIR}/${image_name}"
@ -500,6 +501,11 @@ EOF
"system-cloudinit@.service" "system-cloudinit@${unit_path}.service" "system-cloudinit@.service" "system-cloudinit@${unit_path}.service"
fi fi
if [[ -n "${image_kconfig}" ]]; then
cp "${root_fs_dir}/usr/boot/config" \
"${BUILD_DIR}/${image_kconfig}"
fi
write_contents "${root_fs_dir}" "${BUILD_DIR}/${image_contents}" write_contents "${root_fs_dir}" "${BUILD_DIR}/${image_contents}"
# Zero all fs free space to make it more compressible so auto-update # Zero all fs free space to make it more compressible so auto-update

View File

@ -63,6 +63,7 @@ start_modify_image() {
"${pcr_data}" "${pcr_data}"
"${production_prefix}_contents.txt" "${production_prefix}_contents.txt"
"${production_prefix}_packages.txt" "${production_prefix}_packages.txt"
"${production_prefix}_kernel_config.txt"
"${COREOS_DEVELOPER_CONTAINER_NAME}" "${COREOS_DEVELOPER_CONTAINER_NAME}"
"${container_prefix}_contents.txt" "${container_prefix}_contents.txt"
"${container_prefix}_packages.txt" "${container_prefix}_packages.txt"

View File

@ -66,6 +66,7 @@ create_prod_image() {
local image_contents="${image_name%.bin}_contents.txt" local image_contents="${image_name%.bin}_contents.txt"
local image_packages="${image_name%.bin}_packages.txt" local image_packages="${image_name%.bin}_packages.txt"
local image_licenses="${image_name%.bin}_licenses.json" local image_licenses="${image_name%.bin}_licenses.json"
local image_kconfig="${image_name%.bin}_kernel_config.txt"
local image_kernel="${image_name%.bin}.vmlinuz" local image_kernel="${image_name%.bin}.vmlinuz"
local image_pcr_policy="${image_name%.bin}_pcr_policy.zip" local image_pcr_policy="${image_name%.bin}_pcr_policy.zip"
local image_grub="${image_name%.bin}.grub" local image_grub="${image_name%.bin}.grub"
@ -126,7 +127,8 @@ EOF
"${image_kernel}" \ "${image_kernel}" \
"${image_pcr_policy}" \ "${image_pcr_policy}" \
"${image_grub}" \ "${image_grub}" \
"${image_shim}" "${image_shim}" \
"${image_kconfig}"
# Upload # Upload
local to_upload=( local to_upload=(
@ -137,6 +139,7 @@ EOF
"${BUILD_DIR}/${image_kernel}" "${BUILD_DIR}/${image_kernel}"
"${BUILD_DIR}/${image_pcr_policy}" "${BUILD_DIR}/${image_pcr_policy}"
"${BUILD_DIR}/${image_grub}" "${BUILD_DIR}/${image_grub}"
"${BUILD_DIR}/${image_kconfig}"
) )
# FIXME(bgilbert): no shim on arm64 # FIXME(bgilbert): no shim on arm64
if [[ -f "${BUILD_DIR}/${image_shim}" ]]; then if [[ -f "${BUILD_DIR}/${image_shim}" ]]; then