Commit Graph

9017 Commits

Author SHA1 Message Date
Maksym Pavlenko
3f406d4af6 Cleanup vendor
Signed-off-by: Maksym Pavlenko <pavlenko.maksym@gmail.com>
2021-03-27 15:53:20 -07:00
Maksym Pavlenko
d56b49c13d Rewrite Docker hosts parser
Signed-off-by: Maksym Pavlenko <pavlenko.maksym@gmail.com>
2021-03-27 15:39:46 -07:00
Kazuyoshi Kato
e1f51ba73d Use os.File#Seek() to get the size of a block device
Instead of calling blockdev(1), this change uses os.File#Seek which
would be more effecient.

https://github.com/firecracker-microvm/firecracker/pull/1371

Signed-off-by: Kazuyoshi Kato <katokazu@amazon.com>
2021-03-26 10:14:38 -07:00
Mike Brown
1b05b605c8
Merge pull request #5145 from aojea/happyeyeballs
use (sort of) happy-eyeballs for port-forwarding
2021-03-26 09:51:29 -05:00
Phil Estes
effe226d9d
Merge pull request #5258 from fuweid/checkpoint-on-pause-state
task: allow checkpoint on pause state
2021-03-26 09:44:04 -04:00
Maksym Pavlenko
ddd4298a10 Migrate current TOML code to github.com/pelletier/go-toml
Signed-off-by: Maksym Pavlenko <pavlenko.maksym@gmail.com>
2021-03-25 13:13:33 -07:00
Maksym Pavlenko
499c2f7d4a Vendor github.com/pelletier/go-toml
Signed-off-by: Maksym Pavlenko <pavlenko.maksym@gmail.com>
2021-03-25 13:10:52 -07:00
Derek McGowan
75a0c2b7d3
Merge pull request #5264 from mxpv/tests
Run unit tests on CI for MacOS
2021-03-25 09:46:25 -07:00
Derek McGowan
ed8cf6077e
Merge pull request #5267 from estesp/up-integ-timeout
Extend default timeout for nested VM integration run
2021-03-25 09:44:47 -07:00
Derek McGowan
7b17a29da0
Merge pull request #5262 from cpuguy83/ci_cross_compile
Add CI job to cross compile all the things
2021-03-25 09:44:12 -07:00
Phil Estes
219f1395b2
Merge pull request #5268 from thaJeztah/no_klog
integration/util: remove dependency on k8s.io/klog/v2
2021-03-25 11:51:29 -04:00
Sebastiaan van Stijn
61c7490368
integration/util: remove dependency on k8s.io/klog/v2
Having this log should not be critical, and removing it allows
using this package without pulling in the explicit dependency
on k8s.io/klog.

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2021-03-25 15:09:03 +01:00
Phil Estes
4f7d1d74fb
Merge pull request #5260 from fuweid/limit-concurent-uploads-when-push
remotes/ctr: allow to limit max concurrent uploads like downloads
2021-03-25 09:22:44 -04:00
Phil Estes
f2d84035f6
Merge pull request #5266 from Ace-Tang/ace
ctr: add --user for task exec
2021-03-25 09:17:52 -04:00
Phil Estes
d9765f7bff
Extend default timeout for nested VM integration run
When integration tests are run under nested VM (for SELinux, Cgroupsv2
testing) they are regularly starting to push past 10 minutes, causing
`go test` to fatally kill the test run (default timeout is 10m).

Signed-off-by: Phil Estes <estesp@amazon.com>
2021-03-25 09:12:41 -04:00
acetang
5e94745f26 ctr: add --user for task exec
set user in exec container

$ ctr t exec --exec-id e1 --user admin container id
uid=500(admin) gid=500(admin) groups=500(admin)

Signed-off-by: chuangxue <chenglong.lcl@alibaba-inc.com>
Signed-off-by: acetang <aceapril@126.com>
2021-03-25 19:29:30 +08:00
Wei Fu
f8c2f04756 remotes/ctr: allow to limit max concurrent uploads like downloads
Also add flags for push/pull subcommand to limit max concurrent
uploads/downloads.

Signed-off-by: Wei Fu <fuweid89@gmail.com>
2021-03-25 14:37:02 +08:00
Fu, Wei
80fa9fe32a
Merge pull request #5135 from AkihiroSuda/default-config-crypt
add imgcrypt stream processors to the default config
2021-03-25 14:31:38 +08:00
Maksym Pavlenko
4674ad7beb Ignore some tests on darwin
Signed-off-by: Maksym Pavlenko <pavlenko.maksym@gmail.com>
2021-03-24 22:40:22 -07:00
Maksym Pavlenko
55450e7730 Run unit tests on CI for MacOS
Though we don't officially support Apple platform, we should
at least run unit tests to make sure things are not broken.

Signed-off-by: Maksym Pavlenko <pavlenko.maksym@gmail.com>
2021-03-24 22:10:04 -07:00
Brian Goff
311e326a1c Add CI job to cross compile all the things
This makes sure we can compile on all the platforms and prevent things
like integer overflows.

Signed-off-by: Brian Goff <cpuguy83@gmail.com>
2021-03-24 22:57:56 +00:00
Brian Goff
10a498c7c8 Update go-winio to fix compile error on armv7
Signed-off-by: Brian Goff <cpuguy83@gmail.com>
2021-03-24 22:56:24 +00:00
Brian Goff
1a9c6f557b Revendor zfs to to fix integer overflow
This currently breaks armhf builds.

Signed-off-by: Brian Goff <cpuguy83@gmail.com>
2021-03-24 21:37:17 +00:00
Mike Brown
548d984f27
Merge pull request #5132 from mikebrow/add-some-debug-out-for-dep-setups
adds a new install-deps in the makefile; and some refactoring of the scripts
2021-03-24 15:28:16 -05:00
Phil Estes
bcda849e7c
Merge pull request #5133 from TBBle/correct-cleanup-of-windows-layers-in-test
Correct clean-up of Windows Layers in testsuite
2021-03-24 16:03:11 -04:00
Paul "TBBle" Hampson
1fd3d12f93 go mod tidy the client integration test module
Signed-off-by: Paul "TBBle" Hampson <Paul.Hampson@Pobox.com>
2021-03-25 05:26:24 +11:00
Paul "TBBle" Hampson
da7d96ba3f Clean up WCOW layers after tests in the correct order
This ensures that we do not trigger assertions inside HCS by tring to
call hcsshim.DestroyLayer on the parent of a currently-activated layer.

It also deactivates the layers before deletion, to ensure we trigger or
avert file-in-use failures due to leftover state from the tests with
more detail than 'destroy failed'.

Signed-off-by: Paul "TBBle" Hampson <Paul.Hampson@Pobox.com>
2021-03-25 05:26:24 +11:00
Mike Brown
9ad87b9ba7 adds critools-version
Signed-off-by: Mike Brown <brownwm@us.ibm.com>
2021-03-24 10:58:40 -05:00
Wei Fu
72b7f4bab1 task: allow checkpoint on pause state
task.Checkpoint should check status of container before handle
checkpoint. If the container has been paused, task.Checkpoint should
handle checkpoint and leave it paused.

Signed-off-by: Wei Fu <fuweid89@gmail.com>
Signed-off-by: Baijia <baijia.wr@antfin.com>
2021-03-24 16:37:39 +08:00
Derek McGowan
31a0f92df1
Merge pull request #5234 from mxpv/http-dbg
Support HTTP debug in ctr
2021-03-23 19:05:57 -07:00
Maksym Pavlenko
181e2d4216
Merge pull request #5250 from dmcgowan/cri-fix-reference-ordering
Fix reference ordering in CRI image store
2021-03-23 14:45:16 -07:00
Mike Brown
664088dd2e
Merge pull request #5254 from voltbit/clarify-cri-registry-doc
Make CRI registry docs more clear
2021-03-23 16:11:04 -05:00
Andrei Dobre
e4b9b1038b
Make CRI registry docs more clear
Added reference to previous config syntax.

Signed-off-by: Andrei Dobre <andreidobre.web@gmail.com>
2021-03-23 22:10:06 +02:00
Michael Crosby
2ad54a2cde
Merge pull request #5255 from dmcgowan/bump-linux-integration-timeout
Increase timeout for linux integration tests
2021-03-23 16:03:15 -04:00
Maksym Pavlenko
792336b09b
Merge pull request #5245 from mxpv/oom
Fix oom tests on non Linux
2021-03-23 12:34:32 -07:00
Derek McGowan
ec4d7736d8
Increase timeout for linux integration tests
The integration test times have slightly increased and are often
hitting the 25 minutes timeout. This increases to give more room
but still keeps it low enough to catch regressions in tests
causing longer than expected execution.

Signed-off-by: Derek McGowan <derek@mcg.dev>
2021-03-23 12:10:41 -07:00
Maksym Pavlenko
eb7c7c71e2 Fix oom tests on non Linux
Signed-off-by: Maksym Pavlenko <pavlenko.maksym@gmail.com>
2021-03-23 11:57:24 -07:00
Derek McGowan
d54225ccee
Merge pull request #5125 from Iceber/add-caller-info 2021-03-23 08:28:20 -07:00
Phil Estes
717dde3c27
Merge pull request #5252 from thaJeztah/separate_userns
Move RunningInUserNS() to its own package
2021-03-23 08:56:04 -04:00
Sebastiaan van Stijn
708299ca40
Move RunningInUserNS() to its own package
This allows using the utility without bringing whole of "sys" with it.

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2021-03-23 11:29:53 +01:00
Derek McGowan
0886ceaea2
Fix reference ordering in CRI image store
Currently image references end up being stored in a
random order due to the way maps are iterated through
in Go. This leads to inconsistent identifiers being
resolved when a single reference is needed to identify
an image and the ordering of the references is used for
the selection.

Sort references in a consistent and ranked manner,
from higher information formats to lower.

Note: A `name + tag` reference is considered higher
information than a `name + digest` reference since a
registry may be used to resolve the digest from a
`name + tag` reference.

Signed-off-by: Derek McGowan <derek@mcg.dev>
2021-03-22 22:29:57 -07:00
Iceber Gu
bf9db47e8a
add caller info to the testHook
Signed-off-by: Iceber Gu <wei.cai-nat@daocloud.io>
2021-03-23 09:26:27 +08:00
Derek McGowan
edf6484165
Merge pull request #5243 from AkihiroSuda/update-zfs-20210322
go.mod: github.com/containerd/zfs v0.0.0-20210322090317-0e92c2247fb7 (for snapshot usage)
2021-03-22 15:09:58 -07:00
Antonio Ojea
305b425830 use happy-eyeballs for port-forwarding
golang has enabled RFC 6555 Fast Fallback (aka HappyEyeballs)
by default in 1.12.
It means that if a host resolves to both IPv6 and IPv4,
it will try to connect to any of those addresses and use the
working connection.
However, the implementation uses go routines to start both connections in parallel,
and this has limitations when running inside a namespace, so we try to the connections
serially, trying IPv4 first for keeping the same behaviour.
xref https://github.com/golang/go/issues/44922

Signed-off-by: Antonio Ojea <aojea@redhat.com>
2021-03-22 20:15:24 +01:00
Maksym Pavlenko
22ef69d77d Support HTTP debug in ctr
Signed-off-by: Maksym Pavlenko <pavlenko.maksym@gmail.com>
2021-03-22 09:32:34 -07:00
Derek McGowan
4e919ffaba
Merge pull request #5244 from pacoxu/fix/night-run 2021-03-22 06:12:03 -07:00
pacoxu
01765d0974 night ci fix: add packages for ubuntu 20.04
Signed-off-by: pacoxu <paco.xu@daocloud.io>
2021-03-22 17:57:14 +08:00
Akihiro Suda
8cdc1f13b6
go.mod: github.com/containerd/zfs v0.0.0-20210322090317-0e92c2247fb7
Contains "Implements zfs usage by returning the USED field from the zfs snapshot"
(https://github.com/containerd/zfs/pull/38)

Signed-off-by: Akihiro Suda <akihiro.suda.cz@hco.ntt.co.jp>
2021-03-22 16:58:00 +09:00
Maksym Pavlenko
56f17a0856
Merge pull request #5148 from wzshiming/fix/defer-cleanup
runtime/v2: Fix defer cleanup for TaskManager.Create
2021-03-20 13:24:42 -07:00
Shiming Zhang
30e1e66e5c runtime/v2: Fix defer cleanup
Signed-off-by: Shiming Zhang <wzshiming@foxmail.com>
2021-03-20 18:40:36 +08:00