Commit Graph

205 Commits

Author SHA1 Message Date
Derek McGowan
d2472ecc59
Add CRI release build
Add installation scripts needed to generate CRI + CNI tar package on
release.
Update Github action release script to generate CRI release tarballs for
Linux and Windows.

Signed-off-by: Derek McGowan <derek@mcg.dev>
2020-08-11 09:16:38 -07:00
Jacob Blain Christen
b4376e9865 Update Vagrantfile for testing SELinux
`vagrant up` will build and install containerd and all dependencies,
setting up proper SELinux contexts on the runc and containerd binaries.
The VM is configured to be SELinux Enforcing by default but this gets
changed during various CI passes via a matrix param to Disabled and
Permissive before running tests. I have an open PR to fix the
container-selinux policy for containerd at
https://github.com/containers/container-selinux/pull/98 which once
accepted we will want to update the CI matrix to use Enforcing mode
instead of Permissive.

All tests currently pass in SELinux permissive mode with containerd
configured with `enable_selinux=true`. To see which tests are failing
with SELinux enforcing and an already spun up VM:
`SELINUX=Enforcing vagrant up --provision-with=selinux,test-cri`
To test SELinux enforcing in a new VM:
`vagrant destroy -force; SELINUX=Enforcing vagrant up --provision-with=shell,selinux,test-cri`

The `selinux` shell provisioner, parameterized by the SELINUX envvar,
will configure the system as you would expect, with the side effect that
containerd is configured with `enable_selinux=true` via
`/etc/containerd/config.toml` for Permissive or Enforcing modes and
`enable_selinux=false` when SELINUX=Disabled.

Provided that virtualization is suported, this Vagrantfile and provisioners
make it easy to test containerd/cri for conformance under SELinux on
non-SELinux systems.

Signed-off-by: Jacob Blain Christen <jacob@rancher.com>
2020-08-10 01:55:44 -07:00
Sebastiaan van Stijn
55c9eade39
Bump Golang 1.13.15
full diff: https://github.com/golang/go/compare/go1.13.14...go1.13.15

go1.13.15 (released 2020/08/06) includes security fixes to the encoding/binary
package. See the Go 1.13.15 milestone on the issue tracker for details.

https://github.com/golang/go/issues?q=milestone%3AGo1.13.15+label%3ACherryPickApproved

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2020-08-08 15:07:28 +02:00
Phil Estes
5a190c7077
Remove seccomp/Linux deps steps in GH Actions
Recent changes removed the need for libseccomp-dev when building
containerd. The btrfs tools package is already installed on GH Actions
runners and was already a no-op so the whole step can be removed.

Signed-off-by: Phil Estes <estesp@linux.vnet.ibm.com>
2020-07-31 11:25:26 -04:00
Paul "TBBle" Hampson
aa56cfc0a8 Import Windows manifest into test build, rather than copying by script
This will ensure that we can always get the current Windows OS build
version, without being put into Windows 8 compatibility mode.

Signed-off-by: Paul "TBBle" Hampson <Paul.Hampson@Pobox.com>
2020-07-29 06:02:35 +10:00
Mike Brown
1b320bcc26 update for cni config
Signed-off-by: Mike Brown <brownwm@us.ibm.com>
2020-07-23 13:41:14 -05:00
Akihiro Suda
b97c660e16
cgroup2 CI: add RUNC_FLAVOR=runc
Previously we were only testing cgroup2 with crun

Signed-off-by: Akihiro Suda <akihiro.suda.cz@hco.ntt.co.jp>
2020-07-20 17:53:41 +09:00
Wei Fu
e818fe27ce
Merge pull request #4346 from AkihiroSuda/ci-cgroup2
CI: run CRI tests on Fedora 32
2020-07-18 11:18:02 +08:00
Sebastiaan van Stijn
089672fff4
Bump Golang 1.13.14
full diff: https://github.com/golang/go/compare/go1.13.13...go1.13.14

go1.13.14 (released 2020/07/16) includes fixes to the compiler, vet, and the
database/sql, net/http, and reflect packages. See the Go 1.13.14 milestone on
the issue tracker for details:

https://github.com/golang/go/issues?q=milestone%3AGo1.13.14+label%3ACherryPickApproved

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2020-07-17 15:37:52 +02:00
Akihiro Suda
061d338ec2
CI: run CRI tests on Fedora 32
SELinux is currently disabled

Signed-off-by: Akihiro Suda <akihiro.suda.cz@hco.ntt.co.jp>
2020-07-16 17:27:43 +09:00
Maksym Pavlenko
4318fa9c1f
Merge pull request #4376 from AkihiroSuda/test-v1-shim
CI: add back shim v1 test
2020-07-15 22:21:12 -07:00
Akihiro Suda
b2ee43206b
CI: add back shim v1 test
We are going to deprecate shim v1 (#4365), but it is still early to
disable the tests for them

Signed-off-by: Akihiro Suda <akihiro.suda.cz@hco.ntt.co.jp>
2020-07-16 10:40:47 +09:00
Akihiro Suda
c4418bb3a8
CI: remove an unreferenced variable
Signed-off-by: Akihiro Suda <akihiro.suda.cz@hco.ntt.co.jp>
2020-07-16 10:23:43 +09:00
Phil Estes
7af3d7e176
Don't clash with GH Actions runner's containerd
GH runners now have a systemd-run containerd running on the standard
socket, impacting the CRI test's expectation of our CI-built containerd
running there.

Signed-off-by: Phil Estes <estesp@linux.vnet.ibm.com>
2020-07-15 13:57:32 -04:00
Akihiro Suda
c520f819a2
Bump Go 1.13.13
Includes security fixes to the `crypto/x509` and `net/http` packages.

https://github.com/golang/go/issues?q=milestone%3AGo1.13.13+label%3ACherryPickApproved

Signed-off-by: Akihiro Suda <akihiro.suda.cz@hco.ntt.co.jp>
2020-07-15 14:24:48 +09:00
Phil Estes
7855b0a781
Make title similar with other CI workflow jobs
Signed-off-by: Phil Estes <estesp@linux.vnet.ibm.com>
2020-07-10 15:03:26 -04:00
Akihiro Suda
09f4533941
CI: {v1, v2} -> io.containerd.runc.{v1,v2}
The previous names were confusing because v1 may look like shim API v1 (io.containerd.runtime.v1.linux").
Also, v2 may look like cgroup v2.

Signed-off-by: Akihiro Suda <akihiro.suda.cz@hco.ntt.co.jp>
2020-07-08 14:12:56 +09:00
Sebastiaan van Stijn
a6dd1f27d9
update urfave/cli v1.22.1, go-md2man v2.0.0, blackfriday v2.0.1
This updates urfave/cli and its dependencies to v1.22.1:

- diff for urfave/cli: https://github.com/urfave/cli/compare/v1.22.0...v1.22.1
- diff for go-md2man: https://github.com/cpuguy83/go-md2man/compare/v1.0.10...v2.0.0
- diff for blackfriday: https://github.com/russross/blackfriday/compare/v1.5.2...v2.0.1

Also adds github.com/shurcooL/sanitized_anchor_name as a new dependency, which is
used by russross/blackfriday, but will be removed again in a future update (dependency
is already removed on the v2 branch through russross/blackfriday@919b1f5b9b

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2020-07-02 10:48:45 +02:00
Phil Estes
57a9f0b50d
Minor actions fixes/updates
- always apt-get update before installing packages
- move to tagged official create_release action

The official GH create_release action now has support for body text from
file.

Signed-off-by: Phil Estes <estesp@linux.vnet.ibm.com>
2020-07-01 14:27:10 -04:00
Sebastiaan van Stijn
b96f5f4b52
Fix deprecation warnings in CRI tests due to missing unix:// scheme
[BeforeEach] [k8s.io] Security Context
      /home/runner/work/containerd/containerd/src/github.com/kubernetes-sigs/cri-tools/pkg/framework/framework.go:50
    W0624 12:26:28.532644   30569 util_unix.go:103] Using "/var/run/containerd/containerd.sock" as endpoint is deprecated, please consider using full url format "unix:///var/run/containerd/containerd.sock".
    W0624 12:26:28.532700   30569 util_unix.go:103] Using "/var/run/containerd/containerd.sock" as endpoint is deprecated, please consider using full url format "unix:///var/run/containerd/containerd.sock".

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2020-06-24 14:55:13 +02:00
Akihiro Suda
1a83f9a638
Bump Golang 1.13.12
Signed-off-by: Akihiro Suda <akihiro.suda.cz@hco.ntt.co.jp>
2020-06-22 16:49:31 +09:00
Phil Estes
8fcd5a1f28
Streamline hcs shim release flow
Improvements to acquire/build hcsshim from source in the release
workflow.

Signed-off-by: Phil Estes <estesp@linux.vnet.ibm.com>
2020-06-04 12:23:50 -04:00
Phil Estes
8f959d569a
Merge pull request #4292 from cpuguy83/add_hcsshim_to_release_tar
Add windows hcsshim to release pipeline
2020-06-04 08:56:09 -04:00
Brian Goff
2be80f9997 Add windows hcsshim to release pipeline
Signed-off-by: Brian Goff <cpuguy83@gmail.com>
2020-06-03 11:10:33 -07:00
Phil Estes
2bc4e90f6f
Don't inadvertently clip release notes
Specify a much larger linecount for extracting tag annotation from git.

Signed-off-by: Phil Estes <estesp@linux.vnet.ibm.com>
2020-05-28 17:54:08 -04:00
Phil Estes
8e9ba8376e
Merge pull request #4271 from cpuguy83/actions_add_windows_integration
Move windows CI to actions
2020-05-28 11:40:29 -04:00
Phil Estes
bb2b2825b6
Add release GH Action triggered by signed tag
This will check that the tag is signed and then checkout the tag, build
official binaries, sha256sum the tarball, and upload those assets to the
release, officially generating a release in GitHub from the signed tag.

Signed-off-by: Phil Estes <estesp@linux.vnet.ibm.com>
2020-05-27 16:56:13 -04:00
Brian Goff
c376f4f763 Move Windows testing to GH Actions
This eliminates the need for appveyor.

Signed-off-by: Brian Goff <cpuguy83@gmail.com>
2020-05-27 10:45:22 -07:00
Akihiro Suda
af131d7258 cgroup2 CI
Signed-off-by: Akihiro Suda <akihiro.suda.cz@hco.ntt.co.jp>
2020-05-22 01:15:12 +09:00
Sebastiaan van Stijn
d07a71b97f
Bump Golang 1.13.11
full diff: https://github.com/golang/go/compare/go1.13.10...go1.13.11

go1.13.11 (released 2020/05/14) includes fixes to the compiler. See the Go 1.13.11
milestone on the issue tracker for details:

https://github.com/golang/go/issues?q=milestone%3AGo1.13.11+label%3ACherryPickApproved

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2020-05-16 14:57:04 +02:00
Maksym Pavlenko
b7cf3c68e7
Merge pull request #4258 from estesp/codeql
Add CodeQL Analysis workflow
2020-05-15 10:05:21 -07:00
Phil Estes
0207b7ff0e
Enable running CodeQL on PRs that modify Action
Signed-off-by: Phil Estes <estesp@linux.vnet.ibm.com>
2020-05-15 12:51:48 -04:00
Justin Hutchings
1a06884f18
Add CodeQL Analysis workflow
Signed-off-by: Justin Hutchings <jhutchings1@github.com>
Signed-off-by: Phil Estes <estesp@linux.vnet.ibm.com>
2020-05-15 10:15:46 -04:00
Maksym Pavlenko
563964e9d5 Trigger nightly builds on pull reuqest events
Signed-off-by: Maksym Pavlenko <pavlenko.maksym@gmail.com>
2020-05-14 18:39:32 -07:00
Phil Estes
04985039ce
Merge pull request #4214 from payall4u/bugfix-check-not-exist
Transfer error to ErrNotFound when kill a not exist container
2020-05-11 10:25:02 -04:00
payall4u
b437938d2f
Transfer error to ErrNotFound when kill a not exist container, also add
test case.

Signed-off-by: payall4u <404977848@qq.com>

Add integration test case

Signed-off-by: payall4u <404977848@qq.com>
2020-05-11 21:53:43 +08:00
Sebastiaan van Stijn
2c77dc63a4
vendor: update containerd/cri to current master
- Remove dependency on libcontainer/system
- Get rid of socat for port forwarding
- Roll docker/distribution back to latest (v2.7.1) release
  Now that 901bcb2231 was merged in containerd,
  we no longer depend on the ParseDockerRef utility from docker/distribution,
  so we can safely roll back to the latest release for this dependency.
- vendor: kubernetes v1.18.2
  Fix client watch reestablishment handling of client-side timeouts
- Add config flag to default empty seccomp profile

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2020-05-11 09:09:39 +02:00
fahedouch
24b331ad1e omit sudo when EUID eqto 0
Signed-off-by: fahedouch <fahed.dorgaa@gmail.com>

omit sudo when EUID eqto 0

Signed-off-by: fahedouch <fahed.dorgaa@gmail.com>

omit sudo when EUID eqto 0

Signed-off-by: fahedouch <fahed.dorgaa@gmail.com>

omit sudo when EUID eqto 0

Signed-off-by: fahedouch <fahed.dorgaa@gmail.com>

use gosu to omit sudo in GA

Signed-off-by: fahedouch <fahed.dorgaa@gmail.com>

use gosu to omit sudo in GA

Signed-off-by: fahedouch <fahed.dorgaa@gmail.com>

set working-dir for <<Setup gosu>> step

Signed-off-by: fahedouch <fahed.dorgaa@gmail.com>

fix job permissions

Signed-off-by: fahedouch <fahed.dorgaa@gmail.com>
2020-05-05 20:13:27 +02:00
Phil Estes
74ceb35f50
Small fixes to our Actions CI workflow
Integration tests were running with latest Go release rather than the
version used everywhere else. Also, we don't need to install protoc from
tarball and also apt-get the package for Ubuntu when used as a
dependency for criu build.

Signed-off-by: Phil Estes <estesp@linux.vnet.ibm.com>
2020-04-15 15:19:01 -04:00
Phil Estes
041545cd6a
Fix protobuild and CI check protos
Signed-off-by: Phil Estes <estesp@linux.vnet.ibm.com>
2020-04-14 14:31:43 -04:00
Sebastiaan van Stijn
a6828e8c39
CI: Some Go 1.13.10 updates that were missed
This file was still on Go 1.13.8, which caused it to be
missed when updating Go 1.13.9 to 1.13.10

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2020-04-09 23:33:50 +02:00
Sebastiaan van Stijn
7da1e13b5d
Bump Golang 1.13.10
go1.13.10 (released 2020/04/08) includes fixes to the go command, the runtime,
os/exec, and time packages. See the Go 1.13.10 milestone on the issue tracker
for details:

https://github.com/golang/go/issues?q=milestone%3AGo1.13.10+label%3ACherryPickApproved

full diff: https://github.com/golang/go/compare/go1.13.9...go1.13.10

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2020-04-09 22:03:48 +02:00
Phil Estes
d7c2513ff3
Update integration test timeout
Also few changes to names of workflow jobs. Integration tests can get
canceled without full completing at 10 minutes. Make sure we only use
checkout v2 action.

Signed-off-by: Phil Estes <estesp@linux.vnet.ibm.com>
2020-04-07 16:34:54 -04:00
Maksym Pavlenko
6d4429edde Setup dependencies between jobs
Signed-off-by: Maksym Pavlenko <makpav@amazon.com>
2020-04-06 13:02:07 -07:00
Maksym Pavlenko
e598e5e0c6 Add CRI tests
Signed-off-by: Maksym Pavlenko <makpav@amazon.com>
2020-04-05 13:02:10 -07:00
Maksym Pavlenko
4175ebf236 Move integration tests to Github Actions
Signed-off-by: Maksym Pavlenko <makpav@amazon.com>
2020-04-05 12:56:32 -07:00
Maksym Pavlenko
599547d9cb Make binaries with Github Actions
Signed-off-by: Maksym Pavlenko <makpav@amazon.com>
2020-04-05 12:53:40 -07:00
Sebastiaan van Stijn
aa76d95375
Bump Golang 1.13.9
go1.13.9 (released 2020/03/19) includes fixes to the go command, tools, the
runtime, the toolchain, and the crypto/cypher package. See the Go 1.13.9
milestone on the issue tracker for details:

https://github.com/golang/go/issues?q=milestone%3AGo1.13.9+label%3ACherryPickApproved

full diff: https://github.com/golang/go/compare/go1.13.8...go1.13.9

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2020-04-03 19:55:37 +02:00
Maksym Pavlenko
e4cbbc78bf Move checks to Github actions
Signed-off-by: Maksym Pavlenko <makpav@amazon.com>
2020-03-28 18:59:51 -07:00
Sebastiaan van Stijn
499ab8a99a
Update Golang 1.13.8
full diff: https://github.com/golang/go/compare/go1.13.7...go1.13.8

go1.13.8 (released 2020/02/12) includes fixes to the runtime, the crypto/x509,
and net/http packages. See the Go 1.13.8 milestone on the issue tracker for details.

https://github.com/golang/go/issues?q=milestone%3AGo1.13.8+label%3ACherryPickApproved

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2020-02-17 17:18:25 +01:00
Sebastiaan van Stijn
32ba75f0fb
Update Golang 1.13.7 (CVE-2020-0601, CVE-2020-7919)
full diff: https://github.com/golang/go/compare/go1.13.6...go1.13.7

go1.13.7 (released 2020/01/28) includes two security fixes. One mitigates
the CVE-2020-0601 certificate verification bypass on Windows. The other affects
only 32-bit architectures.

https://github.com/golang/go/issues?q=milestone%3AGo1.13.7+label%3ACherryPickApproved

- X.509 certificate validation bypass on Windows 10
  A Windows vulnerability allows attackers to spoof valid certificate chains when
  the system root store is in use. These releases include a mitigation for Go
  applications, but it’s strongly recommended that affected users install the
  Windows security update to protect their system.
  This issue is CVE-2020-0601 and Go issue golang.org/issue/36834.
- Panic in crypto/x509 certificate parsing and golang.org/x/crypto/cryptobyte
  On 32-bit architectures, a malformed input to crypto/x509 or the ASN.1 parsing
  functions of golang.org/x/crypto/cryptobyte can lead to a panic.
  The malformed certificate can be delivered via a crypto/tls connection to a
  client, or to a server that accepts client certificates. net/http clients can
  be made to crash by an HTTPS server, while net/http servers that accept client
  certificates will recover the panic and are unaffected.
  Thanks to Project Wycheproof for providing the test cases that led to the
  discovery of this issue. The issue is CVE-2020-7919 and Go issue golang.org/issue/36837.
  This is also fixed in version v0.0.0-20200124225646-8b5121be2f68 of golang.org/x/crypto/cryptobyte.

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2020-01-28 18:35:49 +01:00
Sebastiaan van Stijn
94964b36d0
Update Golang 1.13.6
full diff: https://github.com/golang/go/compare/go1.13.5...go1.13.6

go1.13.6 (released 2020/01/09) includes fixes to the runtime and the net/http
package. See the Go 1.13.6 milestone on the issue tracker for details.

https://github.com/golang/go/issues?q=milestone%3AGo1.13.6+label%3ACherryPickApproved

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2020-01-17 15:54:16 +01:00
Sebastiaan van Stijn
06f6ea099a
switch nighly builds to Go 1.13.5
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2019-12-23 15:29:09 +01:00
Maksym Pavlenko
82651d3867 Cross build nightly builds (arm64, s390x, ppc64el)
Signed-off-by: Maksym Pavlenko <makpav@amazon.com>
2019-11-14 15:29:56 -08:00
Maksym Pavlenko
c479156b81 Add Github workflow for nightly builds
Signed-off-by: Maksym Pavlenko <makpav@amazon.com>
2019-11-13 18:03:35 -08:00