Commit Graph

5338 Commits

Author SHA1 Message Date
Christophe de Dinechin
d76ece0cf3 rust-agent: Remove useless braces
This addresses the following warning:

    warning: unnecessary braces around assigned value
        --> src/rpc.rs:1411:26
         |
    1411 |     detail.init_daemon = { unistd::getpid() == Pid::from_raw(1) };
         |                          ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: remove these braces
         |
         = note: `#[warn(unused_braces)]` on by default

Fixes: #750

Signed-off-by: Christophe de Dinechin <dinechin@redhat.com>
2020-10-07 13:39:26 +02:00
Christophe de Dinechin
3682812e57 rust-agent: Remove unused macros
This addresses the following warnings:

   Compiling rustjail v0.1.0 (/home/ddd/go/src/github.com/kata-containers-2.0/src/agent/rustjail)
   warning: unused `#[macro_use]` import
     --> rustjail/src/lib.rs:15:1
      |
   15 | #[macro_use]
      | ^^^^^^^^^^^^
      |
      = note: `#[warn(unused_imports)]` on by default

   warning: unused macro definition
     --> rustjail/src/lib.rs:38:1
      |
   38 | / macro_rules! sl {
   39 | |     () => {
   40 | |         slog_scope::logger().new(o!("subsystem" => "rustjail"))
   41 | |     };
   42 | | }
      | |_^
      |
      = note: `#[warn(unused_macros)]` on by default

Fixes: #750

Signed-off-by: Christophe de Dinechin <dinechin@redhat.com>
2020-10-07 13:39:26 +02:00
Eric Ernst
cf26ac0d28
Merge pull request #867 from egernst/main-packaging-fixups
Main packaging fixups
2020-10-06 16:22:44 -07:00
Eric Ernst
483209bf49 actions: add kata deploy test
Pull over kata-deploy-test from the 1.x packaging repository. This is
intended to be used for testing any changes to the kata-deploy
scripting, and does not exercise any new source code changes.

Signed-off-by: Eric Ernst <eric.g.ernst@gmail.com>
2020-10-06 13:44:03 -07:00
Eric Ernst
0793002464 packaging: cleaning, updating based on new filepaths
Update scripts to take into account some files being moved, and some
general cleanup.

Fixes: #866

Signed-off-by: Eric Ernst <eric.g.ernst@gmail.com>
2020-10-06 13:44:03 -07:00
Eric Ernst
f0f205cd7b packaging: remove obs-packaging
No longer required -- let's remove them.

Signed-off-by: Eric Ernst <eric.g.ernst@gmail.com>
2020-10-06 13:44:03 -07:00
Eric Ernst
4b1753c53f packaging: pull versions, build-image out from obs dir
These are still required; let's pull them out.

Signed-off-by: Eric Ernst <eric.g.ernst@gmail.com>
2020-10-06 13:44:03 -07:00
Eric Ernst
3f6cd4d5f7 packaging: Revert "packaging: Stop providing OBS packages"
This reverts commit c0ea910273.

Two scripts are still required for release and testing, which should
have never been under obs-packaging dir in the first place.  Let's
revert, move the scripts / update references to it, and then we can
remove the remaining obs-packaging/ tooling.

Signed-off-by: Eric Ernst <eric.g.ernst@gmail.com>
2020-10-06 13:43:53 -07:00
James O. D. Hunt
13e260a864
Merge pull request #861 from likebreath/clh_vfio_unplug
clh: Support VFIO device unplug
2020-10-06 09:47:19 +01:00
Julio Montes
4657983d80
Merge pull request #839 from devimc/2020-10-01/snapCI
ci: add github action to test the snap
2020-10-05 15:49:30 -05:00
Bo Chen
c33ee54a21 clh: Support VFIO device unplug
This patch adds the support of VFIO device unplug when using
cloud-hypervisor.

Fixes: #860

Signed-off-by: Bo Chen <chen.bo@intel.com>
2020-10-05 12:20:13 -07:00
Bo Chen
1f4dfa3166 clh: Remove unnecessary VmmPing
We can rely on the error handling of the actual HTTP API calls to catch
errors, and don't need to call VmmPing explicitly in advance.

Signed-off-by: Bo Chen <chen.bo@intel.com>
2020-10-05 12:17:45 -07:00
Bo Chen
cc80ae0afb versions: cloud-hypervisor: Bump to version 6d30fe05
The cloud-hypervisor commit `6d30fe05` introduced a fix on its API for
VFIO device hotplug (`VmAddDevice`), which is required for supporting
VFIO unplug through openAPI calls in kata.

Signed-off-by: Bo Chen <chen.bo@intel.com>
2020-10-05 12:13:36 -07:00
Eric Ernst
2929250b61
Merge pull request #798 from cmaf/architecture-tap
docs: update networking description
2020-10-05 08:42:19 -07:00
Chelsea Mafrica
0fec7a4d73 docs: Change kata_tap0 to tap0_kata
Tap device's should be tap0_kata for architecture.md

Fixes #797

Signed-off-by: duanquanfeng <duanquanfeng_yewu@cmss.chinamobile.com>
Signed-off-by: Chelsea Mafrica <chelsea.e.mafrica@intel.com>
2020-10-04 16:55:50 -07:00
Chelsea Mafrica
3394a6a549 docs: update networking description
First, most people don't care about CNM. Move that out of main doc.

Second, tc-filter is the default. Let's add a bit more background on
our usage of tc-filter (and clarify why we use this instead of macvtap).

Fixes #797

Signed-off-by: Eric Ernst <eric.g.ernst@gmail.com>
Signed-off-by: Chelsea Mafrica <chelsea.e.mafrica@intel.com>
2020-10-04 16:55:50 -07:00
Eric Ernst
62b0522b33
Merge pull request #852 from egernst/dev-guide
docs: update dev guide for agent build
2020-10-02 17:13:52 -07:00
Eric Ernst
2e83f40576 dev-guide: update kata-agent install details
Install paths were wrong. Updated based on new agent...

Signed-off-by: Eric Ernst <eric.g.ernst@gmail.com>
2020-10-02 16:17:36 -07:00
Eric Ernst
777f398184 docs: update dev guide for agent build
Include details on setting up rust.

Fixes: #851

Signed-off-by: Eric Ernst <eric.g.ernst@gmail.com>
2020-10-02 15:38:07 -07:00
Julio Montes
aa8eefd813 ci: add github action to test the snap
Add github action to test that the snap package was generated
correctly, this CI don't test the snap, it just build it.

fixes #838

Signed-off-by: Julio Montes <julio.montes@intel.com>
2020-10-01 14:34:36 -05:00
James O. D. Hunt
1d5eab42d6
Merge pull request #833 from bergwolf/197
rust-agent: Update README
2020-10-01 17:26:21 +01:00
James O. D. Hunt
2133f3b742
Merge pull request #832 from bergwolf/arch
docs: update architecture.md
2020-10-01 17:26:16 +01:00
Julio Montes
c2bf8a0f37
Merge pull request #484 from devimc/2020-07-31/SGX
runtime: add support for SGX
2020-10-01 11:08:11 -05:00
Julio Montes
3fec031100
Merge pull request #817 from edmond-hk/qemu
version: upgrade qemu version to v5.1.0 for arm64
2020-10-01 10:31:19 -05:00
James O. D. Hunt
64c3f8bbe0
Merge pull request #686 from jodh-intel/2.0-dev-fix-windows-network-typo
agent: Fix OCI Windows network shared container name typo
2020-10-01 14:25:49 +01:00
James O. D. Hunt
05286d6b1f
Merge pull request #731 from jodh-intel/rm-issue-template
github: Remove issue template and use central one
2020-10-01 14:25:40 +01:00
Julio Montes
ea1cb37b59 versions: cloud-hypervisor: bump version
Use commit c54452c08a467a3e35d8d72f2a91d424e9718c57 as
version for cloud-hypervisor.
Bring openapi fix cloud-hypervisor/cloud-hypervisor#1760 to
support SGX.

Signed-off-by: Julio Montes <julio.montes@intel.com>
2020-10-01 08:24:29 -05:00
Julio Montes
0ebffdf29f runtime: cloud-hypervisor: tag openapi-generator-cli container
Tag openapi-generator-cli container to v4.3.1 that is the latest
stable, this way we can have reproducible builds and the same
generated code in all the systems

Signed-off-by: Julio Montes <julio.montes@intel.com>
2020-10-01 08:24:29 -05:00
Julio Montes
e51a1ea346 docs: use-cases: Add Intel SGX use case
Document how to use Intel SGX with Kata.

fixes kata-containers/documentation#697

Signed-off-by: Julio Montes <julio.montes@intel.com>
2020-10-01 08:24:29 -05:00
Julio Montes
7d63823141 runtime/vendor: add k8s.io/apimachinery/pkg/api/resource
k8s.io/apimachinery/pkg/api/resource is a memory quantities parser,
we use it to parse the SGX EPC size defined by the `sgx.intel.com/epc`
annotation

Signed-off-by: Julio Montes <julio.montes@intel.com>
2020-10-01 08:24:29 -05:00
Julio Montes
6df165c19d runtime: add support for SGX
Support the `sgx.intel.com/epc` annotation that is defined by the intel
k8s plugin. This annotation enables SGX. Hardware-based isolation and
memory encryption.

For example, use `sgx.intel.com/epc = "64Mi"` to create a container
with 1 EPC section with pre-allocated memory.

At the time of writing this patch, SGX patches have not landed on the
linux kernel project.
The following github kernel fork contains all the SGX patches for the
host and guest: https://github.com/intel/kvm-sgx

fixes #483

Signed-off-by: Julio Montes <julio.montes@intel.com>
2020-10-01 08:24:29 -05:00
Peng Tao
a5b3e1cdfd docs: drop docker installation guide
We have removed cli support and that means dockder support is dropped
for now. Also it doesn't make sense to have so many duplications on each
distribution as we can simply refer to the official docker guide on how
to install docker.

Signed-off-by: Peng Tao <bergwolf@hyper.sh>
2020-10-01 20:52:10 +08:00
Peng Tao
6c4300c65f docs: fix static check errors in docs/install/README.md
It was merged in while the static checker is disabled.

Signed-off-by: Peng Tao <bergwolf@hyper.sh>
2020-10-01 20:52:10 +08:00
Peng Tao
59224a76b4 docs: update architecture.md
To match the current architecture of Kata Containers 2.0.

Fixes: #831
Signed-off-by: Peng Tao <bergwolf@hyper.sh>
2020-10-01 20:51:55 +08:00
Yang Bo
a89deb3ec1 rust-agent: Update README
rust agent does not use grpc as submodule for a while, update README
to reflect the change.

Fixes: #196
Signed-off-by: Yang Bo <bo@hyper.sh>
Signed-off-by: Peng Tao <bergwolf@hyper.sh>
2020-10-01 20:41:20 +08:00
James O. D. Hunt
80c52834e6 github: Remove issue template and use central one
Remove the GitHub issue template from this repository. We already have a
central set of templates [1] that are being used so the template in this
repository is redundant.

[1] - https://github.com/kata-containers/.github/tree/master/.github/ISSUE_TEMPLATE/

Fixes: #728.

Signed-off-by: James O. D. Hunt <james.o.hunt@intel.com>
2020-10-01 11:19:32 +01:00
James O. D. Hunt
0ccbca3be8 agent: Fix OCI Windows network shared container name typo
Correct the typo which would break the Windows-specific OCI network
shared container name feature.

See:

- https://github.com/opencontainers/runtime-spec/blob/master/config-windows.md#network

Fixes: #685.

Signed-off-by: James O. D. Hunt <james.o.hunt@intel.com>
2020-10-01 11:18:21 +01:00
James O. D. Hunt
cce80bf746
Merge pull request #827 from devimc/2020-09-29/fixTravis
docs: fix broken links
2020-10-01 09:50:48 +01:00
Edmond AK Dantes
a6221a74e7 qemu: upgrade qemu version to 5.1.0 for arm64.
Now, the qemu version used in arm is so old. As some new features have merged
in current qemu, so it's time to upgrade it. As obs-packaging has been removed,
I put the qemu patch under qemu/patch/5.1.x.
As vxfs has been Deprecated in qemu-5.1, it will be no longer exist in
configuration-hyperversior.sh when qemu version larger than 5.0.

Fixes: #816
Signed-off-by: Edmond AK Dantes <edmond.dantes.ak47@outlook.com>
2020-09-30 22:40:49 +08:00
Julio Montes
d68d850ac4
Merge pull request #830 from YchauWang/update-docs-2.0-2
Packaging: release notes script using error kernel path urls
2020-09-30 09:35:23 -05:00
Peng Tao
ec09971d8e
Merge pull request #794 from c3d/bug/793-bad-match
rust-agent: Replaces improper use of match for non-constant patterns
2020-09-30 20:39:45 +08:00
Peng Tao
414b906e9c
Merge pull request #747 from Kvasscn/fix-warning-in-device-manager-test
devices: fix go test warning in manager_test.go
2020-09-30 20:37:20 +08:00
Bin Liu
ae72ba5cb6
Merge pull request #688 from jodh-intel/2.0-dev-action-improve-line-length-check
action: Allow long lines if non-alphabetic
2020-09-30 15:47:53 +08:00
Ychau Wang
f30b86f131 Packaging: release notes script using error kernel path urls
2.0 Packaging runtime-release-notes.sh script is using 1.x Packaging
kernel urls. Fix these urls to 2.0 branch Packaging urls.

Fixes: #829

Signed-off-by: Ychau Wang <wangyongchao.bj@inspur.com>
2020-09-30 14:47:46 +08:00
Bin Liu
ad7b1ff5ad
Merge pull request #820 from Tim-Zhang/mark-unreachable
Indicates never return function and remove unreachable code
2020-09-30 13:59:30 +08:00
Julio Montes
a7faeaac51 docs: fix broken links
Some sections and files were removed in a previous commit,
remove all reference to such sections and files to fix the
check-markdown test.

fixes #826

Signed-off-by: Julio Montes <julio.montes@intel.com>
2020-09-29 14:08:40 -05:00
Julio Montes
c32af06fc6
Merge pull request #825 from lifupan/2.0-dev
agent: propagate the internal detail errors to users
2020-09-29 12:12:34 -05:00
fupan.lfp
4501c25a46 agent: propagate the internal detail errors to users
It's should propagate the detail errors to users when
the rpc call failed.

Fixes: #824

Signed-off-by: fupan.lfp <fupan.lfp@antfin.com>
2020-09-30 00:01:23 +08:00
Fabiano Fidêncio
3360fb343f
Merge pull request #628 from fidencio/wip/update-install-information
Update Installation Guide to better reflect the current state of the project
2020-09-29 17:30:47 +02:00
Peng Tao
3dcd611a3b
Merge pull request #822 from chavafg/topic/ci-tests-clone-fix
ci: fix clone_tests_repo function
2020-09-29 23:18:54 +08:00