Commit Graph

5325 Commits

Author SHA1 Message Date
Julio Montes
e393422ad4 snap: add bc to build-packages
bc is required to build the snap in launchpad

fixes #635

Signed-off-by: Julio Montes <julio.montes@intel.com>
2019-07-11 15:03:42 +00:00
Salvador Fuentes
0089d300e4
Merge pull request #626 from devimc/topic/snap/fixSnap
snap: fix and release new snap
2019-07-10 13:46:14 -05:00
Vijay Dhanraj
98a69736c5 virtcontainers: Add ACRN unit test cases
This patch adds unit test cases for acrn specific changes.

Fixes: #1778
Signed-off-by: Vijay Dhanraj <vijay.dhanraj@intel.com>
2019-07-10 10:49:24 -07:00
Vijay Dhanraj
f246a799aa virtcontainers: Add support for updating virtio-blk based container rootfs
Thist patch adds the following,
1. ACRN only supports virtio-blk and so the rootfs for the VM
   sits at /dev/vda. So to get the container rootfs increment the
   globalIndex by 1.
2. ACRN doesn't hot-plug container rootfs (but uses blkrescan) to
   update the container rootfs. So the agent can be provided the virtpath
   rather than the PCIaddr avoiding unneccessary rescaning to find the
   virthpath.

v1->v2:
Removed the workaround of incrementing index for
virtio-blk device and addressed it acrn.

Fixes: #1778

Signed-off-by: Vijay Dhanraj <vijay.dhanraj@intel.com>
2019-07-10 10:49:24 -07:00
Vijay Dhanraj
d9a4157841 virtcontainers: Add support for launching/managing ACRN based VMs
This patch adds the following,
1. Implement Sandbox management APIs for ACRN.
2. Implement Sandbox operation APIs for ACRN.
3. Add support for hot-plugging virtio-blk based
(using blk rescan feature) container rootfs to ACRN.
4. Prime devices, image and kernel parameters for
launching VM using ACRN.

v2->v3:
Incrementing index to keep track of virtio-blk devices
created. This change removes the workaround introduced
in block.go.

v1->v2:
1. Created issue #1785 to address the UUID TODO item.
2. Removed dead code.
3. Fixed formatting of log messages.
4. Fixed year in copyright message.
5. Removed acrn_amd64.go file as there are no amd64 specific
   changes. Moved the code to acrn_arch_base.go.

Fixes: #1778

Signed-off-by: Vijay Dhanraj <vijay.dhanraj@intel.com>
2019-07-10 10:49:24 -07:00
Vijay Dhanraj
828e0a2205 pkg/katautils: Add support for ACRN hypervisor config
This patch adds support for,
1. Extracting and configuring ACRN hypervisor from toml.
2. Add ACRN hypervisor ctl for controlling ACRN hypervisor.
This will be used for updating virtio-blk based
container rootfs using blk rescan feature.

v2->v3:
Fixed acrnctl path.

v1->v2:
Trimmed hypervisor config options as needed by ACRN.

Fixes: #1778

Signed-off-by: Vijay Dhanraj <vijay.dhanraj@intel.com>
2019-07-10 10:49:24 -07:00
Vijay Dhanraj
adcac9368f kata-check: Check and validate type-1 hypervisor for kata
ACRN hypervisor is a type-1 hypervisor and this patch
adds support to check and validate if the system is
capable of running kata containers with ACRN hypervisor.

Depends-on: github.com/kata-containers/tests#1793

v3->v4:
Implemented a generic way to identify hypervisor and
test VM creation.

v2->v3:
1. Removed cgo structs and defined go structs.
2. Suppressed lint warnings due to unused createVM struct.

v1->v2:
1. Created an issue #1784 to address TODO item.
2. Fixed formatting of the log message.
3. Currently ACRN is only supported on amd64. So
   moved ACRN specific code to kata-check_amd64.go.

Fixes: #1778

Signed-off-by: Vijay Dhanraj <vijay.dhanraj@intel.com>
2019-07-10 10:47:31 -07:00
Vijay Dhanraj
4d26ceee79 Make: Add ACRN hypervisor and generate configuration file
This patch covers the following aspects,
1. Add ACRN as a supported hypervisor for amd64 architecture.
2. Build and install configuration file for ACRN hypervisor.

v1->v2:
1. Deleted autogenerated configuration-acrn.toml.
2. Trimmed configuration options not used by ACRN.

Fixes: #1778

Signed-off-by: Vijay Dhanraj <vijay.dhanraj@intel.com>
2019-07-10 10:46:47 -07:00
Julio Montes
4e5e018e59 snap/ci: Do not run shimv2 tests
shimv2 with vm templating are failing, disable them and fix later
see https://github.com/kata-containers/packaging/issues/633

Signed-off-by: Julio Montes <julio.montes@intel.com>
2019-07-10 15:48:04 +00:00
Salvador Fuentes
a4e6af0316
Merge pull request #1873 from openSUSE/crictl-openshift
versions: add crictl version which is compatible with OpenShift
2019-07-10 10:10:26 -05:00
Sascha Grunert
bdd89473fd
versions: add crictl version which is compatible with OpenShift
Fixes #1872

Signed-off-by: Sascha Grunert <sgrunert@suse.com>
2019-07-10 11:02:34 +02:00
Julio Montes
10959e6faf
Merge pull request #624 from devimc/topic/kernel/fixConfig
kernel/x86_64: fix make oldconfig
2019-07-09 15:54:07 -05:00
Julio Montes
e647b50bd8
Merge pull request #628 from devimc/topic/scripts/qemu41Libssh
scripts: update configure-hypervisor script to support QEMU 4.1
2019-07-09 15:53:36 -05:00
Julio Montes
588bcedd02 snap: release 1.8.0-rc0
Update snap version to 1.8.0-rc0

fixes #625

Signed-off-by: Julio Montes <julio.montes@intel.com>
2019-07-09 20:31:05 +00:00
Julio Montes
cc4e59f19d snap: update QEMU to 4.0.0
Update QEMU to 4.0.0 since it's now officially supported in Kata Containers

Signed-off-by: Julio Montes <julio.montes@intel.com>
2019-07-09 20:31:05 +00:00
Julio Montes
0bbce8e652 snap: use tagged version of osbuilder to generate the images
To avoid conflics between kata companents and their versions, all
components should be built using their tagged version.

Signed-off-by: Julio Montes <julio.montes@intel.com>
2019-07-09 20:31:05 +00:00
Julio Montes
a0d0a20c98 snap: setup kernel using build-kernel.sh
Setup the kernel by hand is prone to errors.
Use `build-kernel.sh setup` to pull and setup the kata kernel.

fixes #438

Signed-off-by: Julio Montes <julio.montes@intel.com>
2019-07-09 20:31:05 +00:00
Julio Montes
335b8846ed snap: pull and install yq from github
osbuilder shares the yq binary with the container that generates the image,
unfortunately the snap version of yq is not a static binary hence it's not
compatible with the alpine container.

Signed-off-by: Julio Montes <julio.montes@intel.com>
2019-07-09 18:01:59 +00:00
GabyCT
e9bbe0b343
Merge pull request #1867 from openSUSE/crio-version
versions: update CRI-O to v1.14.6
2019-07-09 10:11:34 -05:00
Sascha Grunert
098501ac14
versions: update CRI-O to v1.14.6
- Changes:
  - version: v1.14.6
  - Add username and homedir to generated password
  - Close temporary image in PullImage
  - Version 1.14.6-dev
  - Version 1.14.5
  - version: if git commit is empty, silently ignore
  - enable inline exec and attach test
  - Bump up minMemoryLimit to 12Mb
  - Backport CircleCI config
  - Fix up machine os content version and cri-o version in spec
  - Add state of infracontainer to disk when stopped
  - Use GlobalAuthFile when pulling the pause image if
    PauseImageAuthFile is not set
  - Don't discard copy.Options.SourceCtx when credentials are provided
  - Don't set non-default copy.Options in imageService.PullImage if it is nil
  - Add global_auth_file option to crio.image config
  - Create network and plugins directory if they do not exist
  - Disable file locking by default
  - Update containers/image to v2.0.0, buildah to 1.8.4, libpod to 1.4.1, ...
  - Bump github.com/containers/libpod from 1.2.0 to 1.3.1
  - Vendor containers/storage v1.12.4
  - update github.com/containers/* dependencies
  - Changes to rpm build and Dockerfile for ci
  - When plugin_dir is set, only use that value
  - Update Makefile to be usable without git
  - bump to version 1.14.5-dev
  - bump to version 1.14.4
  - Default to runc is default_runtime is not set
  - Fix missing images names on list
  - Add crio-wipe
  - Add logic for running OpenShift CI on cri-o PRs
  - Update device cgroup permissions for configured devices.
  - version: v1.14.4-dev
  - version: v1.14.3
  - Fix runtime panic when having concurrent writes to runtime impl map
  - server: do not add default /sys if bind mounted
  - Change plugin_dir to plugin_dirs
  - Added unit tests
  - Add version file functionality
  - fix build issues on 32-bit arches
  - conmon: use sd_journal_sendv
  - make vendor generated
  - Move to v1.14.3-dev
  - Tag v1.14.2
  - Vendor in c/storage release-1.13
  - Revert "update github.com/containers/* dependencies"
  - Update test suites
  - Fix logic of server.restore()
  - version: v1.14.2-dev

Fixes #1866

Signed-off-by: Sascha Grunert <sgrunert@suse.com>
2019-07-09 10:57:25 +02:00
Julio Montes
d0c267191c kernel/x86_64: fix make oldconfig
Add missing kernel configs to avoid `make oldconfig` asks or
takes the default value for the missing configs.

fixes #623

Signed-off-by: Julio Montes <julio.montes@intel.com>
2019-07-08 19:26:26 +00:00
Julio Montes
c0f8cf66e2 scripts: update configure-hypervisor script to support QEMU 4.1
QEMU >= 4.1 uses libssh not libssh2

fixes #627

Signed-off-by: Julio Montes <julio.montes@intel.com>
2019-07-08 17:14:29 +00:00
Nitesh Konkar
edbd23728c README: Fix a typo in Kernel Readme
Fix a typo

Fixes:  #583

Signed-off-by: Nitesh Konkar niteshkonkar@in.ibm.com
2019-07-08 13:57:19 +05:30
GabyCT
220ae83820
Merge pull request #1859 from jodh-intel/fix-fork-exec-test-error
Fix fork exec test errors
2019-07-05 15:40:50 -05:00
GabyCT
8b89a868e9
Merge pull request #1858 from GabyCT/topic/checkversion
ci: Verify and block merge if other projects are not updated
2019-07-05 14:05:53 -05:00
GabyCT
89f2c80451
Merge pull request #618 from jcvenegas/fix-container-image
Packaging fixes for release
2019-07-05 12:43:56 -05:00
Jose Carlos Venegas Munoz
3240ad0fd5
Merge pull request #614 from GabyCT/topic/updatecheckversion
ci: Enable check VERSION among the components without the runtime
2019-07-05 11:52:26 -05:00
Jose Carlos Venegas Munoz
bfc9220663 package: fix path to qemu-vanilla in debs
Deb files has not a correct qemu vanilla path.

Fixes: #620

Signed-off-by: Jose Carlos Venegas Munoz <jose.carlos.venegas.munoz@intel.com>
2019-07-05 09:58:39 -05:00
Jose Carlos Venegas Munoz
f9fe9440a7 ci: cd: Use the same obs script for CD.
We want to use the same script for both
PRs and new package CD. Depending if CI
is set a release push will be done or
a ci.

Fixes: #617

Signed-off-by: Jose Carlos Venegas Munoz <jose.carlos.venegas.munoz@intel.com>
2019-07-05 09:58:39 -05:00
James O. D. Hunt
4968438992 tests: Fix fork/exec test error
Fixed `TestSandboxCreationFromConfigRollbackFromCreateSandbox` which
requires that the hypervisor does not exist. Unfortunately, it does
exist (as a fake test binary), but isn't executable meaning although the
test failed (since an error is expected), rather than the expected
`ENOENT` error, the test was logging a message similar to the following
since the fake hypervisor exists with non-executable permissions:

```
Unable to launch /tmp/vc-tmp-526112270/hypervisor: fork/exec /tmp/vc-tmp-526112270/hypervisor: permission denied
```

Fixes: #1835.

Signed-off-by: James O. D. Hunt <james.o.hunt@intel.com>
2019-07-05 11:11:56 +01:00
James O. D. Hunt
fcf9f9f6dd test: Fix fd leak causing test error
Update the `TestQemuAddDeviceKataVSOCK` test so that it:

- Doesn't hard-code the file descriptor number.
- Cleans up after itself.

The latter issue was causing an odd error similar to the following in
the test output:

```
Unable to launch /tmp/vc-tmp-526112270/hypervisor: fork/exec /tmp/vc-tmp-526112270/hypervisor: permission denied
```

Partially fixes: #1835.

Signed-off-by: James O. D. Hunt <james.o.hunt@intel.com>
2019-07-05 11:11:52 +01:00
Gabriela Cervantes
5182a2551d ci: Verify and block merge if other projects are not updated
This will take the VERSION of all the components in order to
verify that they match among them before merging the runtime.

Fixes #1581

Depends-on: github.com/kata-containers/packaging#614

Signed-off-by: Gabriela Cervantes <gabriela.cervantes.tellez@intel.com>
2019-07-05 01:06:37 -05:00
Jose Carlos Venegas Munoz
d29427d353 qemu: static: Apply qemu patches depending on the verison.
qemu static is using all the patches that we have for qemu,
we only want to apply depending the version.

Fixes: #619

Signed-off-by: Jose Carlos Venegas Munoz <jose.carlos.venegas.munoz@intel.com>
2019-07-04 15:33:33 -05:00
Jose Carlos Venegas Munoz
38b93464d8
Merge pull request #616 from jcvenegas/fix-container-image
obs: dokcer: update leap image base.
2019-07-04 11:06:57 -05:00
Jose Carlos Venegas Munoz
3aba4d330d obs: docker: update leap image base.
The image tag opensuse:leap not longer exist
use the the new image format.

Fixes: #615

Signed-off-by: Jose Carlos Venegas Munoz <jose.carlos.venegas.munoz@intel.com>
2019-07-04 09:06:02 -05:00
Gabriela Cervantes
98ad9e2ae2 ci: Enable check VERSION among the components without the runtime
The main purpose is that this script will be used to verify
that VERSION among the components are equal before merging the runtime.

Fixes #613

Depends-on: github.com/kata-containers/runtime#1858

Signed-off-by: Gabriela Cervantes <gabriela.cervantes.tellez@intel.com>
2019-07-04 05:16:01 -05:00
Fupan Li
cd4cc02568
Merge pull request #1857 from odinuge/fix-hugetlb-pagesize
shimv2: Add missing page size to Hugetlb Stat
2019-07-04 15:57:45 +08:00
Jose Carlos Venegas Munoz
a5ff98ff49
Merge pull request #612 from jcvenegas/stable-branch-creation
tag: Automatically create stable branch
2019-07-03 16:20:40 -05:00
Jose Carlos Venegas Munoz
633e5cc1d6 tag: Automatically create stable branch
After a rc0 is created the path to have an stable release starts, after that
any rc0 is to improve stabability and not more features are added. When it is
the projects is considered stable no more rc* are done.

Fixes: #611

Signed-off-by: Jose Carlos Venegas Munoz <jose.carlos.venegas.munoz@intel.com>
2019-07-03 14:39:38 -05:00
Odin Ugedal
da7f5f3796
shimv2: Add missing page size to Hugetlb Stat
Fixes: #1856

Signed-off-by: Odin Ugedal <odin@ugedal.com>
2019-07-03 21:07:04 +02:00
Jose Carlos Venegas Munoz
0ec5e60342
Merge pull request #610 from jcvenegas/bump-on-log-fail
bump: Do not fail is not possible to get logs
2019-07-03 12:58:28 -05:00
Jose Carlos Venegas Munoz
896ed41c7f bump: Do not fail is not possible to get logs
Sometimes get logs could fail, for example
when a tag does not exit, instead of fail
just log the error in the PR.

Fixes: #609

Signed-off-by: Jose Carlos Venegas Munoz <jose.carlos.venegas.munoz@intel.com>
2019-07-03 10:07:14 -05:00
Jose Carlos Venegas Munoz
33434894ba
Merge pull request #325 from katabuilder/1.8.0-rc0-branch-bump
# Kata Containers 1.8.0-rc0
2019-07-03 08:46:10 -05:00
James O. D. Hunt
c74f9a2bfb
Merge pull request #327 from jcvenegas/fix-go-version-detect
rootfs: fix golang version detection
2019-07-03 08:41:01 +01:00
GabyCT
43f2680e4c
Merge pull request #1841 from katabuilder/1.8.0-rc0-branch-bump
# Kata Containers 1.8.0-rc0
2019-07-02 18:15:16 -05:00
Jose Carlos Venegas Munoz
4ade7e5853 rootfs: fix golang version detection
When the rootfs creation is used for PRs there is
not a match with a kata runtime version, in this
case lets clone the runtime repository and checkout
to the kata branch target. If is already cloned
this mean this was set by depens-on script or the user.

Fixes: #326

Signed-off-by: Jose Carlos Venegas Munoz <jose.carlos.venegas.munoz@intel.com>
2019-07-02 18:05:10 -05:00
Archana Shinde
27dddf0a25 rootfs: Make sure etc exists.
We are seeing sporadic failures in the rootfs creation as listed here:
https://github.com/kata-containers/tests/issues/1744

While this cannot be reproduced locally, there is no reason
for the failure to write to $ROOTFS_DIR/etc/chrony.conf unless the upper
directories are missing as this file should be created if it did not
exist earier.
So just create the etc directory to test out if we see these sporadic
failures in the CI.

Fixes #328

Signed-off-by: Archana Shinde <archana.m.shinde@intel.com>
2019-07-02 12:02:54 -07:00
GabyCT
212b219e9e
Merge pull request #597 from chavafg/topic/static-qemu-patches
static-qemu: Apply qemu patches from this repo.
2019-07-02 10:00:13 -05:00
Jose Carlos Venegas Munoz
b94dafa980
Merge pull request #1849 from jodh-intel/fix-borken-url
docs: Fix broken URL
2019-07-02 08:04:26 -05:00
James O. D. Hunt
f1a43ac4c6 docs: Fix broken URL
Update broken Clear Linux stateless URL.

Fixes: #1846.

Signed-off-by: James O. D. Hunt <james.o.hunt@intel.com>
2019-07-02 08:41:33 +01:00