From ae4b78d1cc9001455325367d8b3ff53186988754 Mon Sep 17 00:00:00 2001 From: Michael Crosby Date: Tue, 22 May 2018 13:20:11 -0400 Subject: [PATCH 1/6] Move progress into pkg Signed-off-by: Michael Crosby --- cmd/ctr/commands/content/fetch.go | 2 +- cmd/ctr/commands/images/images.go | 2 +- cmd/ctr/commands/images/push.go | 2 +- cmd/ctr/commands/snapshots/snapshots.go | 2 +- {progress => pkg/progress}/bar.go | 0 {progress => pkg/progress}/doc.go | 0 {progress => pkg/progress}/escape.go | 0 {progress => pkg/progress}/humaans.go | 0 {progress => pkg/progress}/writer.go | 0 9 files changed, 4 insertions(+), 4 deletions(-) rename {progress => pkg/progress}/bar.go (100%) rename {progress => pkg/progress}/doc.go (100%) rename {progress => pkg/progress}/escape.go (100%) rename {progress => pkg/progress}/humaans.go (100%) rename {progress => pkg/progress}/writer.go (100%) diff --git a/cmd/ctr/commands/content/fetch.go b/cmd/ctr/commands/content/fetch.go index 01abb4cad..514010dd8 100644 --- a/cmd/ctr/commands/content/fetch.go +++ b/cmd/ctr/commands/content/fetch.go @@ -31,7 +31,7 @@ import ( "github.com/containerd/containerd/errdefs" "github.com/containerd/containerd/images" "github.com/containerd/containerd/log" - "github.com/containerd/containerd/progress" + "github.com/containerd/containerd/pkg/progress" "github.com/containerd/containerd/remotes" digest "github.com/opencontainers/go-digest" ocispec "github.com/opencontainers/image-spec/specs-go/v1" diff --git a/cmd/ctr/commands/images/images.go b/cmd/ctr/commands/images/images.go index 7422eb4bd..29fc45916 100644 --- a/cmd/ctr/commands/images/images.go +++ b/cmd/ctr/commands/images/images.go @@ -27,8 +27,8 @@ import ( "github.com/containerd/containerd/errdefs" "github.com/containerd/containerd/images" "github.com/containerd/containerd/log" + "github.com/containerd/containerd/pkg/progress" "github.com/containerd/containerd/platforms" - "github.com/containerd/containerd/progress" "github.com/pkg/errors" "github.com/urfave/cli" ) diff --git a/cmd/ctr/commands/images/push.go b/cmd/ctr/commands/images/push.go index aa8fb8094..f6d19e64f 100644 --- a/cmd/ctr/commands/images/push.go +++ b/cmd/ctr/commands/images/push.go @@ -28,7 +28,7 @@ import ( "github.com/containerd/containerd/cmd/ctr/commands/content" "github.com/containerd/containerd/images" "github.com/containerd/containerd/log" - "github.com/containerd/containerd/progress" + "github.com/containerd/containerd/pkg/progress" "github.com/containerd/containerd/remotes" "github.com/containerd/containerd/remotes/docker" digest "github.com/opencontainers/go-digest" diff --git a/cmd/ctr/commands/snapshots/snapshots.go b/cmd/ctr/commands/snapshots/snapshots.go index da4ab95d8..b720104eb 100644 --- a/cmd/ctr/commands/snapshots/snapshots.go +++ b/cmd/ctr/commands/snapshots/snapshots.go @@ -30,7 +30,7 @@ import ( "github.com/containerd/containerd/diff" "github.com/containerd/containerd/log" "github.com/containerd/containerd/mount" - "github.com/containerd/containerd/progress" + "github.com/containerd/containerd/pkg/progress" "github.com/containerd/containerd/rootfs" "github.com/containerd/containerd/snapshots" digest "github.com/opencontainers/go-digest" diff --git a/progress/bar.go b/pkg/progress/bar.go similarity index 100% rename from progress/bar.go rename to pkg/progress/bar.go diff --git a/progress/doc.go b/pkg/progress/doc.go similarity index 100% rename from progress/doc.go rename to pkg/progress/doc.go diff --git a/progress/escape.go b/pkg/progress/escape.go similarity index 100% rename from progress/escape.go rename to pkg/progress/escape.go diff --git a/progress/humaans.go b/pkg/progress/humaans.go similarity index 100% rename from progress/humaans.go rename to pkg/progress/humaans.go diff --git a/progress/writer.go b/pkg/progress/writer.go similarity index 100% rename from progress/writer.go rename to pkg/progress/writer.go From 927517de3696b147923dedda385b0f9e705afda5 Mon Sep 17 00:00:00 2001 From: Michael Crosby Date: Tue, 22 May 2018 13:24:16 -0400 Subject: [PATCH 2/6] Move dialer to pkg Signed-off-by: Michael Crosby --- client.go | 2 +- cmd/containerd/command/publish.go | 2 +- {dialer => pkg/dialer}/dialer.go | 0 {dialer => pkg/dialer}/dialer_unix.go | 0 {dialer => pkg/dialer}/dialer_windows.go | 0 5 files changed, 2 insertions(+), 2 deletions(-) rename {dialer => pkg/dialer}/dialer.go (100%) rename {dialer => pkg/dialer}/dialer_unix.go (100%) rename {dialer => pkg/dialer}/dialer_windows.go (100%) diff --git a/client.go b/client.go index 3cf7ff3ee..6ce27b71d 100644 --- a/client.go +++ b/client.go @@ -39,11 +39,11 @@ import ( "github.com/containerd/containerd/containers" "github.com/containerd/containerd/content" "github.com/containerd/containerd/defaults" - "github.com/containerd/containerd/dialer" "github.com/containerd/containerd/errdefs" "github.com/containerd/containerd/events" "github.com/containerd/containerd/images" "github.com/containerd/containerd/namespaces" + "github.com/containerd/containerd/pkg/dialer" "github.com/containerd/containerd/plugin" "github.com/containerd/containerd/remotes" "github.com/containerd/containerd/remotes/docker" diff --git a/cmd/containerd/command/publish.go b/cmd/containerd/command/publish.go index d297732bf..280a7e70d 100644 --- a/cmd/containerd/command/publish.go +++ b/cmd/containerd/command/publish.go @@ -25,9 +25,9 @@ import ( "time" eventsapi "github.com/containerd/containerd/api/services/events/v1" - "github.com/containerd/containerd/dialer" "github.com/containerd/containerd/errdefs" "github.com/containerd/containerd/namespaces" + "github.com/containerd/containerd/pkg/dialer" "github.com/gogo/protobuf/types" "github.com/pkg/errors" "github.com/urfave/cli" diff --git a/dialer/dialer.go b/pkg/dialer/dialer.go similarity index 100% rename from dialer/dialer.go rename to pkg/dialer/dialer.go diff --git a/dialer/dialer_unix.go b/pkg/dialer/dialer_unix.go similarity index 100% rename from dialer/dialer_unix.go rename to pkg/dialer/dialer_unix.go diff --git a/dialer/dialer_windows.go b/pkg/dialer/dialer_windows.go similarity index 100% rename from dialer/dialer_windows.go rename to pkg/dialer/dialer_windows.go From 009ba4d797706986c755906d235641ace75c41d3 Mon Sep 17 00:00:00 2001 From: Michael Crosby Date: Tue, 22 May 2018 17:08:38 -0400 Subject: [PATCH 3/6] Move testutils to pkg Signed-off-by: Michael Crosby --- archive/issues_test.go | 2 +- client_test.go | 2 +- content/local/store_test.go | 2 +- content/testsuite/testsuite.go | 2 +- daemon_config_linux_test.go | 2 +- metadata/snapshot_test.go | 2 +- mount/lookup_test/lookup_linux_test.go | 4 ++-- {testutil => pkg/testutil}/helpers.go | 0 {testutil => pkg/testutil}/helpers_unix.go | 0 {testutil => pkg/testutil}/helpers_windows.go | 0 {testutil => pkg/testutil}/loopback_linux.go | 0 {testutil => pkg/testutil}/mount_linux.go | 0 {testutil => pkg/testutil}/mount_other.go | 0 snapshots/btrfs/btrfs_test.go | 2 +- snapshots/native/native_test.go | 2 +- snapshots/overlay/check_test.go | 2 +- snapshots/overlay/overlay_test.go | 2 +- snapshots/storage/bolt_test.go | 2 +- snapshots/testsuite/testsuite.go | 2 +- 19 files changed, 14 insertions(+), 14 deletions(-) rename {testutil => pkg/testutil}/helpers.go (100%) rename {testutil => pkg/testutil}/helpers_unix.go (100%) rename {testutil => pkg/testutil}/helpers_windows.go (100%) rename {testutil => pkg/testutil}/loopback_linux.go (100%) rename {testutil => pkg/testutil}/mount_linux.go (100%) rename {testutil => pkg/testutil}/mount_other.go (100%) diff --git a/archive/issues_test.go b/archive/issues_test.go index af2418d27..9d54c7cad 100644 --- a/archive/issues_test.go +++ b/archive/issues_test.go @@ -26,7 +26,7 @@ import ( "testing" "github.com/containerd/containerd/archive/compression" - "github.com/containerd/containerd/testutil" + "github.com/containerd/containerd/pkg/testutil" ) // TestPrefixHeaderReadable tests that files that could be created with the diff --git a/client_test.go b/client_test.go index 842b1a475..e726a54a7 100644 --- a/client_test.go +++ b/client_test.go @@ -33,9 +33,9 @@ import ( "github.com/containerd/containerd/images" "github.com/containerd/containerd/log" "github.com/containerd/containerd/namespaces" + "github.com/containerd/containerd/pkg/testutil" "github.com/containerd/containerd/platforms" "github.com/containerd/containerd/sys" - "github.com/containerd/containerd/testutil" "github.com/sirupsen/logrus" ) diff --git a/content/local/store_test.go b/content/local/store_test.go index b9ed2e270..c78e64cc0 100644 --- a/content/local/store_test.go +++ b/content/local/store_test.go @@ -36,7 +36,7 @@ import ( "github.com/containerd/containerd/content" "github.com/containerd/containerd/content/testsuite" - "github.com/containerd/containerd/testutil" + "github.com/containerd/containerd/pkg/testutil" "github.com/gotestyourself/gotestyourself/assert" "github.com/opencontainers/go-digest" ) diff --git a/content/testsuite/testsuite.go b/content/testsuite/testsuite.go index 65865d451..86bdde6b2 100644 --- a/content/testsuite/testsuite.go +++ b/content/testsuite/testsuite.go @@ -30,7 +30,7 @@ import ( "time" "github.com/containerd/containerd/content" - "github.com/containerd/containerd/testutil" + "github.com/containerd/containerd/pkg/testutil" "github.com/gotestyourself/gotestyourself/assert" digest "github.com/opencontainers/go-digest" "github.com/pkg/errors" diff --git a/daemon_config_linux_test.go b/daemon_config_linux_test.go index cbb6454a0..d3241f990 100644 --- a/daemon_config_linux_test.go +++ b/daemon_config_linux_test.go @@ -29,8 +29,8 @@ import ( "time" "github.com/containerd/containerd/oci" + "github.com/containerd/containerd/pkg/testutil" "github.com/containerd/containerd/server" - "github.com/containerd/containerd/testutil" ) // the following nolint is for shutting up gometalinter on non-linux. diff --git a/metadata/snapshot_test.go b/metadata/snapshot_test.go index e7bedbd55..f464acd10 100644 --- a/metadata/snapshot_test.go +++ b/metadata/snapshot_test.go @@ -24,10 +24,10 @@ import ( "testing" "github.com/boltdb/bolt" + "github.com/containerd/containerd/pkg/testutil" "github.com/containerd/containerd/snapshots" "github.com/containerd/containerd/snapshots/native" "github.com/containerd/containerd/snapshots/testsuite" - "github.com/containerd/containerd/testutil" ) func newTestSnapshotter(ctx context.Context, root string) (snapshots.Snapshotter, func() error, error) { diff --git a/mount/lookup_test/lookup_linux_test.go b/mount/lookup_test/lookup_linux_test.go index 7d7db2223..4a0b5e691 100644 --- a/mount/lookup_test/lookup_linux_test.go +++ b/mount/lookup_test/lookup_linux_test.go @@ -19,7 +19,7 @@ // FIXME: we can't put this test to the mount package: // import cycle not allowed in test // package github.com/containerd/containerd/mount (test) -// imports github.com/containerd/containerd/testutil +// imports github.com/containerd/containerd/pkg/testutil // imports github.com/containerd/containerd/mount // // NOTE: we can't have this as lookup_test (compilation fails) @@ -35,7 +35,7 @@ import ( "testing" "github.com/containerd/containerd/mount" - "github.com/containerd/containerd/testutil" + "github.com/containerd/containerd/pkg/testutil" "github.com/gotestyourself/gotestyourself/assert" ) diff --git a/testutil/helpers.go b/pkg/testutil/helpers.go similarity index 100% rename from testutil/helpers.go rename to pkg/testutil/helpers.go diff --git a/testutil/helpers_unix.go b/pkg/testutil/helpers_unix.go similarity index 100% rename from testutil/helpers_unix.go rename to pkg/testutil/helpers_unix.go diff --git a/testutil/helpers_windows.go b/pkg/testutil/helpers_windows.go similarity index 100% rename from testutil/helpers_windows.go rename to pkg/testutil/helpers_windows.go diff --git a/testutil/loopback_linux.go b/pkg/testutil/loopback_linux.go similarity index 100% rename from testutil/loopback_linux.go rename to pkg/testutil/loopback_linux.go diff --git a/testutil/mount_linux.go b/pkg/testutil/mount_linux.go similarity index 100% rename from testutil/mount_linux.go rename to pkg/testutil/mount_linux.go diff --git a/testutil/mount_other.go b/pkg/testutil/mount_other.go similarity index 100% rename from testutil/mount_other.go rename to pkg/testutil/mount_other.go diff --git a/snapshots/btrfs/btrfs_test.go b/snapshots/btrfs/btrfs_test.go index 12374efee..02b357bc1 100644 --- a/snapshots/btrfs/btrfs_test.go +++ b/snapshots/btrfs/btrfs_test.go @@ -28,9 +28,9 @@ import ( "testing" "github.com/containerd/containerd/mount" + "github.com/containerd/containerd/pkg/testutil" "github.com/containerd/containerd/snapshots" "github.com/containerd/containerd/snapshots/testsuite" - "github.com/containerd/containerd/testutil" "github.com/pkg/errors" "golang.org/x/sys/unix" ) diff --git a/snapshots/native/native_test.go b/snapshots/native/native_test.go index b49072fd1..79e02637d 100644 --- a/snapshots/native/native_test.go +++ b/snapshots/native/native_test.go @@ -21,9 +21,9 @@ import ( "runtime" "testing" + "github.com/containerd/containerd/pkg/testutil" "github.com/containerd/containerd/snapshots" "github.com/containerd/containerd/snapshots/testsuite" - "github.com/containerd/containerd/testutil" ) func newSnapshotter(ctx context.Context, root string) (snapshots.Snapshotter, func() error, error) { diff --git a/snapshots/overlay/check_test.go b/snapshots/overlay/check_test.go index 2f83939dc..d394b9522 100644 --- a/snapshots/overlay/check_test.go +++ b/snapshots/overlay/check_test.go @@ -24,7 +24,7 @@ import ( "os/exec" "testing" - "github.com/containerd/containerd/testutil" + "github.com/containerd/containerd/pkg/testutil" ) func testOverlaySupported(t testing.TB, expected bool, mkfs ...string) { diff --git a/snapshots/overlay/overlay_test.go b/snapshots/overlay/overlay_test.go index 67149b15e..17f555d55 100644 --- a/snapshots/overlay/overlay_test.go +++ b/snapshots/overlay/overlay_test.go @@ -28,10 +28,10 @@ import ( "testing" "github.com/containerd/containerd/mount" + "github.com/containerd/containerd/pkg/testutil" "github.com/containerd/containerd/snapshots" "github.com/containerd/containerd/snapshots/storage" "github.com/containerd/containerd/snapshots/testsuite" - "github.com/containerd/containerd/testutil" ) func newSnapshotter(ctx context.Context, root string) (snapshots.Snapshotter, func() error, error) { diff --git a/snapshots/storage/bolt_test.go b/snapshots/storage/bolt_test.go index 3f5768d31..838f7aa9f 100644 --- a/snapshots/storage/bolt_test.go +++ b/snapshots/storage/bolt_test.go @@ -22,7 +22,7 @@ import ( // Does not require root but flag must be defined for snapshot tests - _ "github.com/containerd/containerd/testutil" + _ "github.com/containerd/containerd/pkg/testutil" ) func TestMetastore(t *testing.T) { diff --git a/snapshots/testsuite/testsuite.go b/snapshots/testsuite/testsuite.go index 65ea93a07..2c6f20861 100644 --- a/snapshots/testsuite/testsuite.go +++ b/snapshots/testsuite/testsuite.go @@ -29,8 +29,8 @@ import ( "github.com/containerd/containerd/errdefs" "github.com/containerd/containerd/mount" "github.com/containerd/containerd/namespaces" + "github.com/containerd/containerd/pkg/testutil" "github.com/containerd/containerd/snapshots" - "github.com/containerd/containerd/testutil" "github.com/containerd/continuity/fs/fstest" "github.com/gotestyourself/gotestyourself/assert" is "github.com/gotestyourself/gotestyourself/assert/cmp" From d8ad141851db7298acdc50f43b5919322d520bc5 Mon Sep 17 00:00:00 2001 From: Michael Crosby Date: Tue, 22 May 2018 17:09:40 -0400 Subject: [PATCH 4/6] Remove debug package Signed-off-by: Michael Crosby --- debug/debug.go | 72 -------------------------------------------------- 1 file changed, 72 deletions(-) delete mode 100644 debug/debug.go diff --git a/debug/debug.go b/debug/debug.go deleted file mode 100644 index 1136288c1..000000000 --- a/debug/debug.go +++ /dev/null @@ -1,72 +0,0 @@ -/* - Copyright The containerd Authors. - - Licensed under the Apache License, Version 2.0 (the "License"); - you may not use this file except in compliance with the License. - You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - - Unless required by applicable law or agreed to in writing, software - distributed under the License is distributed on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - See the License for the specific language governing permissions and - limitations under the License. -*/ - -package debug - -import ( - "bufio" - "fmt" - "os" - "strconv" - "strings" -) - -// Smaps prints the smaps to a file -func Smaps(note, file string) error { - smaps, err := getMaps(os.Getpid()) - if err != nil { - return err - } - f, err := os.OpenFile(file, os.O_CREATE|os.O_WRONLY|os.O_APPEND, 0666) - if err != nil { - return err - } - defer f.Close() - fmt.Fprintf(f, "%s: rss %d\n", note, smaps["rss"]) - fmt.Fprintf(f, "%s: pss %d\n", note, smaps["pss"]) - return nil -} - -func getMaps(pid int) (map[string]int, error) { - f, err := os.Open(fmt.Sprintf("/proc/%d/smaps", pid)) - if err != nil { - return nil, err - } - defer f.Close() - var ( - smaps = make(map[string]int) - s = bufio.NewScanner(f) - ) - for s.Scan() { - var ( - fields = strings.Fields(s.Text()) - name = fields[0] - ) - name = strings.TrimSuffix(strings.ToLower(name), ":") - if len(fields) < 2 { - continue - } - n, err := strconv.Atoi(fields[1]) - if err != nil { - continue - } - smaps[name] += n - } - if err := s.Err(); err != nil { - return nil, err - } - return smaps, nil -} From c87ed12da52eb33070f768c07832d899a8f22cd9 Mon Sep 17 00:00:00 2001 From: Michael Crosby Date: Tue, 22 May 2018 17:13:40 -0400 Subject: [PATCH 5/6] Move restart pkg to runtime Signed-off-by: Michael Crosby --- cmd/containerd/builtins.go | 2 +- {restart => runtime/restart}/monitor/change.go | 0 {restart => runtime/restart}/monitor/monitor.go | 2 +- {restart => runtime/restart}/restart.go | 0 4 files changed, 2 insertions(+), 2 deletions(-) rename {restart => runtime/restart}/monitor/change.go (100%) rename {restart => runtime/restart}/monitor/monitor.go (99%) rename {restart => runtime/restart}/restart.go (100%) diff --git a/cmd/containerd/builtins.go b/cmd/containerd/builtins.go index 930481aef..17fa9f629 100644 --- a/cmd/containerd/builtins.go +++ b/cmd/containerd/builtins.go @@ -20,7 +20,7 @@ package main import ( _ "github.com/containerd/containerd/diff/walking/plugin" _ "github.com/containerd/containerd/gc/scheduler" - _ "github.com/containerd/containerd/restart/monitor" + _ "github.com/containerd/containerd/runtime/restart/monitor" _ "github.com/containerd/containerd/services/containers" _ "github.com/containerd/containerd/services/content" _ "github.com/containerd/containerd/services/diff" diff --git a/restart/monitor/change.go b/runtime/restart/monitor/change.go similarity index 100% rename from restart/monitor/change.go rename to runtime/restart/monitor/change.go diff --git a/restart/monitor/monitor.go b/runtime/restart/monitor/monitor.go similarity index 99% rename from restart/monitor/monitor.go rename to runtime/restart/monitor/monitor.go index e5d7f8bb6..3b2a2713f 100644 --- a/restart/monitor/monitor.go +++ b/runtime/restart/monitor/monitor.go @@ -31,7 +31,7 @@ import ( "github.com/containerd/containerd/content" "github.com/containerd/containerd/namespaces" "github.com/containerd/containerd/plugin" - "github.com/containerd/containerd/restart" + "github.com/containerd/containerd/runtime/restart" "github.com/containerd/containerd/services" "github.com/containerd/containerd/snapshots" "github.com/pkg/errors" diff --git a/restart/restart.go b/runtime/restart/restart.go similarity index 100% rename from restart/restart.go rename to runtime/restart/restart.go From 8e97da09583935ecfee965fe762e499d1b2c0398 Mon Sep 17 00:00:00 2001 From: Michael Crosby Date: Tue, 22 May 2018 17:15:58 -0400 Subject: [PATCH 6/6] Move server to services pkg Signed-off-by: Michael Crosby --- cmd/containerd/command/config.go | 2 +- cmd/containerd/command/config_linux.go | 2 +- cmd/containerd/command/config_unsupported.go | 2 +- cmd/containerd/command/config_windows.go | 2 +- cmd/containerd/command/main.go | 2 +- cmd/containerd/command/main_unix.go | 2 +- cmd/containerd/command/main_windows.go | 2 +- daemon_config_linux_test.go | 2 +- {server => services/server}/config.go | 0 {server => services/server}/server.go | 0 {server => services/server}/server_linux.go | 0 {server => services/server}/server_solaris.go | 0 {server => services/server}/server_test.go | 0 {server => services/server}/server_unsupported.go | 0 {server => services/server}/server_windows.go | 0 15 files changed, 8 insertions(+), 8 deletions(-) rename {server => services/server}/config.go (100%) rename {server => services/server}/server.go (100%) rename {server => services/server}/server_linux.go (100%) rename {server => services/server}/server_solaris.go (100%) rename {server => services/server}/server_test.go (100%) rename {server => services/server}/server_unsupported.go (100%) rename {server => services/server}/server_windows.go (100%) diff --git a/cmd/containerd/command/config.go b/cmd/containerd/command/config.go index cbcc087ae..eebe2ba5b 100644 --- a/cmd/containerd/command/config.go +++ b/cmd/containerd/command/config.go @@ -21,7 +21,7 @@ import ( "os" "github.com/BurntSushi/toml" - "github.com/containerd/containerd/server" + "github.com/containerd/containerd/services/server" "github.com/urfave/cli" ) diff --git a/cmd/containerd/command/config_linux.go b/cmd/containerd/command/config_linux.go index 2b522989d..3010ee65f 100644 --- a/cmd/containerd/command/config_linux.go +++ b/cmd/containerd/command/config_linux.go @@ -18,7 +18,7 @@ package command import ( "github.com/containerd/containerd/defaults" - "github.com/containerd/containerd/server" + "github.com/containerd/containerd/services/server" ) func defaultConfig() *server.Config { diff --git a/cmd/containerd/command/config_unsupported.go b/cmd/containerd/command/config_unsupported.go index 1d3825c78..3b479a1c6 100644 --- a/cmd/containerd/command/config_unsupported.go +++ b/cmd/containerd/command/config_unsupported.go @@ -20,7 +20,7 @@ package command import ( "github.com/containerd/containerd/defaults" - "github.com/containerd/containerd/server" + "github.com/containerd/containerd/services/server" ) func defaultConfig() *server.Config { diff --git a/cmd/containerd/command/config_windows.go b/cmd/containerd/command/config_windows.go index 2b522989d..3010ee65f 100644 --- a/cmd/containerd/command/config_windows.go +++ b/cmd/containerd/command/config_windows.go @@ -18,7 +18,7 @@ package command import ( "github.com/containerd/containerd/defaults" - "github.com/containerd/containerd/server" + "github.com/containerd/containerd/services/server" ) func defaultConfig() *server.Config { diff --git a/cmd/containerd/command/main.go b/cmd/containerd/command/main.go index 8fba0fa38..1556752dd 100644 --- a/cmd/containerd/command/main.go +++ b/cmd/containerd/command/main.go @@ -29,7 +29,7 @@ import ( "github.com/containerd/containerd/log" "github.com/containerd/containerd/mount" - "github.com/containerd/containerd/server" + "github.com/containerd/containerd/services/server" "github.com/containerd/containerd/sys" "github.com/containerd/containerd/version" "github.com/pkg/errors" diff --git a/cmd/containerd/command/main_unix.go b/cmd/containerd/command/main_unix.go index 9dc287ca0..12c14261b 100644 --- a/cmd/containerd/command/main_unix.go +++ b/cmd/containerd/command/main_unix.go @@ -24,7 +24,7 @@ import ( "runtime" "github.com/containerd/containerd/log" - "github.com/containerd/containerd/server" + "github.com/containerd/containerd/services/server" "github.com/sirupsen/logrus" "golang.org/x/sys/unix" ) diff --git a/cmd/containerd/command/main_windows.go b/cmd/containerd/command/main_windows.go index 7af904801..66df8881a 100644 --- a/cmd/containerd/command/main_windows.go +++ b/cmd/containerd/command/main_windows.go @@ -22,7 +22,7 @@ import ( "path/filepath" "github.com/containerd/containerd/log" - "github.com/containerd/containerd/server" + "github.com/containerd/containerd/services/server" "golang.org/x/sys/windows" ) diff --git a/daemon_config_linux_test.go b/daemon_config_linux_test.go index d3241f990..c8003abf8 100644 --- a/daemon_config_linux_test.go +++ b/daemon_config_linux_test.go @@ -30,7 +30,7 @@ import ( "github.com/containerd/containerd/oci" "github.com/containerd/containerd/pkg/testutil" - "github.com/containerd/containerd/server" + "github.com/containerd/containerd/services/server" ) // the following nolint is for shutting up gometalinter on non-linux. diff --git a/server/config.go b/services/server/config.go similarity index 100% rename from server/config.go rename to services/server/config.go diff --git a/server/server.go b/services/server/server.go similarity index 100% rename from server/server.go rename to services/server/server.go diff --git a/server/server_linux.go b/services/server/server_linux.go similarity index 100% rename from server/server_linux.go rename to services/server/server_linux.go diff --git a/server/server_solaris.go b/services/server/server_solaris.go similarity index 100% rename from server/server_solaris.go rename to services/server/server_solaris.go diff --git a/server/server_test.go b/services/server/server_test.go similarity index 100% rename from server/server_test.go rename to services/server/server_test.go diff --git a/server/server_unsupported.go b/services/server/server_unsupported.go similarity index 100% rename from server/server_unsupported.go rename to services/server/server_unsupported.go diff --git a/server/server_windows.go b/services/server/server_windows.go similarity index 100% rename from server/server_windows.go rename to services/server/server_windows.go