Commit Graph

4821 Commits

Author SHA1 Message Date
James O. D. Hunt
576b8a510c
Merge pull request #1513 from Pennyzct/vsock
support-vsock: load vhost_vsock module if it isn't built-in
2019-05-14 11:08:48 +01:00
Marco Vedovati
f2100fd440 runtime: prettify Debian/Ubuntu package template
Signed-off-by: Marco Vedovati <mvedovati@suse.com>
2019-05-14 11:09:29 +02:00
Marco Vedovati
634138145e runtime: specify strict dependencies Debian package
Strict dependencies guarantees that an older version of the runtime will
not be installed together with a more recent version of the other kata
packages.
This complements commit e73473f.

Fixes: #508

Signed-off-by: Marco Vedovati <mvedovati@suse.com>
2019-05-14 11:09:29 +02:00
James O. D. Hunt
33828b7dcb
Merge pull request #509 from jcvenegas/kernel-patches-dir-fix
kernel: obs: fix kernel path
2019-05-14 08:59:47 +01:00
Penny Zheng
bce0d604e1 unit-test: refine unit test
We should refine unit test which involves func SupportsVsocks and newly
reconstructed struct kernelModule.

Fixes: #1512

Signed-off-by: Penny Zheng <penny.zheng@arm.com>
2019-05-14 13:31:25 +08:00
Penny Zheng
9b23d4f143 vsock_module: add 'vhost_vsock' kernel module in kata-check
Since we prefer vsock over virtio serial port, we add 'vhost_vsock'
in kernel mosules list.
But vhost_vsock.ko shouldn't be the definitely required kernel modules,
afterall, we could also use virtio serial port.
if kata-env shows SupportsVSocks as false, users could run kata-check
to manually load vhost_vsock.ko and get detailed info(errors)

Fixes: #1512

Signed-off-by: Penny Zheng <penny.zheng@arm.com>
2019-05-14 13:31:11 +08:00
Penny Zheng
f21d5a37fe Support_vsock: only need to check whether device 'vhost_vsock' exists
QEMU opens /dev/vhost-vsock and this causes vhost_vsock.ko to be
automatically loaded.
So, checking the existence of /dev/vhost-vsock is enough.

Fixes: #1512

Signed-off-by: Penny Zheng <penny.zheng@arm.com>
2019-05-14 13:30:56 +08:00
Eric Ernst
09a7d15176 nemu-config: adjust defaults in configuration-nemu.toml
- For initial offering of virtiofsd, hugepages are required
- use the qemu hypervisor type for configuration template
- decrease virtiofs cache size from 8192 to 1024, to better support
running with virtio-fs on smaller machines while hugepages are required.
- For initial experimental release, utilize virtio-serial instead of
vsock

Fixes: #1662

Signed-off-by: Eric Ernst <eric.ernst@intel.com>
2019-05-13 15:35:04 -07:00
Jose Carlos Venegas Munoz
89695fe7e0 kernel: obs: fix kernel path
Fix path to kernel patches.

Fixes: #505

Signed-off-by: Jose Carlos Venegas Munoz <jose.carlos.venegas.munoz@intel.com>
2019-05-13 14:32:22 -05:00
Jianyong Wu
72054cd2a3 kernel: disable pci shpc hotplug for arm64
As shpchp used for pci hotplug on arm64 initialized
its bottom half work as a delay work for 5 seconds, pci bus
rescan triggered between up half and bottom half of shpc interrupt
handling will fail. so disable shpc and let bus rescan
to do the device hotplug on arm64.

Fixes: #498
Signed-off-by: Jianyong Wu <jianyong.wu@arm.com>
2019-05-13 06:57:02 -04:00
Wei Zhang
a6b3368469 persist: merge more files with persist.json
Fixes #803

Merge more container storage files with `persist.json` including:
* devices.json
* mounts.json
* process.json

Signed-off-by: Wei Zhang <zhangwei555@huawei.com>
2019-05-13 17:00:33 +08:00
Eric Ernst
ef00bb023a kata-deploy: configure multiple runtimes with containerd
Fixes: #504

Signed-off-by: Eric Ernst <eric.ernst@intel.com>
2019-05-10 22:16:34 -07:00
Eric Ernst
beea7d9f64 kata-deploy: add nemu support
Fixes: #416

Signed-off-by: Eric Ernst <eric.ernst@intel.com>
2019-05-10 22:16:34 -07:00
Manohar Castelino
66b93c7ca0 Networking: Ensure that network namespace is propagated
Network namespace needs to be propagated if available at
createSandbox()

Fixes: #1664

Signed-off-by: Manohar Castelino <manohar.r.castelino@intel.com>
2019-05-10 18:00:30 -07:00
James O. D. Hunt
f13416129c
Merge pull request #497 from egernst/nemu-static
nemu: add support for static build of nemu
2019-05-10 16:21:57 +01:00
James O. D. Hunt
4a2fa6875d
Merge pull request #287 from marcov/no-create-1
rootfs: use command vs which, avoid "1" file creation
2019-05-10 16:18:50 +01:00
Eric Ernst
c8e20e2a18
Merge pull request #288 from katabuilder/1.7.0-rc1-branch-bump
# Kata Containers 1.7.0-rc1
2019-05-10 07:58:27 -07:00
Eric Ernst
bce1167c33
Merge pull request #1646 from katabuilder/1.7.0-rc1-branch-bump
# Kata Containers 1.7.0-rc1
2019-05-10 07:58:15 -07:00
James O. D. Hunt
765e51ef0d
Merge pull request #479 from grahamwhaley/20190501_golang_req
kernel: Note prereqs in document
2019-05-10 13:38:33 +01:00
James O. D. Hunt
fca62b1fca
Merge pull request #477 from brtknr/patch-1
Allow kata-deploy containers to restart gracefully
2019-05-10 11:20:18 +01:00
Graham Whaley
3ca8aeb22f kernel: version bump
We modified the kernel subdir, even thought it was only a doc
change, so we need to bump the config ver to reflect that.

Signed-off-by: Graham Whaley <graham.whaley@intel.com>
2019-05-10 10:25:16 +01:00
Graham Whaley
7ccc3b7fdd kernel: README: add a toc
Add Table Of Contents to the kernel README.md file.

Signed-off-by: Graham Whaley <graham.whaley@intel.com>
2019-05-10 10:22:16 +01:00
Graham Whaley
8ec9507387 kernel: README: remove trailing '.' from a title
We don't append fullstops to section titles, and they mess the
ToC up (looks wise). Nuke the one we had in this file.

Signed-off-by: Graham Whaley <graham.whaley@intel.com>
2019-05-10 10:22:16 +01:00
Graham Whaley
38aa271b9c kernel: Note prereqs in document
Note that to use the build script you need to have some prereqs,
including a new enough golang.

Fixes: #478

Reported-by: Rory Savage <rsavage@dispersivegroup.com>
Signed-off-by: Graham Whaley <graham.whaley@intel.com>
2019-05-10 10:22:16 +01:00
Graham Whaley
b9f601c2d3
Merge pull request #458 from amshinde/change-doc-for-runtimeclass
kata-deploy: Change the kata-deploy doc to use yaml files
2019-05-10 08:49:59 +01:00
Hui Zhu
d745bcb034
Merge pull request #1630 from GabyCT/topic/skiptest
test: Skip namespace test on Centos
2019-05-10 15:38:03 +08:00
Hui Zhu
5ba09817d8
Merge pull request #1575 from WeiZhang555/simplify-persist-api
newstore:  removing deprecated files when use new store driver
2019-05-10 15:33:22 +08:00
Hui Zhu
fb93774d28
Merge pull request #1628 from lifupan/fixctx
shimv2: fix the issue ttrpc server canceled context
2019-05-10 15:28:32 +08:00
zhangwei_cs
59948faf32
Merge pull request #1648 from egernst/nemu-config-support
configuration: add nemu support
2019-05-10 14:59:23 +08:00
Eric Ernst
9d71d4e783 configuration: add nemu support
NEMU requires a unique runtime configuration.  Add support for utilizing
a configuration-nemu.toml

Fixes: #1647

Signed-off-by: Eric Ernst <eric.ernst@intel.com>
2019-05-09 22:01:09 -07:00
Eric Ernst
c769e0572c release: add nemu to kata deploy creation script
Add nemu to kata-deploy-binaries.sh

Signed-off-by: Eric Ernst <eric.ernst@intel.com>
2019-05-09 21:52:03 -07:00
Eric Ernst
255bae1515 nemu: add virtiofsd to nemu static binary
add virtiofsd as part of the nemu static build

Signed-off-by: Eric Ernst <eric.ernst@intel.com>
2019-05-09 21:52:03 -07:00
Eric Ernst
924bda0c61 nemu: add support for static build of nemu
Fixes: #401

Signed-off-by: Eric Ernst <eric.ernst@intel.com>
2019-05-09 21:52:03 -07:00
Hui Zhu
9ab09f9c2d
Merge pull request #1651 from lifupan/fix_rootfs
shimv2: create the rootfs dir if it doesn't exist
2019-05-10 09:45:52 +08:00
Fupan Li
838661044f
Merge pull request #1641 from Ace-Tang/leak-ns
vc: fix netns leak
2019-05-10 09:42:16 +08:00
GabyCT
44a5953e45
Merge pull request #1654 from jodh-intel/fix-test-constraint-version-numbers
Fix test constraint version numbers
2019-05-09 16:21:46 -05:00
Salvador Fuentes
b1d8e9f064
Merge pull request #1618 from GabyCT/topic/updatek8s
versions: Update K8s and CRI-O version
2019-05-09 15:13:28 -05:00
Archana Shinde
3444aa68f0 kata-deploy: Change the kata-deploy doc to use yaml files
Change the kata-deploy doc to get rid of code-snippets
and instead include instructions to apply the provided
RuntimeClass yaml according to the k8s version being used.

Fixes #457

Signed-off-by: Archana Shinde <archana.m.shinde@intel.com>
2019-05-09 12:40:40 -07:00
Ace-Tang
a5bc98c150 vc: fix netns leak
when kata container start fails, netns will leak, add a defer func
to fix it

Fixes: #1640

Signed-off-by: Ace-Tang <aceapril@126.com>
2019-05-09 23:07:16 +08:00
James O. D. Hunt
0c207c16ef katatestutils: Add missing distro version constraints
Added the following distro version constraints for parity with the
kernel version constraints:

- `NeedDistroVersionGE()`
- `NeedDistroVersionLE()`
- `NeedDistroVersionNotEquals()`

Signed-off-by: James O. D. Hunt <james.o.hunt@intel.com>
2019-05-09 15:37:57 +01:00
James O. D. Hunt
2bc03f23e0 katatestutils: Fix version check bug
Fix version comparison bug whereby the specified operator was being
applied to the wrong version number.

The version handling for distro and kernel versions was incorrect. This
was not clear as the internal logic was rather difficult to understand.
Renaming `constraintInvalid()` to `constraintValid()` and updating
`NotValid()` correspondingly makes the logic clearer and exposed the
bug, allowing it to be fixed.

Added two new tests to ensure correct behaviour:

- `TestConstraintNotValidKernelVersion()`
- `TestConstraintNotValidDistroVersion()`

Fixes #1653.

Signed-off-by: James O. D. Hunt <james.o.hunt@intel.com>
2019-05-09 15:35:29 +01:00
Salvador Fuentes
0162e41d78
Merge pull request #1645 from egernst/nemu-bump
Nemu bump
2019-05-09 09:26:16 -05:00
James O. D. Hunt
1bec735cb6 katatestutils: Fix NeedDistroVersionEquals comment
Previously, the comment on `NeedDistroVersionEquals()` erroneously
referred to `NeedDistroVersionLT()`.

Signed-off-by: James O. D. Hunt <james.o.hunt@intel.com>
2019-05-09 15:00:21 +01:00
James O. D. Hunt
20b558656d katatestutils: Reset TestConstraints fields on NotValid() call
`TestConstraint.NotValid()` is really designed to be called once per
test. However, there is no reason it should not be possible to call
multiple times. But to allow for that secenario, any settings
from a previous `NotValid()` call need to be cleared.

Signed-off-by: James O. D. Hunt <james.o.hunt@intel.com>
2019-05-09 14:56:38 +01:00
Graham Whaley
82dc91481d
Merge pull request #463 from devimc/topic/howto/fixContainerdWithCri
how-to: Fix `Install containerd with cri plugin` note
2019-05-09 14:29:40 +01:00
Julio Montes
3b29f8fbb3 how-to: Fix Install containerd with cri plugin note
It's a little complicated to understand the note of the section
Install containerd with cri plugin, that says Just check if the cri plugin has
been disabled in the containerd configuration file but if it's disabled
containerd + the runtime class won't work.

fixes #462

Signed-off-by: Julio Montes <julio.montes@intel.com>
2019-05-09 08:21:55 -05:00
Gabriela Cervantes
4b6370160a test: Skip namespace test on Centos
Skip TestHostNetworkingRequested test as nsfs is not supported on
older kernel versions. Currently, CentOS has issues with this test a
is using a kernel version of 3.10 and to run this test we need a
kernel version greater than 3.19.

Fixes #1629

Signed-off-by: Gabriela Cervantes <gabriela.cervantes.tellez@intel.com>
2019-05-09 08:05:21 -05:00
lifupan
8eb09dec67 shimv2: fix the issue ttrpc server canceled context
This latest ttrpc vendor supports the feature of request timeout propgation.
this feature will do context cancel after a service call return, and this cancel
will propagated into kata sandbox's agent/hypervisor and resulted in the following
calls canceled. To fix this issue, pass the service's context instead of the service's
call's context to CreateSandbox(), and this context will live until the shim exited.

Fixes:#1627

Signed-off-by: lifupan <lifupan@gmail.com>
2019-05-09 04:58:30 -04:00
James O. D. Hunt
bb44f65a68
Merge pull request #1623 from awprice/system-mount-skip
mounts: fix isSystemMount check for mountSharedDirMounts
2019-05-09 09:38:11 +01:00
lifupan
1b33fe4022 shimv2: create the rootfs dir if it doesn't exist
Latest containerd commit<c0f0b21314b93a1> had moved the
step of creating rootfs dir from creating bundle to container
creation; in order to support both of the old and latest
containerd, check the "rootfs" existed before creating it.

Fixes:#1652

Signed-off-by: lifupan <lifupan@gmail.com>
2019-05-09 04:20:48 -04:00