Commit Graph

31 Commits

Author SHA1 Message Date
Kyle L Frisbie
0119d43a41
use raw link to containerd.servic config
Referencing the raw link to the containerd.service may enhance the developer experience by enabling those following the docs to use the raw link directly to `wget` or `curl` the file without additional navigation.

Signed-off-by: Kyle L Frisbie <KyleFrisbie@users.noreply.github.com>
2022-10-02 14:36:59 -06:00
Derek McGowan
281c2b8f90
Merge pull request #7103 from 2000yeshu/fix-doc
Fix Documentation Issue
2022-06-27 10:58:12 -07:00
Yakul Garg
47ad5f70e7 Fix Doc:
since containerd doesn't have GenerateSpec method any longer, spec has to be generated with WithNewSpec.

Signed-off-by: Yakul Garg <2000yeshu@gmail.com>
2022-06-25 12:09:30 +05:30
Shaun Lawrie
b5107a8984
Fix Windows install powershell script
Signed-off-by: Shaun Lawrie <beatbophiphop@gmail.com>
2022-05-21 19:31:17 +12:00
Mark Rossetti
9b04d2fae2 docs: Adding windows installation steps to getting-started.md
Signed-off-by: Mark Rossetti <marosset@microsoft.com>
2022-04-28 13:46:17 -07:00
Akihiro Suda
83665bf8d2
docs/getting-started.md: typo
Signed-off-by: Akihiro Suda <akihiro.suda.cz@hco.ntt.co.jp>
2022-04-05 15:56:21 +09:00
Akihiro Suda
6f269ccb3c
docs/getting-started.md: massive update
The previous documentation was too much forcusing on the Go API and not useful
for users who are not interested in implementing their own containerd client.
It was also recommending the deprecated way (cri-containerd-*.tar.gz) to install
containerd and its dependencies.

The new documentation recommends the current official way to install containerd,
and provides several links for end users.

This will replace the content of https://containerd.io/docs/getting-started/
after merging the containerd/containerd.io PR 120.

Signed-off-by: Akihiro Suda <akihiro.suda.cz@hco.ntt.co.jp>
2022-04-01 20:45:17 +09:00
Quan Tian
59b1871b30 Fix link in getting-started.md
Signed-off-by: Quan Tian <qtian@vmware.com>
2022-03-11 22:29:44 +08:00
Phil Estes
2b68c03a60
Update Go version recommendation in getting started
Signed-off-by: Phil Estes <estesp@amazon.com>
2022-02-23 15:48:19 -05:00
Romain Aviolat
ebc5cf19ac
feat(doc): update to version 2 syntax
Signed-off-by: Romain Aviolat <r.aviolat@gmail.com>
2021-10-21 19:06:47 +02:00
Derek McGowan
7dffdfa560
Move documentation and helper directories out of root
Signed-off-by: Derek McGowan <derek@mcg.dev>
2021-01-12 12:19:50 -08:00
Kazuyoshi Kato
03cc4cedc5 docs: fix broken links
This change fixes broken links in docs/.

Signed-off-by: Kazuyoshi Kato <katokazu@amazon.com>
2020-11-11 10:19:17 -08:00
Brian Goff
8574083153 This config no longer exists, so remove from docs.
This was changed to `no_subreaper` in
6e9f24b711 and, as far as I can tell,
`no_subreaper` doesn't exist as a config anymore.

Signed-off-by: Brian Goff <cpuguy83@gmail.com>
2020-04-17 14:14:35 -07:00
Luc Perkins
e5e63539a6 Return Markdown files to /docs directory
Signed-off-by: Luc Perkins <lucperkins@gmail.com>
2018-05-16 11:23:50 -07:00
Luc Perkins
d1503dc9ce Migrate website to Hugo
Signed-off-by: Luc Perkins <lucperkins@gmail.com>
2018-05-15 12:30:26 -07:00
Lucas Molas
f61f60e01e Update getting-started guide with the new stdio implementation
Signed-off-by: Lucas Molas <lmolas@fundacionsadosky.org.ar>
2017-12-21 13:15:53 -03:00
YaoZengzeng
21c260398d add missing dependency in code example
Signed-off-by: YaoZengzeng <yaozengzeng@zju.edu.cn>
2017-12-08 15:53:23 +08:00
Ace-Tang
aca8e15916 docs: fix usage of cio package in docs
Signed-off-by: Ace-Tang <aceapril@126.com>
2017-12-05 00:07:08 +08:00
Daniel Nephin
cdf62f69a1 Fix usage of oci in other packages.
Signed-off-by: Daniel Nephin <dnephin@gmail.com>
2017-11-27 16:16:17 -05:00
bando-shintaro
5128f034b8 Fix docs, log output in getting started
Signed-off-by: bando-shintaro <bando142141@gmail.com>
2017-11-05 23:25:27 +09:00
Ian Campbell
680bab8468 Update docs with go 1.9 requirement.
re: #1632

The comment about plugins in README.md didn't seem relevant any longer so I
removed it.

Signed-off-by: Ian Campbell <ian.campbell@docker.com>
2017-10-12 15:06:36 +01:00
Michael Crosby
d7864eb77b Use namespace in default cgroup path
By default, the generated spec will place containers in cgroups by their
ids, we need to use the namespace as the cgroup root to avoid
containers with the same name being placed in the same cgroup.

```
11:perf_event:/to/redis
10:freezer:/to/redis
9:memory:/to/redis
8:devices:/to/redis
7:net_cls,net_prio:/to/redis
6:pids:/to/redis
5:hugetlb:/to/redis
4:cpuset:/to/redis
3:blkio:/to/redis
2:cpu,cpuacct:/to/redis
1:name=systemd:/to/redis

11:perf_event:/te/redis
10:freezer:/te/redis
9:memory:/te/redis
8:devices:/te/redis
7:net_cls,net_prio:/te/redis
6:pids:/te/redis
5:hugetlb:/te/redis
4:cpuset:/te/redis
3:blkio:/te/redis
2:cpu,cpuacct:/te/redis
1:name=systemd:/te/redis
```

Signed-off-by: Michael Crosby <crosbymichael@gmail.com>
2017-10-09 17:07:57 -04:00
Phil Estes
fe1e00c06c
Fix example using old GenerateSpec function
This fixes the example in the getting started guide. The full example
was already correct; tested compilation and proper runtime on latest
master.

Signed-off-by: Phil Estes <estesp@linux.vnet.ibm.com>
2017-09-22 15:25:18 -04:00
Michael Crosby
f23edd3cc0 Add v1 to metrics API endpoint
Fixes #1399

This versions the prometheus metrics API so we can manage backwards
incompatible changes in the future more easily.

Signed-off-by: Michael Crosby <crosbymichael@gmail.com>
2017-09-20 16:24:30 -04:00
Michael Crosby
9c207952b0 Add go build and ./main to guide
Signed-off-by: Michael Crosby <crosbymichael@gmail.com>
2017-09-07 11:14:37 -04:00
Roy Inganta Ginting
34a58ce0d4 Improve the getting started guide
Here is list of improvement:
- Add 2 intermediate full samples of code that can be compiled and ran
- Link to Runc.md page for runc installation
- Fix typo at the "Task Wait and Start" section
- Fix missing commands to run sample code at the getting stated guide
- Explicitly State go 1.8.x or above and link back to golang install page

Signed-off-by: Roy Inganta Ginting <ringanta.ginting@gmail.com>
2017-09-07 11:12:37 -04:00
Michael Crosby
2052b76fa7 Change WithSpec to take SpecOpts
Signed-off-by: Michael Crosby <crosbymichael@gmail.com>
2017-08-24 14:32:41 -04:00
Michael Crosby
c601606f84 Move spec generation to Container Create
Signed-off-by: Michael Crosby <crosbymichael@gmail.com>
2017-08-24 10:32:16 -04:00
Brian Goff
6ab99edb71 Convert ExitStatus to use fn to get details
Instead of requiring callers to read the struct fields to check for an
error, provide the exit results via a function instead which is more
natural.

Signed-off-by: Brian Goff <cpuguy83@gmail.com>
2017-08-22 10:48:44 -04:00
Brian Goff
026896ac4c Make Wait() async
In all of the examples, its recommended to call `Wait()` before starting
a process/task.
Since `Wait()` is a blocking call, this means it must be called from a
goroutine like so:

```go
statusC := make(chan uint32)
go func() {
  status, err := task.Wait(ctx)
  if err != nil {
    // handle async err
  }

  statusC <- status
}()

task.Start(ctx)
<-statusC
```

This means there is a race here where there is no guarentee when the
goroutine is going to be scheduled, and even a bit more since this
requires an RPC call to be made.
In addition, this code is very messy and a common pattern for any caller
using Wait+Start.

Instead, this changes `Wait()` to use an async model having `Wait()`
return a channel instead of the code itself.
This ensures that when `Wait()` returns that the client has a handle on
the event stream (already made the RPC request) before returning and
reduces any sort of race to how the stream is handled by grpc since we
can't guarentee that we have a goroutine running and blocked on
`Recv()`.

Making `Wait()` async also cleans up the code in the caller drastically:

```go
statusC, err := task.Wait(ctx)
if err != nil {
  return err
}

task.Start(ctx)

status := <-statusC
if status.Err != nil {
  return err
}
```

No more spinning up goroutines and more natural error
handling for the caller.

Signed-off-by: Brian Goff <cpuguy83@gmail.com>
2017-08-22 09:33:07 -04:00
Michael Crosby
d6c171ea89 Add getting started guide
Signed-off-by: Michael Crosby <crosbymichael@gmail.com>
2017-08-07 09:17:27 -04:00