mirror of
https://github.com/podman-container-tools/podman.git
synced 2026-08-13 12:19:36 +00:00
ci: Use the GitHub action grouping syntax
This groups log output in the github UI and makes it easier to just show the actual test results, the groups are hidden under an extra drop down and only shown when selected. Inspired by Miloslav container-libs change for this. Signed-off-by: Paul Holzinger <pholzing@redhat.com>
This commit is contained in:
parent
66c6da6e84
commit
784f70980d
2 changed files with 11 additions and 8 deletions
|
|
@ -20,6 +20,7 @@ IMAGE_URL="https://objectstorage.us-ashburn-1.oraclecloud.com/n/id0lmbbwgcdv/b/p
|
|||
|
||||
trap "limactl delete --force $LIMA_VM_NAME" EXIT
|
||||
|
||||
echo "::group::Starting VM"
|
||||
limactl --yes start --plain --name=$LIMA_VM_NAME --cpus $(nproc) --memory 8 --nested-virt \
|
||||
--set ".images=[{\"location\":\"$IMAGE_URL\", \"arch\": \"x86_64\"}]" \
|
||||
"$SCRIPT_DIR/template.lima.yml"
|
||||
|
|
@ -28,12 +29,16 @@ limactl shell $LIMA_VM_NAME mkdir -p /var/tmp/podman-container-tools
|
|||
|
||||
limactl copy "$REPO_DIR" $LIMA_VM_NAME:/var/tmp/podman-container-tools/podman
|
||||
|
||||
echo "::endgroup::"
|
||||
|
||||
set +e
|
||||
|
||||
limactl shell --preserve-env --workdir /var/tmp/podman-container-tools/podman $LIMA_VM_NAME ./hack/ci/runner.sh "${@}"
|
||||
rc=$?
|
||||
|
||||
echo "::group::Collecting logs"
|
||||
limactl copy $LIMA_VM_NAME:/var/tmp/podman-container-tools/podman/hack/ci/logs/ $SCRIPT_DIR/logs
|
||||
echo "::endgroup::"
|
||||
|
||||
# TODO: figure out how to cache the binaries from the build job to the actual test tasks
|
||||
# Copy the binaries out of the VM in gh actions so we can upload them as artifact
|
||||
|
|
|
|||
|
|
@ -9,6 +9,8 @@ SCRIPT_DIR=$(cd -- "$(dirname -- "${BASH_SOURCE[0]}")" && pwd)
|
|||
|
||||
source "$SCRIPT_DIR/lib.sh"
|
||||
|
||||
echo "::group::Test Setup"
|
||||
|
||||
parse_args "$@"
|
||||
|
||||
PRESERVE_ENVS="CI_USE_REGISTRY_CACHE,CI_DESIRED_COMPOSEFS,OCI_RUNTIME,CGROUP_MANAGER,STORAGE_FS,STORAGE_OPTIONS_OVERLAY,STORAGE_OPTIONS_VFS,PODMAN_UPGRADE_FROM"
|
||||
|
|
@ -127,15 +129,14 @@ fi
|
|||
$SUDO git config --global user.name "Podman CI"
|
||||
$SUDO git config --global user.email "no-reply@podman.io"
|
||||
|
||||
echo "::endgroup::" # Test Setup
|
||||
|
||||
### LOG various relevant things
|
||||
|
||||
echo
|
||||
echo "#################"
|
||||
echo "Setup complete, logging versions"
|
||||
echo "#################"
|
||||
|
||||
echo "::group::Logging system info"
|
||||
"$SCRIPT_DIR/logcollector.sh" packages
|
||||
"$SCRIPT_DIR/logcollector.sh" ip
|
||||
echo "::endgroup::" # Logging system info
|
||||
|
||||
mkdir -p "$SCRIPT_DIR/logs"
|
||||
# Log the journal at the end.
|
||||
|
|
@ -228,9 +229,6 @@ function run_machine() {
|
|||
$SUDO make ${MODE}machine
|
||||
}
|
||||
|
||||
echo
|
||||
echo "#################"
|
||||
echo "Starting Test"
|
||||
echo "#################"
|
||||
|
||||
run_$TEST
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue