mirror of
https://github.com/kata-containers/kata-containers.git
synced 2025-05-05 15:07:31 +00:00
some of the e2e tests spawn a lot of workers which are mainly idle, but the scheduler fails to schedule them due to cpu resource overcommit. For our testing we are more focused on having actual pods running than the speed of the scheduled pods so let's increase the amount of schedulable pods by decreasing the default cpu requests. Signed-off-by: Lukáš Doktor <ldoktor@redhat.com>
37 lines
935 B
Bash
Executable File
37 lines
935 B
Bash
Executable File
#!/bin/bash
|
|
#
|
|
# Copyright (c) 2020 Red Hat, Inc.
|
|
#
|
|
# SPDX-License-Identifier: Apache-2.0
|
|
#
|
|
|
|
# The kata shim to be used
|
|
export KATA_RUNTIME=${KATA_RUNTIME:-kata-qemu}
|
|
|
|
script_dir=$(dirname "$0")
|
|
# shellcheck disable=SC1091 # import based on variable
|
|
source "${script_dir}/lib.sh"
|
|
|
|
suite=$1
|
|
if [[ -z "$1" ]]; then
|
|
suite='smoke'
|
|
fi
|
|
|
|
# Make oc and kubectl visible
|
|
export PATH=/tmp/shared:${PATH}
|
|
|
|
oc version || die "Test cluster is unreachable"
|
|
|
|
info "Install and configure kata into the test cluster"
|
|
export SELINUX_PERMISSIVE="no"
|
|
"${script_dir}/cluster/install_kata.sh" || die "Failed to install kata-containers"
|
|
|
|
info "Overriding KATA_RUNTIME cpu resources"
|
|
oc patch "runtimeclass/${KATA_RUNTIME}" -p '{"overhead": {"podFixed": {"cpu": "50m"}}}'
|
|
|
|
info "Run test suite: ${suite}"
|
|
test_status='PASS'
|
|
"${script_dir}/run_${suite}_test.sh" || test_status='FAIL'
|
|
info "Test suite: ${suite}: ${test_status}"
|
|
[[ "${test_status}" == "PASS" ]]
|