Commit Graph

12769 Commits

Author SHA1 Message Date
Alex Lyn
51a82bec3c
Merge pull request #9012 from deagon/fix/monitor-agent-url
kata-monitor: fix agentUrl from containerd shim
2024-02-05 10:41:56 +08:00
Xuewei Niu
fa01a86334
Merge pull request #9007 from wainersm/aks_delete_rg
gha: delete azure RG only if it exists
2024-02-04 16:34:17 +08:00
Guoqiang Ding
7bf1ebe16d kata-monitor: fix agentUrl from containerd shim
Fix the missing leading slash.

Fixes: #9013
Signed-off-by: Guoqiang Ding <dgq8211@gmail.com>
2024-02-04 16:24:13 +08:00
Fabiano Fidêncio
e0bb632053
Merge pull request #8983 from fidencio/topic/add-confidential-image
packaging: Add confidential image / initrd
2024-02-03 12:30:16 +01:00
Fabiano Fidêncio
a9f8888c15
packaging: Add confidential image / initrd
Let's use a single rootfs image / initrd for confidential workloads,
instead of having those split for different TEEs.

We can easily do this now as the soon-to-be-added guest-components can
be built in a generic way.

Fixes: #8982

Signed-off-by: Fabiano Fidêncio <fabiano.fidencio@intel.com>
2024-02-03 00:58:52 +01:00
Fabiano Fidêncio
7ddb2e5999
Merge pull request #8978 from fidencio/topic/use-the-kernel-confidential-when-possible
runtime: packaging: Use confidential kernel instead of the TDX one
2024-02-03 00:29:43 +01:00
Fabiano Fidêncio
e9de0ef6b3
packaging: rootfs: Depend on kernel-confidential tarball
Now that we're using the kernel-confidential, let the rootfs depending
on it, instead of depending on the TEE specific ones.

Signed-off-by: Fabiano Fidêncio <fabiano.fidencio@intel.com>
2024-02-02 21:13:41 +01:00
Fabiano Fidêncio
b58cfc765c
packaging: Ensure rootfs is rebuilt in case kernel changes
We need to do this in order to ensure that the measure boot will be
taking the latest kernel bits, as needed.

Signed-off-by: Fabiano Fidêncio <fabiano.fidencio@intel.com>
2024-02-02 21:13:06 +01:00
Fabiano Fidêncio
4394dacb88
packaging: Build the confidential kernel with MEASURED_ROOTFS support
This is already done for the TDX kernel, and should have been done also
for the confidential one.

This action requires us to bump the kernel version as the resulting
kernel will be different from the cached one.

Signed-off-by: Fabiano Fidêncio <fabiano.fidencio@intel.com>
2024-02-02 21:13:06 +01:00
Fabiano Fidêncio
c7680839f9
packaging: Fix modules tarball for nvidia-gpu-confidential
The modules dir has an extra "-nvidia-gpu-confidential" string in its
name.

Signed-off-by: Fabiano Fidêncio <fabiano.fidencio@intel.com>
2024-02-02 21:13:06 +01:00
Fabiano Fidêncio
dc027e39d6
gha: Remove TEE specific kernel build targets
We're using the confidential kernel instead from now on.

Fixes: #8981 -- part I

Signed-off-by: Fabiano Fidêncio <fabiano.fidencio@intel.com>
2024-02-02 21:12:41 +01:00
Fabiano Fidêncio
3755c69165
runtime: makefile: remove SNP specific kernel references
As this is not used anymore, we can go ahead and just remove it

Signed-off-by: Fabiano Fidêncio <fabiano.fidencio@intel.com>
2024-02-02 21:12:21 +01:00
Fabiano Fidêncio
57b132f94c
runtime: makefile: remove SEV specific kernel references
As this is not used anymore, we can go ahead and just remove it

Signed-off-by: Fabiano Fidêncio <fabiano.fidencio@intel.com>
2024-02-02 21:12:21 +01:00
Fabiano Fidêncio
2562d23242
runtime: makefile: remove TDX specific kernel references
As this is not used anymore, we can go ahead and just remove it.

Signed-off-by: Fabiano Fidêncio <fabiano.fidencio@intel.com>
2024-02-02 21:11:43 +01:00
Fabiano Fidêncio
f4e3c936d8
runtime: snp: config: Use the confidential kernel
As we're building a single confidential kernel, we should rely on it
rather than keep using the specific ones for TDX / SEV / SNP.

However, for debugability-sake, let's do this change TEE by TEE.

Signed-off-by: Fabiano Fidêncio <fabiano.fidencio@intel.com>
2024-02-02 21:11:36 +01:00
Fabiano Fidêncio
8731366d7b
runtime: sev: config: Use the confidential kernel
As we're building a single confidential kernel, we should rely on it
rather than keep using the specific ones for TDX / SEV / SNP.

However, for debugability-sake, let's do this change TEE by TEE.

Signed-off-by: Fabiano Fidêncio <fabiano.fidencio@intel.com>
2024-02-02 21:11:36 +01:00
Wainer dos Santos Moschetta
a04b215bcc gha: delete azure RG only if it exists
delete_cluster() has tried to delete the az resources group regardless
if it exists. In some cases the result of that operation is ignored,
i.e., fail to resource group not found, but the log messages get a
little dirty. Let's delete the RG only if it exists then.

Fixes #8989
Signed-off-by: Wainer dos Santos Moschetta <wainersm@redhat.com>
2024-02-02 16:57:20 -03:00
Fabiano Fidêncio
6cbdba7268
runtime: tdx: config: Use the confidential kernel
As we're building a single confidential kernel, we should rely on it
rather than keep using the specific ones for TDX / SEV / SNP.

However, for debugability-sake, let's do this change TEE by TEE.

Signed-off-by: Fabiano Fidêncio <fabiano.fidencio@intel.com>
2024-02-02 17:13:06 +01:00
Fabiano Fidêncio
a618461d3a
runtime: Add confidential kernel to the makefile
With this we can properly generate and the the `-confidential` kernel,
which supports SEV / SNP / TDX as part of our configuration files.

Signed-off-by: Fabiano Fidêncio <fabiano.fidencio@intel.com>
2024-02-02 17:13:05 +01:00
GabyCT
40d9a65601
Merge pull request #8996 from GabyCT/topic/addclhr
gha: k8s: Add cloud-hypervisor (runtime-rs) support
2024-02-02 09:48:35 -06:00
Fabiano Fidêncio
741ed1c8bd
Merge pull request #9001 from fidencio/topic/fix-cache-for-confidential-kernel-part-III
packaging: Don't build the confidential / sev kernel twice -- part III
2024-02-02 15:19:41 +01:00
Wainer Moschetta
424fbfe58f
Merge pull request #8654 from ldoktor/openshift-tests
ci/openshift-ci: Move openshift-ci from the tests repo here
2024-02-02 10:40:30 -03:00
Fabiano Fidêncio
2ff3f0afc6
packaging: Remove trailing whitespace from extra_tarballs arg
This was overlooked during the reviews.

Fixes: #6415 -- part III

Signed-off-by: Fabiano Fidêncio <fabiano.fidencio@intel.com>
2024-02-02 12:42:02 +01:00
Fabiano Fidêncio
228bc48c73
packaging: Fix kernel confidential name
It should be "kernel-confidential" instead of "kernel".

Signed-off-by: Fabiano Fidêncio <fabiano.fidencio@intel.com>
2024-02-02 12:42:02 +01:00
Fabiano Fidêncio
31b21093b0
packaging: Pass the kernel flavour to get_kernel_modules_dir
I made this a required argument during the series and ended up
forgetting to add that while calling the function.

Signed-off-by: Fabiano Fidêncio <fabiano.fidencio@intel.com>
2024-02-02 12:42:02 +01:00
Fabiano Fidêncio
51b1df2333
packaging: Fix typo to get the extra_tarballs path
It should've been  "${m#*:}" instead of "${m#&:}".

Signed-off-by: Fabiano Fidêncio <fabiano.fidencio@intel.com>
2024-02-02 12:41:54 +01:00
Fabiano Fidêncio
53e8461db2
Merge pull request #9000 from fidencio/topic/fix-pushing-artefacts-to-registry
packaging: Fix pushing artefacts to the registry
2024-02-02 10:21:40 +01:00
Fabiano Fidêncio
0b221b5618
packaging: Fix pushing artefacts to the registry
This issues was introduced due to a typo not caught during reviews on
e5bca90274.

Fixes: #6415 -- part II

Signed-off-by: Fabiano Fidêncio <fabiano.fidencio@intel.com>
2024-02-02 10:13:11 +01:00
Wenyuan Liu
cb888516c1
Merge pull request #8760 from fadecoder/reduce_go_runtime_mounts
runtime: Reduce the mount points with namespace isolation
2024-02-02 16:54:44 +08:00
Greg Kurz
d1a26ead94
Merge pull request #8454 from BbolroC/compile-with-qemu-s390x
runtime-rs: make compilation for QEMU on s390x
2024-02-02 09:29:32 +01:00
Fabiano Fidêncio
0520b272a3
Merge pull request #8987 from fidencio/topic/fix-cache-for-confidential-kernel
packaging: cache: Fix caching kernels which rely on extra modules
2024-02-02 09:10:52 +01:00
Amulya Meka
e4252a3fe2
Merge pull request #8957 from Amulyam24/add-k8s-test-ppc64le
gha: add kubernetes tests workflow for ppc64le
2024-02-02 10:22:00 +05:30
Fabiano Fidêncio
b2f1235e3c
Merge pull request #8994 from sprt/sprt/switch-aks-eastus
ci: aks: switch from eastus2 to eastus region
2024-02-02 00:09:40 +01:00
Hyounggyu Choi
bb6f5073aa runtime-rs: Allow compilation for s390x
Until now, runtime-rs couldn't be compiled on s390x.
We need to lift those restrictions in Makefile first.

Fixes: #8446

Signed-off-by: Hyounggyu Choi <Hyounggyu.Choi@ibm.com>
2024-02-01 23:48:15 +01:00
Dan Mihai
6f1062b5d6
Merge pull request #8966 from microsoft/danmihai1/k8s-sandbox-vcpus-allocation
genpolicy: ignore empty YAML as input
2024-02-01 13:51:02 -08:00
Dan Mihai
8f9c92c0ee
Merge pull request #8977 from microsoft/danmihai1/default-namespace
genpolicy: support non-default namespace name
2024-02-01 13:50:33 -08:00
Gabriela Cervantes
6771ca463b gha: k8s: Add cloud-hypervisor (runtime-rs) support
This PR adds the Cloud Hypervisor driver, integrated with the runtime-rs,
as part of the kubernetes tests different with devmapper.

Fixes #8995

Signed-off-by: Gabriela Cervantes <gabriela.cervantes.tellez@intel.com>
2024-02-01 21:22:56 +00:00
Aurélien Bombo
0ace31f041 ci: aks: switch from eastus2 to eastus region
This addresses an internal AKS issue that intermittently prevents
clusters from getting created. The fix has been rolled out to eastus but
not yet eastus2, so we unblock the CI by switching. No downsides in
general.

This supersedes #8990.

Fixes: #8989

Signed-off-by: Aurélien Bombo <abombo@microsoft.com>
2024-02-01 19:22:42 +00:00
Hyounggyu Choi
8fcee6e6ec runtime-rs: Use Persist::restore() of QEMU for VirtSandbox
It fails to compile virt_container because Dragonball is only
used in the implementation of the trait method Persist::restore().
As the hypervisor is not compiled on s390x and QEMU implements
the trait method, this commit is to let the method use QEMUi's.

Signed-off-by: Hyounggyu Choi <Hyounggyu.Choi@ibm.com>
2024-02-01 18:02:10 +01:00
Hyounggyu Choi
56aef3741d runtime-rs: Exclude hypervisors plugins except QEMU for s390x
Dragonball and cloud-hypervisor are not supported on s390x.
We need to exclude the plugins for these hypervisors from compilation.

Signed-off-by: Hyounggyu Choi <Hyounggyu.Choi@ibm.com>
2024-02-01 18:02:10 +01:00
Fabiano Fidêncio
5d2906c36a
packaging: Bump the kata config kernel version
Just to make sure we won't use cached components.

Fixes: #6415

Signed-off-by: Fabiano Fidêncio <fabiano.fidencio@intel.com>
2024-02-01 16:57:15 +01:00
Fabiano Fidêncio
d2ea11dbff
packaging: Use the cached kernel modules
Till now we didn't have a logic to consume the kernel modules cached
tarball.  Let's make sure those are consumed as it'll save us a
reasonable amount of build time.

Signed-off-by: Fabiano Fidêncio <fabiano.fidencio@intel.com>
2024-02-01 16:57:15 +01:00
Fabiano Fidêncio
e5bca90274
packaging: Cache the kernel modules
This will save us a lot of time, as right now the CI is rebuilding the
kernel for absolutely no reason.

Signed-off-by: Fabiano Fidêncio <fabiano.fidencio@intel.com>
2024-02-01 16:55:21 +01:00
Fabiano Fidêncio
f481f58659
packaging: Create the tarball for the kernel modules
Let's start doing this for the confidential kernels (and also for SEV,
till it gets removed).

Signed-off-by: Fabiano Fidêncio <fabiano.fidencio@intel.com>
2024-02-01 16:55:20 +01:00
Fabiano Fidêncio
a58caca723
packaging: Take extra tarballs in install_cached_tarball_component()
This allows us to add a map, in the format of:
`"tarball1_name:tarball1_path tarball2_name:tarball2_path ..."`

With this we have a base to start doing a better job when caching extra
artefacts, like kernel modules.

Signed-off-by: Fabiano Fidêncio <fabiano.fidencio@intel.com>
2024-02-01 16:55:20 +01:00
Fabiano Fidêncio
33ac5468fe
packaging: Add function to get the kernel modules directory
Right now this is just being added but not used yet.  The idea is to use
this to both cache and later on untar the kernel modules needed for some
of the kernel targets we have (specifically looking at the confidential
one).

Signed-off-by: Fabiano Fidêncio <fabiano.fidencio@intel.com>
2024-02-01 16:55:20 +01:00
Zhigang Wang
9317e23df1 mount: Reduce the mount points with namespace isolation
This patch can reduce load on systemd process, and
increase the k8s deployment density when using go runtime.

Fixes: #8758

Signed-off-by: Zhigang Wang <wangzhigang17@huawei.com>
Signed-off-by: Liu Wenyuan <liuwenyuan9@huawei.com>
2024-02-01 18:34:24 +08:00
Xuewei Niu
2332552c8f
Merge pull request #7483 from frezcirno/passfd_io_feature
runtime-rs: improving io performance using dragonball's vsock fd passthrough
2024-02-01 14:53:53 +08:00
Amulyam24
f8585db8d9 gha: add kubernetes tests workflow for ppc64le
This PR adds workflow for running kubernetes test suite on ppc64le.

It uses scripts to create and delete the cluster using kubeadm as none of the current cluster creation tools are supported on Power.

Fixes: #7950

Signed-off-by: Amulyam24 <amulmek1@in.ibm.com>
2024-02-01 12:23:11 +05:30
Alex Lyn
cf26c16017
Merge pull request #8931 from yaoyinnan/8930/feat/merge-ValidCgroupPath
runtime: merged ValidCgroupPath method
2024-02-01 12:53:55 +08:00