Merge pull request #9992 from sprt/fix-nydus

ci: fix run-nydus tests
This commit is contained in:
GabyCT 2024-07-10 13:56:16 -06:00 committed by GitHub
commit c40b3b4ce7
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 5 additions and 5 deletions

View File

@ -176,11 +176,6 @@ function extract_kata_env() {
RUNTIME_PATH="$(echo "${kata_env}" | jq -r ${runtime_path})"
SHARED_FS="$(echo "${kata_env}" | jq -r ${shared_fs})"
# get_kata_memory_and_vcpus() function measures the memory and the number of vcpus
# from a kata container, and saves these values in the variables:
# 'MEASURED_CONTAINER_NUM_VCPUS' and 'MEASURED_CONTAINER_TOTAL_MEM'
get_kata_memory_and_vcpus
# get the requested memory and num of vcpus from the kata config file.
config_content="$(cat ${RUNTIME_CONFIG_PATH} | grep -vE "^#")"
REQ_MEMORY="$(echo "${config_content}" | grep -i default_memory | cut -d "=" -f2 | awk '{print $1}')"

View File

@ -43,6 +43,11 @@ function metrics_json_init() {
despaced_name="$(echo ${TEST_NAME} | sed 's/[ \/]/-/g')"
json_filename="${RESULT_DIR}/${despaced_name}.json"
# get_kata_memory_and_vcpus() function measures the memory and the number of vcpus
# from a kata container, and saves these values in the variables:
# 'MEASURED_CONTAINER_NUM_VCPUS' and 'MEASURED_CONTAINER_TOTAL_MEM'
get_kata_memory_and_vcpus
local json="$(cat << EOF
"@timestamp" : $(timestamp_ms)
EOF