Commit graph

2105 commits

Author SHA1 Message Date
Antonio Murdaca
e344ad105a
Merge pull request #1116 from nalind/storage-update-2
Update containers/image and containers/storage
2017-12-15 17:01:29 +01:00
Antonio Murdaca
43119a7b13
Merge branch 'lock-free-ops' into moar-tests
* lock-free-ops:
  lib,oci: drop stateLock when possible
2017-12-15 16:46:42 +01:00
Antonio Murdaca
ecc572e7cf
lib,oci: drop stateLock when possible
Should fix a possible deadlock in, at least, ListPodSandbox.
There seems to be no reason to hold stateLock when doing operations on
the memory_store for containers and sandboxes.

Signed-off-by: Antonio Murdaca <runcom@redhat.com>
2017-12-15 15:31:58 +01:00
Antonio Murdaca
455245e65b
bump runc to c6e4a1ebeb1a72b529c6f1b6ee2b1ae5b868b14f
Signed-off-by: Antonio Murdaca <runcom@redhat.com>
2017-12-15 14:33:44 +01:00
Antonio Murdaca
7d2bde110a
contrib: test: integration: enable more e2e kube tests
Signed-off-by: Antonio Murdaca <runcom@redhat.com>
2017-12-14 22:21:42 +01:00
Nalin Dahyabhai
fa90249c59 Playbooks: install the atomic-registries package
Install atomic-registries to get a /etc/containers/registries.conf file,
so that we can resolve image names that don't include domain portions.

Signed-off-by: Nalin Dahyabhai <nalin@redhat.com>
2017-12-14 14:23:53 -05:00
Nalin Dahyabhai
72442d0957 Don't skip a critest that we now pass
We can pass the "listImage should get exactly 2 repoTags in the result
image" test now, so we no longer need to skip it.

Signed-off-by: Nalin Dahyabhai <nalin@redhat.com>
2017-12-14 14:23:53 -05:00
Nalin Dahyabhai
0ab8c507f4 Install python-rhsm-certificates, handle python-boto
Add python-rhsm-certificates to the list of packages that we require, so
that the required certificates are available for the
pull-image-with-signature tests.

Add per-distribution package install tasks so that we install either
python2-boto or python-boto, depending on whether we're running on
Fedora or RHEL/CentOS, respectively.

Signed-off-by: Nalin Dahyabhai <nalin@redhat.com>
2017-12-14 14:23:53 -05:00
Nalin Dahyabhai
492f758176 Playbooks: don't assume the default network is eth0
Replace instances of "ansible_eth0.ipv4.address" with
"ansible_default_ipv4.address" in the integration test playbook, so that
we can run tests without depending on the name of the primary network
interface being "eth0".

Signed-off-by: Nalin Dahyabhai <nalin@redhat.com>
2017-12-14 14:23:53 -05:00
Nalin Dahyabhai
893aa4e8c7 Be more diligent about cleaning up failed-to-create containers
If server/Server.createSandboxContainer() fails after calling
server/Server.StorageRuntimeServer().CreateContainer(), cleanup logic in
server/Server.CreateContainer() won't try to clean it up, but we still
need to clean up the on-disk container and its layer.

Signed-off-by: Nalin Dahyabhai <nalin@redhat.com>
2017-12-14 14:23:53 -05:00
Nalin Dahyabhai
6a456d1502 Use crictl instead of crioctl in image integration tests
Use crictl instead of crioctl in some of the integration tests that
exercise image handling.

Signed-off-by: Nalin Dahyabhai <nalin@redhat.com>
2017-12-14 14:23:53 -05:00
Nalin Dahyabhai
5ea050fc12 Handle truncated IDs in imageService.ResolveNames()
Have ResolveNames() check if the value that it's been given is a
truncated version of the ID of a locally-available image, and if it is,
return the value as it was given.

Signed-off-by: Nalin Dahyabhai <nalin@redhat.com>
2017-12-14 14:23:53 -05:00
Nalin Dahyabhai
ff7bbb4f0d Switch to ImageServer.UntagImage in RemoveImage handler
Add an UntagImage() method to pkg/storage/ImageServer, which will check
if the passed-in NameOrID is a name.  If so, it merely removes that name
from the image, removing the image only if it was the last name that the
image had.  If the NameOrID is an image ID, the image is removed, as
RemoveImage() does.

Signed-off-by: Nalin Dahyabhai <nalin@redhat.com>
2017-12-14 14:23:53 -05:00
Nalin Dahyabhai
f3b7065bd8 Return image references from the storage package
The image's canonical reference is a name with a digest of the image's
manifest, so in imageService.ImageStatus() and
imageService.ListImages(), divide the image's name list into tagged and
digested values, and if we have names, add canonical versions.

In Server.ContainerStatus(), return the image name as it was given to us
as the image, and the image digested reference as the image reference.

In Server.ListImages(), be sure to only return tagged names in the
RepoTags field.  In Server.ImageStatus(), also return canonical
references in the RepoDigests field.

In Server.PullImage(), be sure that we consistently return the same
image reference for an image, whether we ended up pulling it or not.

Signed-off-by: Nalin Dahyabhai <nalin@redhat.com>
2017-12-14 14:23:52 -05:00
Nalin Dahyabhai
553979e1fc storage: API fixups
github.com/containers/image/types.ImageReference.NewImage() can take a
*github.com/containers/image/types.SystemContext now, so pass it one if
pkg/storage/imageService.CanPull() has one to give it.

Signed-off-by: Nalin Dahyabhai <nalin@redhat.com>
2017-12-14 11:06:55 -05:00
Nalin Dahyabhai
0651d3a8de Update containers/image and containers/storage
Bump containers/image to 3d0304a02154dddc8f97cc833aa0861cea5e9ade, and
containers/storage to 0d32dfce498e06c132c60dac945081bf44c22464.

Signed-off-by: Nalin Dahyabhai <nalin@redhat.com>
2017-12-14 11:06:23 -05:00
Mrunal Patel
2fa1f3f74a
Merge pull request #1221 from runcom/split-critest-from-e2e
CI: split critest from e2e
2017-12-13 16:53:20 -08:00
Antonio Murdaca
d91df68638
CI: split critest from e2e
Signed-off-by: Antonio Murdaca <runcom@redhat.com>
2017-12-14 00:09:36 +01:00
Mrunal Patel
da50e6ca11
Merge pull request #1197 from runcom/sys-cont
contrib: import system containers
2017-12-13 09:22:55 -08:00
Mrunal Patel
ebc249cad8
Merge pull request #1214 from runcom/fix-1.10-vendor
vendor: bump to kube 1.10/master
2017-12-11 11:14:15 -08:00
Antonio Murdaca
f317ffce5b
vendor: bump to kube 1.10/master
Signed-off-by: Antonio Murdaca <runcom@redhat.com>
2017-12-11 16:45:48 +01:00
Mrunal Patel
a85ea609db
Merge pull request #1207 from runcom/fix-exec-termianl
container_exec: fix terminal true process json
2017-12-07 14:44:38 -08:00
Antonio Murdaca
afeab27a36
container_exec: fix terminal true process json
Signed-off-by: Antonio Murdaca <runcom@redhat.com>
2017-12-07 20:51:05 +01:00
Mrunal Patel
1f3fbdc987
Merge pull request #1206 from nlacasse/state-ignore-stderr
Only parse stdout from "state" command.  Ignore stderr.
2017-12-07 11:29:25 -08:00
Nicolas Lacasse
1138af9e59 Don't parse stderr as json when calling "state" command.
Some oci runtimes may used stderr for logging.  Cri-o should not try to
parse this output as json when calling the "state" command.

Signed-off-by: Nicolas Lacasse <nlacasse@google.com>
2017-12-06 09:52:54 -08:00
Antonio Murdaca
06904d4dbb
contrib: import system containers
Signed-off-by: Antonio Murdaca <runcom@redhat.com>
2017-12-02 12:24:40 +01:00
Mrunal Patel
85f303f3ff
Merge pull request #1198 from runcom/list-sandboxes-refactor
lib: sandbox: refactor to memory store
2017-12-01 11:36:46 -08:00
Mrunal Patel
989d275e76
Merge pull request #1170 from alexandrst88/fix-tutorial
Update install.md relevant documentation
2017-12-01 09:20:38 -10:00
Antonio Murdaca
d168fc5fec
lib: sandbox: refactor to memory store
Signed-off-by: Antonio Murdaca <runcom@redhat.com>
2017-12-01 18:16:08 +01:00
Daniel J Walsh
b9ffd277b9
Merge pull request #1192 from runcom/no-libkpod
libkpod -> lib rename
2017-12-01 08:44:44 -05:00
Antonio Murdaca
910cfab6e9
Merge pull request #910 from sameo/topic/bats
test: Add timeout before checking for status
2017-12-01 13:30:13 +01:00
Samuel Ortiz
a2e08d5dc4 test: Add timeout before checking for status
Under some slow environment (nested VMs) or with some
not as fast runtimes (Clear Containers), asking for a
status right away is racy.

Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2017-12-01 10:21:50 +01:00
Antonio Murdaca
0eaa52c356
Merge pull request #1184 from willstudy/unit_test
Adding unit tests for server/secrets.go
2017-12-01 10:04:30 +01:00
Antonio Murdaca
0ab5e80c38
Merge pull request #1193 from mrunalp/go_1.8.5
Bump up go version to 1.8.5
2017-11-30 22:19:34 +01:00
Mrunal Patel
2cae11ba35 Merge pull request #1189 from runcom/fix-apparmor-master
container_create: fix apparmor from container config
2017-11-30 08:56:46 -10:00
Mrunal Patel
40da5c2c16
Merge pull request #1186 from runcom/fixups-env-master
Fix env handling on exec
2017-11-30 08:54:33 -10:00
Antonio Murdaca
b8bba70f99
libkpod -> lib rename
Signed-off-by: Antonio Murdaca <runcom@redhat.com>
2017-11-30 17:08:26 +01:00
Mrunal Patel
32d2c2d57c Bump up go version to 1.8.5
Signed-off-by: Mrunal Patel <mrunalp@gmail.com>
2017-11-30 08:02:02 -08:00
Antonio Murdaca
c8aad704dd
container_create: fix apparmor from container config
Signed-off-by: Antonio Murdaca <runcom@redhat.com>
2017-11-30 16:12:16 +01:00
Antonio Murdaca
ea0bf448fe
test: add exec/execsync env conflict test
Signed-off-by: Antonio Murdaca <runcom@redhat.com>
2017-11-30 12:54:58 +01:00
Antonio Murdaca
902acca4af
container_create: correctly set image and kube envs
Signed-off-by: Antonio Murdaca <runcom@redhat.com>
2017-11-30 12:28:50 +01:00
Antonio Murdaca
b59f31a2d5
oci: do not append conmon env to container process
Signed-off-by: Antonio Murdaca <runcom@redhat.com>
2017-11-30 11:23:42 +01:00
Antonio Murdaca
c6f68f1bf1
container_exec: use process file with runc exec
Signed-off-by: Antonio Murdaca <runcom@redhat.com>
2017-11-30 11:23:37 +01:00
Oleksandr Stepanov
a71948e9e7
Fixed install.md documentation
Signed-off-by: Oleksandr Stepanov <alexandrst88@gmail.com>
2017-11-30 10:38:20 +02:00
Mrunal Patel
6faef13293
Merge pull request #1168 from weiwei04/remove_crioctl
remove crioctl source code
2017-11-29 17:06:51 -10:00
Mrunal Patel
b2a78eba2b
Merge pull request #1185 from runcom/fix-runtime-deps
README.md: add all runtime dependencies
2017-11-29 05:47:13 -10:00
Antonio Murdaca
bae4d2241f
README.md: add all runtime dependencies
Signed-off-by: Antonio Murdaca <runcom@redhat.com>
2017-11-29 15:57:17 +01:00
Wei Wei
3006a2159a drop crioctl source code
Signed-off-by: Wei Wei <weiwei.inf@gmail.com>
2017-11-29 21:07:50 +08:00
Antonio Murdaca
5f5a7a3648
Merge pull request #1162 from mrunalp/add_partial_support
conmon: Add support for partial/newline log tags
2017-11-29 11:47:09 +01:00
Liu Chang
c0ad5277e6 Adding unit tests for server/secrets.go
Signed-off-by: Liu Chang <liuchang@qiniu.com>
2017-11-29 17:42:19 +08:00