Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Starting containers using ctr failing with parse error #1520

Closed
rmkrjy opened this issue Sep 16, 2017 · 3 comments
Closed

Starting containers using ctr failing with parse error #1520

rmkrjy opened this issue Sep 16, 2017 · 3 comments

Comments

@rmkrjy
Copy link

rmkrjy commented Sep 16, 2017

I am trying to run containers on containerd and runc. But facing the following issue

I have config.json and rootfs in the running directory.

Versions of the tools:

$ sudo ctr containers start .
ctr: filters: parse error: [ >|.|< ]: expected field or quoted: invalid argument: invalid argument
$ sudo ctr -v
ctr github.com/containerd/containerd v1.0.0-beta.0

$ containerd -v
containerd github.com/containerd/containerd v1.0.0-beta.0
$ runc -v
runc version 1.0.0-rc4
spec: 1.0.0

@stevvooe
Copy link
Member

start is not a subcommand of `containers:

ctr c -h
NAME:
   ctr containers - manage containers (metadata)

USAGE:
   ctr containers command [command options] [filter, ...]

COMMANDS:
     delete, del, rm  deletes one or more existing containers
     label            Set and clear labels for a container.
     info             get info about a container

OPTIONS:
   --quiet, -q  print only the container id
   --help, -h   show help

The default action is to list containers. This will cause . and start to get parsed as filters, which matches nothing.

We should probably add this under containers ls to avoid this confusion. Right now, we don't have a way to just "start" a container via the cli, so you'll have to use run or the Go API client (which is the recommended way to drive containerd).

@estesp
Copy link
Member

estesp commented Sep 22, 2017

I think this is resolved for now with @stevvooe detailing the run command and the fact that start is not a verb for ctr

@estesp estesp closed this as completed Sep 22, 2017
@stevvooe
Copy link
Member

@estesp I wonder if we should look into having a start verb. At this point, we haven't needed for demos, but it would better expose the API. We can revisit this post-1.0.

mauriciovasquezbernal pushed a commit to kinvolk/containerd that referenced this issue Nov 13, 2020
…date

CI: run apt-get update befor apt-get install
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants