Finish draft of downloads page and update getting started guide

Signed-off-by: lucperkins <lucperkins@gmail.com>
This commit is contained in:
lucperkins 2018-10-18 17:23:30 -07:00
parent 3cd71c2fdd
commit 37dca766b9
8 changed files with 68 additions and 2354 deletions

View File

@ -28,6 +28,9 @@ features = [
"Multi-tenant supported with CAS storage for global images"
]
[params.versions]
latest = "1.2.0-rc.2"
[[params.fonts]]
name = "Lato"
sizes = [300,400,600,700]

View File

@ -19,8 +19,16 @@ If you need to install Go or update your currently installed one, please refer t
## Starting containerd
You can download one of the latest builds for containerd on the [github releases](https://github.com/containerd/containerd/releases) page and then use your favorite process supervisor to get the daemon started.
If you are using systemd, we have a `containerd.service` file at the root of the repository that you can use.
You can download one of the latest source builds for containerd on the [Downloads](/downloads) page and then use your favorite process supervisor to get the daemon started.
To install version {{< latest >}}, for example:
```shell
wget https://github.com/containerd/containerd/archive/v{{< latest >}}.zip
unzip v{{< latest >}}.zip
```
This will extract the containerd source into a `containerd-{{< latest >}}` directory. If you are using systemd, there is a `containerd.service` file at the root of that directory that you can use.
The daemon also uses a configuration file located in `/etc/containerd/config.toml` for specifying daemon level options.
A sample configuration file looks like this:

View File

@ -2,4 +2,27 @@
title: containerd downloads
---
Here is some page content.
containerd [releases](#releases) can be downloaded in each of the following ways:
* As a tarball containing all containerd binaries (`containerd`, `ctr`, etc.)
* As a zip file containing the source code
* As a tarball containing the source code
## Installing binaries
To install the binaries for containerd version **{{< latest >}}**, for example:
```shell
wget https://github.com/containerd/containerd/releases/download/v{{< latest >}}/containerd-{{< latest >}}.linux-amd64.tar.gz
tar xvf containerd-{{< latest >}}.linux-amd64.tar.gz
```
This will extract all containerd binaries into a `bin` folder.
{{< info >}}
For a more comprehensive guide to installing and running containerd, see the [Getting started](../docs/getting-started) guide.
{{< /info >}}
## Releases
{{< releases >}}

View File

@ -1,36 +1,11 @@
{{ define "main" }}
{{- $section := .Section }}
{{- $releases := getJSON "https://api.github.com/repos/containerd/containerd/releases" }}
{{ partial "hero.html" . }}
<article class="is-{{ $section }}-article">
<div class="container">
<div class="content">
<h2>Releases</h2>
{{- range $releases }}
{{- $tag := .tag_name }}
{{- $asset := (index .assets 0).name }}
{{- $zipUrl := .zipball_url }}
{{- $tarUrl := .tarball_url }}
{{- $url := printf "https://github.com/containerd/containerd/releases/download/%s/%s" $tag $asset }}
<h3>{{ .name }}</h3>
<div class="buttons">
<a class="button is-dark" href="{{ $url }}">
{{ $asset }} {{ .latest }}
</a>
<a class="button is-light" href="{{ $zipUrl }}">
Source code (<strong>zip</strong>)
</a>
<a class="button is-black" href="{{ $tarUrl }}">
Source code (<strong>.tar.gz</strong>)
</a>
</div>
{{- end }}
<div class="content is-inner-content">
{{ .Content }}
</div>
</div>
</article>

View File

@ -29,6 +29,10 @@
<div class="navbar-menu" id="navbarMenu">
<div class="navbar-end">
<a class="navbar-item has-text-weight-bold" href="/downloads">
Downloads
</a>
<div class="navbar-item is-hoverable has-dropdown has-text-weight-bold" href="/docs">
<a class="navbar-link">
Docs

View File

@ -0,0 +1 @@
{{- .Site.Params.versions.latest -}}

View File

@ -0,0 +1,24 @@
{{- $releases := getJSON "https://api.github.com/repos/containerd/containerd/releases" }}
{{- range $releases }}
{{- $tag := .tag_name }}
{{- $asset := (index .assets 0).name }}
{{- $zipUrl := printf "https://github.com/containerd/containerd/archive/%s.zip" $tag }}
{{- $tarUrl := printf "https://github.com/containerd/containerd/archive/%s.tar.gz" $tag }}
{{- $url := printf "https://github.com/containerd/containerd/releases/download/%s/%s" $tag $asset }}
<h3>{{ .name }}</h3>
<div class="buttons">
<a class="button is-dark" href="{{ $url }}">
Linux tarball
</a>
<a class="button is-light is-outlined is-inverted" href="{{ $zipUrl }}">
Source code (<strong>zip</strong>)
</a>
<a class="button is-light is-outlined is-inverted" href="{{ $tarUrl }}">
Source code (<strong>.tar.gz</strong>)
</a>
</div>
{{- end }}

File diff suppressed because one or more lines are too long