c9f7743ae1
For debugging patching, we need an additional ostree command output to be captured for the feed ostree repos - "ostree summary -v --repo=<feed repo>. This commit adds this ostree command to the collect tool. Test plan: [PASS] ostree summary is collected for feed ostree repo Story: 2009969 Task: 46992 Signed-off-by: Jessica Castelino <jessica.castelino@windriver.com> Change-Id: I5021ba9948c84e8f7e5832b4a62714a69a4b2923
56 lines
1.9 KiB
Bash
56 lines
1.9 KiB
Bash
#! /bin/bash
|
|
#
|
|
# Copyright (c) 2022 Wind River Systems, Inc.
|
|
#
|
|
# SPDX-License-Identifier: Apache-2.0
|
|
#
|
|
|
|
# Loads Up Utilities and Commands Variables
|
|
|
|
source /usr/local/sbin/collect_parms
|
|
source /usr/local/sbin/collect_utils
|
|
|
|
SERVICE="ostree"
|
|
LOGFILE="${extradir}/${SERVICE}.info"
|
|
|
|
SYSROOT_REPO="/sysroot/ostree/repo"
|
|
FEED_OSTREE_BASE_DIR="/var/www/pages/feed"
|
|
OSTREE_REF="starlingx"
|
|
|
|
echo "${hostname}: OSTREE Info .......: ${LOGFILE}"
|
|
###############################################################################
|
|
# OSTREE Info:
|
|
###############################################################################
|
|
|
|
|
|
###############################################################################
|
|
# ostree admin status (deployment)
|
|
# -v outputs additional data to stderr
|
|
###############################################################################
|
|
delimiter ${LOGFILE} "ostree admin status -v"
|
|
ostree admin status -v >> ${LOGFILE} 2>&1
|
|
|
|
###############################################################################
|
|
# ostree logs for the sysroot and patch feeds
|
|
###############################################################################
|
|
delimiter ${LOGFILE} "ostree log ${OSTREE_REF} --repo=${SYSROOT_REPO}"
|
|
ostree log ${OSTREE_REF} --repo=${SYSROOT_REPO} >> ${LOGFILE} 2>>${COLLECT_ERROR_LOG}
|
|
|
|
for feed_dir in ${FEED_OSTREE_BASE_DIR}/*/ostree_repo
|
|
do
|
|
delimiter ${LOGFILE} "ostree log ${OSTREE_REF} --repo=${feed_dir}"
|
|
ostree log ${OSTREE_REF} --repo=${feed_dir} >> ${LOGFILE} 2>>${COLLECT_ERROR_LOG}
|
|
done
|
|
|
|
###############################################################################
|
|
# ostree repo summary for the feed ostrees
|
|
###############################################################################
|
|
|
|
for feed_dir in ${FEED_OSTREE_BASE_DIR}/*/ostree_repo
|
|
do
|
|
delimiter ${LOGFILE} "ostree summary -v --repo=${feed_dir}"
|
|
ostree summary -v --repo=${feed_dir} >> ${LOGFILE} 2>>${COLLECT_ERROR_LOG}
|
|
done
|
|
|
|
exit 0
|