Commit graph

278 commits

Author SHA1 Message Date
TomSweeneyRedHat
f92ed659ab Add pause state to ps, touchup kpod man page
Signed-off-by: TomSweeneyRedHat <tsweeney@redhat.com>
2017-10-04 07:42:21 -04:00
Daniel J Walsh
1a41d6ecd4 Remove references to overlay2 in the code
Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2017-09-29 20:34:29 +00:00
Daniel J Walsh
a40aa7ad54 Merge pull request #907 from baude/kpod_kill
Add support for kpod kill
2017-09-28 12:59:38 -04:00
Daniel J Walsh
251f16af80 Merge pull request #883 from umohnani8/libpod
Continue switching commands from libkpod to libpod
2017-09-28 11:09:01 -04:00
baude
7b062cf4c1 Add support for kpod kill
Kill one or more containers using a user-provided signal.  If not signal
is provided, KILL is used.

Signed-off-by: baude <bbaude@redhat.com>
2017-09-28 09:34:21 -05:00
Daniel J Walsh
e70802863e Switch kpod load/push/save to use libpod runtime
Since this is the last use of libpod/images/copy.go,
removing that code

Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2017-09-27 22:33:20 -04:00
baude
3bf23b684a Add kpod wait
Waits on one or more containers to stop and prints the container's
return code

Signed-off-by: baude <bbaude@redhat.com>
2017-09-27 09:03:33 -05:00
Daniel J Walsh
214adee0ef Merge pull request #926 from TomSweeneyRedHat/pause
Add `kpod pause` and `kpod unpause`
2017-09-27 09:33:22 -04:00
Daniel J Walsh
8949e669c9 Modify kpod tag to use libpod runtime interface
Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2017-09-26 16:14:34 -04:00
d6a44bf111
*: allow to not use pivot_root
runc has a `--no-pivot` flag, that uses MS_MOVE instead.

This patch set bubbles up a runtime config to enable using no-pivot
globally.

Signed-off-by: Vincent Batts <vbatts@hashbangbash.com>
2017-09-26 11:35:00 -04:00
Daniel J Walsh
9db7cf1370 Add kpod pause and kpod unpause
Implement the ability to pause and unpause running containers.

Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
Signed-off-by: TomSweeneyRedHat <tsweeney@redhat.com>
2017-09-26 08:38:07 -04:00
Mrunal Patel
4d0270d138 crio: Add flag for --log-size-max
Signed-off-by: Mrunal Patel <mrunalp@gmail.com>
2017-09-25 15:37:10 -07:00
Mrunal Patel
c7f5347673 Add log size max configuration
Signed-off-by: Mrunal Patel <mrunalp@gmail.com>
2017-09-25 15:27:21 -07:00
Mrunal Patel
2e3d5240c2 client: Add crio client package
Signed-off-by: Mrunal Patel <mrunalp@gmail.com>
2017-09-25 11:59:40 -07:00
Daniel J Walsh
5e3c53c172 Merge pull request #909 from rhatdan/lastError
We should not be exiting with exit(1)
2017-09-18 07:46:53 -04:00
Mrunal Patel
7e7a097395 Merge pull request #913 from runcom/v1.0.0-rc2-patches
V1.0.0 rc2 patches
2017-09-17 21:03:54 -07:00
Antonio Murdaca
e26e48ec87
server: add inspect unit test
The inspect endpoint is used mainly in the CRI-O cAdvisor handler.
Let's make sure we don't break it by adding some trivial unit tests.

Signed-off-by: Antonio Murdaca <runcom@redhat.com>
2017-09-17 10:19:29 +02:00
Daniel J Walsh
33fc0231f7 Merge branch 'master' of github.com:kubernetes-incubator/cri-o into lastError
Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2017-09-16 06:10:01 -04:00
Daniel J Walsh
dbc2b404a3 Merge pull request #841 from baude/kpod_pull_name
libkpod/image/copy.go: Add pull by short-name
2017-09-16 05:12:47 -04:00
Daniel J Walsh
d03ea10be2 Merge pull request #890 from mrunalp/bind_docs
docs: Add missing bind option in docs and command help
2017-09-16 05:11:17 -04:00
Mrunal Patel
f59e9dae1c docs: Add missing bind option in docs and command help
Signed-off-by: Mrunal Patel <mpatel@redhat.com>
2017-09-15 16:12:13 -07:00
Daniel J Walsh
a001b177d6 We should not be exiting with exit(1)
There is cleanup code that will never get run.
This code will print out all errors and then return the last error.
This should allow for proper cleanup.

Also cleanup help to switch usage and description.
Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2017-09-15 17:51:34 -04:00
umohnani8
036658b844 Modified namespace field in json struct
The namespace field was not being omitted when empty

Signed-off-by: umohnani8 <umohnani@redhat.com>
2017-09-15 17:30:25 -04:00
baude
951a943d16 libkpod/image/copy.go: Add pull by short-name
If the user provides kpod pull a short name like 'debian', we
still want the pull to be sucessful.  As such, when a short
name is provided, we get the list of searchable registries via
the systemregistries code in containers-storage.  We then
append a tag of 'latest' (if not provided) and we formulate
a list of possible fully-qualified image names to try.

Vendor update for containers-storage to bring in the system_registries
code.

Also includes a patch from Nalin to fix compilation errors.

Signed-off-by: baude <bbaude@redhat.com>
2017-09-14 08:33:10 -05:00
Daniel J Walsh
1eb9f8ed8c Merge pull request #887 from baude/kpod_fix_rmi_by_id
cmd/kpod/rmi.go: Fix deletion by ID
2017-09-12 13:44:16 -04:00
Daniel J Walsh
ac5596cf62 Merge pull request #855 from baude/kpod_stop2
kpod stop -- stop one or more containers
2017-09-12 12:27:21 -04:00
baude
aca658b423 kpod stop -- stop one or more containers
Stop one or more containers. Specific a timeout value
that if the stop operation exceeds, will forcibly stop
the container.

Signed-off-by: baude <bbaude@redhat.com>
2017-09-11 17:03:27 -05:00
baude
f0b94a41e8 cmd/kpod/rmi.go: Fix deletion by ID
When deleting by ID, kpod rmi was only "untagging" the image
and not actually removing it.

Signed-off-by: baude <bbaude@redhat.com>
2017-09-11 16:52:57 -05:00
Daniel J Walsh
75a60cf519 Only print error message on kpod error not stacktrace
If the user specifies --debug flag then print stack trace.

Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2017-09-11 19:40:06 +00:00
Daniel J Walsh
c56dcf2cb5 Merge pull request #863 from umohnani8/version
kpod version
2017-09-11 12:10:11 -04:00
umohnani8
12512e418b Update kpod version and info to show beta version
Signed-off-by: umohnani8 <umohnani@redhat.com>
2017-09-10 12:17:43 -04:00
umohnani8
38e9f07844 Add namespace flag to kpod ps
The namespace flag prints out information about the namespaces

Signed-off-by: umohnani8 <umohnani@redhat.com>
2017-09-10 11:21:49 -04:00
Daniel J Walsh
36584e6f34 Merge pull request #830 from umohnani8/update_load-save
Update kpod load and save for oci-archive
2017-09-09 05:58:54 -04:00
Daniel J Walsh
b5ed8b34c0 Merge pull request #843 from baude/kpod_tag
cmd/kpod/tag.go: Do not assume docker.io for tagging
2017-09-09 05:43:15 -04:00
Antonio Murdaca
bb1da978e3 Merge pull request #870 from mrunalp/bump_rc_1
Bump up version to rc 1
2017-09-08 23:34:31 +02:00
Mrunal Patel
77db25f5bb Merge pull request #856 from umohnani8/kpod_ps
Slight modification to kpod ps based on QE feedback
2017-09-08 11:47:27 -07:00
Mrunal Patel
0ae21a5f08 Add support for displaying git commit in version
Signed-off-by: Mrunal Patel <mrunalp@gmail.com>
2017-09-08 10:16:01 -07:00
umohnani8
79c09d4343 Update kpod load and save for oci-archive
Signed-off-by: umohnani8 <umohnani@redhat.com>
2017-09-08 10:33:58 -04:00
umohnani8
216e35db18 Modify the JSON output of kpod history
The JSON output was being modified to type string, fixed that
to be of the same type as the source
This is better for further processing of the JSON output if needed
Restructured kpod history a bit as well

Signed-off-by: umohnani8 <umohnani@redhat.com>
2017-09-08 10:33:09 -04:00
umohnani8
45c7100253 Slight modification to kpod ps based on QE feedback
QE noticed that kpod ps --last 0 was returning the running containers
Fixed that problem so that it returns nothing

Signed-off-by: umohnani8 <umohnani@redhat.com>
2017-09-08 10:32:11 -04:00
Daniel J Walsh
3c468b6f51 Merge pull request #803 from rhatdan/libpod
Move libkpod/image libkpod/layer to libpod/images and libpod/layers
2017-09-07 15:20:31 -04:00
Antonio Murdaca
b8a6d358e7 Merge pull request #562 from rhatdan/hooks
Add support for running oci-hooks
2017-09-07 19:06:01 +02:00
Antonio Murdaca
dacc5c3ece
*: correctly wait and close servers
Signed-off-by: Antonio Murdaca <runcom@redhat.com>
2017-09-07 10:13:21 +02:00
Daniel J Walsh
9f282717da Begin converting kpod pull to use libpod/runtime
We want to drop brute force mechainism for handling image
movement, this patch experiments with moving kpod pull
to use new libpod interfaces.

Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2017-09-06 19:38:47 +00:00
Daniel J Walsh
e18e962238 Move libkpod/image libkpod/layer to libpod/images and libpod/layers
Begin moving image and layer handling out of libkpod into libpod.

Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2017-09-06 19:25:45 +00:00
Mrunal Patel
ac12018973 Merge pull request #814 from runcom/cache-ip-sandbox
cache sandbox's IP address
2017-09-06 09:51:03 -07:00
baude
529eb5bdb7 cmd/kpod/tag.go: Do not assume docker.io for tagging
When performing a tag, if a shortname was provided, tag.go would
preprend docker.io to the shortname through the ParseNormalized
function.  Here we work around that such that is a short name
and tag are provided, the resulting tag will be shortname:tag.  If
a shortname is provided without a tag, we append "latest" as the
tag.

Added specific tag tests too

Signed-off-by: baude <bbaude@redhat.com>
2017-09-06 09:00:00 -05:00
Daniel J Walsh
c88bc13b07 Implement kpod rm
Kpod rm removes a container from the system

Signed-off-by: Ryan Cole <rcyoalne@gmail.com>

Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
Signed-off-by: umohnani8 <umohnani@redhat.com>
2017-09-05 14:35:36 -04:00
Daniel J Walsh
139d0841e8 Add support for oci-hooks to libkpod
Add new directory /etc/crio/hooks.d, where packagers can drop a json config
file to specify a hook.

The json must specify a valid executable to run.
The json must also specify which stage(s) to run the hook:
prestart, poststart, poststop
The json must specify under which criteria the hook should be launched
If the container HasBindMounts
If the container cmd matches a list of regular expressions
If the containers annotations matches a list of regular expressions.
If any of these match the the hook will be launched.

Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2017-09-05 07:39:31 -04:00
Antonio Murdaca
2ac2832686
server: container_create: store sandbox's ip in annotations
So it can be later retrieved when needed (cadvisor)

Signed-off-by: Antonio Murdaca <runcom@redhat.com>
2017-09-02 02:05:58 +02:00