Commit Graph

12405 Commits

Author SHA1 Message Date
David Esparza
ba8a8fcbf2
Merge pull request #7442 from GabyCT/topic/addgofilesfio
metrics: Add FIO benchmark for metrics tests
2023-07-27 10:20:43 -06:00
ChengyuZhu6
57b932c127 kata-runtime: Add configurable image request timeout
Add ImageRequestTimeout field in the config struct, set RequestTimeout
by configured image request timeout, add image_request_timeout to
default configuration files, add image request timeout to annotations
and add image timeout annotation to sandbox config documentation.

exp:

configure the image request timout in the configuration:
[image]
image_request_timeout = 300

configure the image request timeout in the yaml:
annotations:
      "io.katacontainers.config.runtime.image_request_timeout": "300"

Fixes: #7389

Signed-off-by: ChengyuZhu6 <chengyu.zhu@intel.com>
2023-07-27 18:18:54 +02:00
Fabiano Fidêncio
e0bcb39ee7
Merge pull request #7471 from fidencio/topic/CCv0-converge-build-and-payload-scripts-follow-up-6
CC | kata-deploy: Add the runtime-classes that are not yet on main
2023-07-27 18:12:37 +02:00
Fabiano Fidêncio
03478ad064 kata-deploy: Add the runtime-classes that are not yet on main
This is another piece that got dropped as part of
6f552b010c and is causing regressions on
the operator tests.

Fixes: #7422

Signed-off-by: Fabiano Fidêncio <fabiano.fidencio@intel.com>
2023-07-27 17:02:18 +02:00
Zhongtao Hu
c8fcd29d9b runtime-rs: use device manager to handle virtio-pmem
use device manager to handle virtio-pmem device

Fixes: #7119
Signed-off-by: Zhongtao Hu <zhongtaohu.tim@linux.alibaba.com>
2023-07-27 20:18:49 +08:00
Zhongtao Hu
901c192251 runtime-rs: support configure vm_rootfs_driver
support configure vm_rootfs_driver in toml config

Fixes: #7119
Signed-off-by: Zhongtao Hu <zhongtaohu.tim@linux.alibaba.com>
2023-07-27 20:12:53 +08:00
Zhongtao Hu
5d6199f9bc runtime-rs: use device manager to handle vm rootfs
use device manager to handle vm rootfs, after attach the block device of
vm rootfs, we need to increase index number

Fixes: #7119
Signed-off-by: Zhongtao Hu <zhongtaohu.tim@linux.alibaba.com>
Signed-off-by: Chelsea Mafrica <chelsea.e.mafrica@intel.com>
Signed-off-by: James O. D. Hunt <james.o.hunt@intel.com>
2023-07-27 20:12:45 +08:00
James O. D. Hunt
20f1f62a2a runtime-rs: change block index to 0
Change block index in SharedInfo to 0 for vda.

Fixes #7119

Signed-off-by: Chelsea Mafrica <chelsea.e.mafrica@intel.com>
Signed-off-by: James O. D. Hunt <james.o.hunt@intel.com>
2023-07-27 20:11:44 +08:00
Chao Wu
ede1dae65d
Merge pull request #7465 from fidencio/topic/fix-dragonball-static-check-runner-selector
gha: dragonball: Run only on the dragonball labeled machine
2023-07-27 10:19:26 +08:00
Gabriela Cervantes
662f87539e metrics: Add general FIO makefile
This PR adds a general FIO makefile for kata metrics.

Signed-off-by: Gabriela Cervantes <gabriela.cervantes.tellez@intel.com>
2023-07-26 20:46:02 +00:00
Fabiano Fidêncio
f28af98ac6
Merge pull request #7453 from sprt/fix-ci-node-debugger
tests: Fix `k8s-job` test
2023-07-26 22:27:21 +02:00
Fabiano Fidêncio
8a22b5f075
Merge pull request #7439 from ManaSugi/fix/remove-unused-mut
agent,libs: Remove unused 'mut' keywords
2023-07-26 21:25:41 +02:00
Fabiano Fidêncio
9792ac49fe
Merge pull request #7425 from jongwu/remove_mut
runtime-rs: remove unneeded 'mut' keywords
2023-07-26 21:24:40 +02:00
Fabiano Fidêncio
24564a8499
Merge pull request #7455 from sprt/local-tests
tests: QoL improvements for running tests locally
2023-07-26 21:23:43 +02:00
Aurélien Bombo
c5a87eed29 tests: gha: Add timeout to cluster creation
This has been intermittently taking a while lately so let's add a
timeout.

Signed-off-by: Aurélien Bombo <abombo@microsoft.com>
2023-07-26 10:19:07 -07:00
Aurélien Bombo
6daeb08e69 tests: k8s: Clean up node debuggers after running
This deletes node debugger pods after execution since their presence may
affect tests that assume only test workloads pods are present.

For example, in `k8s-job` we wait for *any* pod to be in the `Succeeded`
state before proceeding, which causes failures.

Fixes: #7452

Signed-off-by: Aurélien Bombo <abombo@microsoft.com>
2023-07-26 10:19:07 -07:00
Fabiano Fidêncio
3aa6c77a01 gha: dragonball: Run only on the dragonball labeled machine
Static checks for dragonball are landing on any of the self-hosted
runners, and the reason for that is because "self-hosted" was the label
selector used.

Let's use "dragonball" instead, as the machine has that label as well.

Fixes: #7464

Signed-off-by: Fabiano Fidêncio <fabiano.fidencio@intel.com>
2023-07-26 18:15:04 +02:00
Gabriela Cervantes
37641a5430 metrics: Add example config for fio jobs
This PR adds example config for fio jobs.

Signed-off-by: Gabriela Cervantes <gabriela.cervantes.tellez@intel.com>
2023-07-26 16:03:12 +00:00
Fabiano Fidêncio
61cbae6c39
Merge pull request #7463 from fidencio/topic/CCv0-converge-build-and-payload-scripts-follow-up-5
cc: kata-deploy: Configure cri-handler="cc"
2023-07-26 14:00:28 +02:00
Fabiano Fidêncio
e35b4cc9fb
Merge pull request #7461 from jepio/kata-deploy-make-exec
CC | kata-deploy: Add executable bit to script
2023-07-26 13:00:25 +02:00
Fabiano Fidêncio
eff98f5795 cc: kata-deploy: Configure cri-handler="cc"
This has been mistakenly dropped as part of
441399df1f

Fixes: #7422

Signed-off-by: Fabiano Fidêncio <fabiano.fidencio@intel.com>
2023-07-26 12:57:03 +02:00
Jeremi Piotrowski
5ae7a74846 kata-deploy: Add executable bit to script
We need the executable bit set because it is preserved into the
runtime-payload-ci image.

Fixes: #7460
Signed-off-by: Jeremi Piotrowski <jpiotrowski@microsoft.com>
2023-07-26 12:07:37 +02:00
Hyounggyu Choi
46f04d762f
Merge pull request #7448 from fidencio/topic/CCv0-converge-build-and-payload-scripts-follow-up-4
cc: cache: shim-v2: Re-enable cached artefact
2023-07-26 08:18:53 +02:00
Alakesh Haloi
314aec73d4 agent: fix typo in constant
It fixes a constant name to have the right spelling

Fixes: #7457
Signed-off-by: Alakesh Haloi <a_haloi@apple.com>
2023-07-26 00:06:34 -05:00
Aurélien Bombo
4703434b12 tests: k8s: Allow using custom resource group
This simply allows setting a custom resource group when debugging
locally, so as to prevent name collisions and not pollute the namespace.

Signed-off-by: Aurélien Bombo <abombo@microsoft.com>
2023-07-25 15:45:44 -07:00
Aurélien Bombo
350f3f70b7 tests: Import common.bash in run_kubernetes_tests.sh
Not sure why this works in GHA, but the `info` call on line 65 would
fail locally.

Signed-off-by: Aurélien Bombo <abombo@microsoft.com>
2023-07-25 15:45:44 -07:00
Aurélien Bombo
d7f04a64a0 tests: k8s: Leave runtimeclass_workloads/ alone
Makes it so that `setup.sh` doesn't make changes in
`runtimeclass_workloads/` directly. Instead we treat that as a template
directory and we use the new directory `runtimeclass_workloads_work/` as
a work dir.

This has two advantages:

 * Allows rerunning tests without the assumption that `setup.sh` must be
   idempotent. E.g. the `set_runtime_class()` step would break.
 * Doesn't pollute your git environment with a bunch of changes when
   developing.

Signed-off-by: Aurélien Bombo <abombo@microsoft.com>
2023-07-25 15:45:44 -07:00
Aurélien Bombo
bdde6aa948 tests: k8s: Split deployment and testing commands
This splits deploying Kata and running the tests into separate commands
to make it possible to rerun tests locally without having to redeploy
Kata each time.

Signed-off-by: Aurélien Bombo <abombo@microsoft.com>
2023-07-25 15:44:46 -07:00
Aurélien Bombo
91a0b3b406 tests: aks: Simply delete cluster when cleaning up
If we're going to delete the cluster anyway, no need to call
kata-cleanup.

Fixes: #7454

Signed-off-by: Aurélien Bombo <abombo@microsoft.com>
2023-07-25 15:44:46 -07:00
Fabiano Fidêncio
9ea161577f
Merge pull request #7450 from BbolroC/fix-prefix-to-kata
CCv0: fix a prefix to kata for IBM SE image build
2023-07-26 00:23:40 +02:00
Hyounggyu Choi
a578266b26 CCv0: fix prefix to kata for IBM SE image build
This is to change a prefix from `confidential-containers` to `kata` for IBM SE image build.

Fixes: #7444

Signed-off-by: Hyounggyu Choi <Hyounggyu.Choi@ibm.com>
2023-07-25 22:54:18 +02:00
Gabriela Cervantes
3c1044d9d5 metrics: Update FIO paths for k8s runner
This PR updates the FIO paths for k8s runner.

Signed-off-by: Gabriela Cervantes <gabriela.cervantes.tellez@intel.com>
2023-07-25 20:50:03 +00:00
Hyounggyu Choi
78262695d2
Merge pull request #7445 from BbolroC/remove-cc-from-kernel-ibm-se
CCv0: Remove `cc` from kernel for IBM SE image build
2023-07-25 21:52:01 +02:00
Fabiano Fidêncio
f6197f60b4 cc: cache: shim-v2: Re-enable cached artefact
Now that the shim-v2 for CCv0 has been rebuilt with the correct path,
let's re-enable the cache.

Fixes: #7422

Signed-off-by: Fabiano Fidêncio <fabiano.fidencio@intel.com>
2023-07-25 21:48:20 +02:00
Fabiano Fidêncio
ce926439f0
Merge pull request #7443 from fidencio/topic/CCv0-converge-build-and-payload-scripts-follow-up-3
CC| cc: cache: Enable more cached components back and ensure shim-v2 can be properly cached
2023-07-25 20:32:02 +02:00
Eric Ernst
5385ddc560
Merge pull request #7365 from alakesh/symlink-fix
agent: exclude symlinks from recursive ownership change
2023-07-25 11:27:48 -07:00
Gabriela Cervantes
6177a0db3e metrics: Add env files for FIO
This PR adds the env files for FIO for kata metrics.

Signed-off-by: Gabriela Cervantes <gabriela.cervantes.tellez@intel.com>
2023-07-25 17:48:45 +00:00
Hyounggyu Choi
1093e71cc5 CCv0: Remove cc from kernel for IBM SE image build
This is a quick fix for the error on IBM SE image build.

Fixes: #7444

Signed-off-by: Hyounggyu Choi <Hyounggyu.Choi@ibm.com>
2023-07-25 19:46:31 +02:00
Gabriela Cervantes
a45900324d metrics: Add fio exec
This PR adds fio exec for the FIO benchmark.

Signed-off-by: Gabriela Cervantes <gabriela.cervantes.tellez@intel.com>
2023-07-25 17:36:08 +00:00
Gabriela Cervantes
ea198fddcc metrics: Add FIO runner k8s
Add program to execute FIO workloads using k8s.

Signed-off-by: Gabriela Cervantes <gabriela.cervantes.tellez@intel.com>
2023-07-25 17:34:29 +00:00
Gabriela Cervantes
8f7ef41c14 metrics: Add FIO vendor code
This PR adds the FIO vendor code.

Signed-off-by: Gabriela Cervantes <gabriela.cervantes.tellez@intel.com>
2023-07-25 17:24:29 +00:00
Gabriela Cervantes
6293c17bde metrics: Add FIO benchmark for metrics tests
This PR adds the FIO benchmark scripts and resources for the metrics
tests section.

Fixes #7441

Signed-off-by: Gabriela Cervantes <gabriela.cervantes.tellez@intel.com>
2023-07-25 16:36:33 +00:00
Fabiano Fidêncio
ad8c96b6c0 cc: cache: Enable more cached components after rebuild was done
Let's re-enabled caching for the following components, as those were
rebuilt with the new prefix:
* cc-rootfs-image
* cc-rootfs-initrd
* cc-tdx-rootfs-image
* cc-tdx-td-shim
* cc-sev-rootfs-initrd

"cc-se-image" was part of the list, but we never had a target for it.

Signed-off-by: Fabiano Fidêncio <fabiano.fidencio@intel.com>
2023-07-25 18:33:27 +02:00
Fabiano Fidêncio
2213660bf3 cc: cache: shim-v2: Allow root_hashes to be downloaded
We should not return, in case cache is not used, before actually
downloading the root_hash_*.txt provided by the other components,
otherwise the job used to do the caching will always fail.

Fixes: #7422

Signed-off-by: Fabiano Fidêncio <fabiano.fidencio@intel.com>
2023-07-25 18:33:27 +02:00
Fabiano Fidêncio
7f1226ae2b
Merge pull request #7440 from fidencio/topic/CCv0-converge-build-and-payload-scripts-follow-up-2
CC | Adjust cache URL for TDX components
2023-07-25 18:33:08 +02:00
Fabiano Fidêncio
cdf04e5018
Merge pull request #7437 from jepio/fix-sev-kernel-cache
cache: kernel: Fix kernel caching
2023-07-25 18:10:03 +02:00
GabyCT
7a3b55ce67
Merge pull request #7432 from ManaSugi/runk/doc-docker
runk: Add Docker guide to README
2023-07-25 09:56:02 -06:00
GabyCT
c1bd527163
Merge pull request #7430 from GabyCT/topic/fixjson
metrics: General improvements to json.bash script
2023-07-25 09:45:53 -06:00
Fabiano Fidêncio
6efd684a46
Merge pull request #7408 from fidencio/topic/kata-deploy-add-SHIMS-and-SHIM_DEFAULT-as-env
kata-deploy: Allow shim creation based on what's passed to the daemonset
2023-07-25 16:56:46 +02:00
Fabiano Fidêncio
5b82268d2c
Merge pull request #7436 from jepio/vfio-gha
gha: ci: Add skeleton of vfio job
2023-07-25 14:44:04 +02:00