Bump packages to new alpine w/ containerd v1.0.0-rc.0

Minor updates due to renamings in containerd.

Signed-off-by: Ian Campbell <ijc@docker.com>
This commit is contained in:
Ian Campbell 2017-12-01 13:22:30 +00:00
parent e5caf00020
commit 28e22e40bb
4 changed files with 14 additions and 13 deletions

View File

@ -1,4 +1,4 @@
FROM linuxkit/alpine:7d79062909882186e881aad263668d66e6df2a28 as alpine FROM linuxkit/alpine:a99d4f10971f30b20688b4a4c40763150b9e4355 as alpine
RUN apk add tzdata RUN apk add tzdata
WORKDIR $GOPATH/src/github.com/containerd/containerd WORKDIR $GOPATH/src/github.com/containerd/containerd

View File

@ -1,4 +1,4 @@
FROM linuxkit/alpine:7d79062909882186e881aad263668d66e6df2a28 AS build FROM linuxkit/alpine:a99d4f10971f30b20688b4a4c40763150b9e4355 AS build
RUN apk add --no-cache --initdb alpine-baselayout make gcc musl-dev git linux-headers RUN apk add --no-cache --initdb alpine-baselayout make gcc musl-dev git linux-headers
ADD usermode-helper.c ./ ADD usermode-helper.c ./
@ -16,7 +16,7 @@ RUN mkdir /tmp/bin && cd /tmp/bin/ && cp /go/bin/rc.init . && ln -s rc.init rc.s
RUN cd /go/src/cmd/service && ./skanky-vendor.sh $GOPATH/src/github.com/containerd/containerd RUN cd /go/src/cmd/service && ./skanky-vendor.sh $GOPATH/src/github.com/containerd/containerd
RUN go-compile.sh /go/src/cmd/service RUN go-compile.sh /go/src/cmd/service
FROM linuxkit/alpine:07f7d136e427dc68154cd5edbb2b9576f9ac5213 AS mirror FROM linuxkit/alpine:a99d4f10971f30b20688b4a4c40763150b9e4355 AS mirror
RUN mkdir -p /out/etc/apk && cp -r /etc/apk/* /out/etc/apk/ RUN mkdir -p /out/etc/apk && cp -r /etc/apk/* /out/etc/apk/
RUN apk add --no-cache --initdb -p /out alpine-baselayout busybox musl RUN apk add --no-cache --initdb -p /out alpine-baselayout busybox musl

View File

@ -10,6 +10,7 @@ import (
"path/filepath" "path/filepath"
"github.com/containerd/containerd" "github.com/containerd/containerd"
"github.com/containerd/containerd/cio"
"github.com/containerd/containerd/namespaces" "github.com/containerd/containerd/namespaces"
specs "github.com/opencontainers/runtime-spec/specs-go" specs "github.com/opencontainers/runtime-spec/specs-go"
log "github.com/sirupsen/logrus" log "github.com/sirupsen/logrus"
@ -55,21 +56,21 @@ func startCmd(args []string) {
log.Debugf("Started %s pid %d", id, pid) log.Debugf("Started %s pid %d", id, pid)
} }
type cio struct { type logio struct {
config containerd.IOConfig config cio.Config
} }
func (c *cio) Config() containerd.IOConfig { func (c *logio) Config() cio.Config {
return c.config return c.config
} }
func (c *cio) Cancel() { func (c *logio) Cancel() {
} }
func (c *cio) Wait() { func (c *logio) Wait() {
} }
func (c *cio) Close() error { func (c *logio) Close() error {
return nil return nil
} }
@ -120,7 +121,7 @@ func start(service, sock, basePath, dumpSpec string) (string, uint32, string, er
return "", 0, "failed to create container", err return "", 0, "failed to create container", err
} }
io := func(id string) (containerd.IO, error) { io := func(id string) (cio.IO, error) {
stdoutFile := filepath.Join("/var/log", service+".out.log") stdoutFile := filepath.Join("/var/log", service+".out.log")
stderrFile := filepath.Join("/var/log", service+".err.log") stderrFile := filepath.Join("/var/log", service+".err.log")
// We just need this to exist. If we cannot write to the directory, // We just need this to exist. If we cannot write to the directory,
@ -131,8 +132,8 @@ func start(service, sock, basePath, dumpSpec string) (string, uint32, string, er
if err := ioutil.WriteFile(stderrFile, []byte{}, 0600); err != nil { if err := ioutil.WriteFile(stderrFile, []byte{}, 0600); err != nil {
stderrFile = "/dev/null" stderrFile = "/dev/null"
} }
return &cio{ return &logio{
containerd.IOConfig{ cio.Config{
Stdin: "/dev/null", Stdin: "/dev/null",
Stdout: stdoutFile, Stdout: stdoutFile,
Stderr: stderrFile, Stderr: stderrFile,

View File

@ -1,4 +1,4 @@
FROM linuxkit/alpine:7d79062909882186e881aad263668d66e6df2a28 AS mirror FROM linuxkit/alpine:a99d4f10971f30b20688b4a4c40763150b9e4355 AS mirror
RUN mkdir -p /out/etc/apk && cp -r /etc/apk/* /out/etc/apk/ RUN mkdir -p /out/etc/apk && cp -r /etc/apk/* /out/etc/apk/
# btrfs-progfs is required for btrfs test (mkfs.btrfs) # btrfs-progfs is required for btrfs test (mkfs.btrfs)
# util-linux is required for btrfs test (losetup) # util-linux is required for btrfs test (losetup)