File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1818
1919package main
2020
21- import _ "github.com/containerd/containerd/snapshots/btrfs"
21+ import _ "github.com/containerd/containerd/snapshots/btrfs/plugin "
Original file line number Diff line number Diff line change @@ -26,31 +26,18 @@ import (
2626 "strings"
2727
2828 "github.com/containerd/btrfs"
29+ "github.com/containerd/continuity/fs"
30+
2931 "github.com/containerd/containerd/log"
3032 "github.com/containerd/containerd/mount"
31- "github.com/containerd/containerd/platforms"
3233 "github.com/containerd/containerd/plugin"
3334 "github.com/containerd/containerd/snapshots"
3435 "github.com/containerd/containerd/snapshots/storage"
35- "github.com/containerd/continuity/fs"
3636
37- ocispec "github.com/opencontainers/image-spec/specs-go/v1"
3837 "github.com/pkg/errors"
3938 "github.com/sirupsen/logrus"
4039)
4140
42- func init () {
43- plugin .Register (& plugin.Registration {
44- ID : "btrfs" ,
45- Type : plugin .SnapshotPlugin ,
46- InitFn : func (ic * plugin.InitContext ) (interface {}, error ) {
47- ic .Meta .Platforms = []ocispec.Platform {platforms .DefaultSpec ()}
48- ic .Meta .Exports = map [string ]string {"root" : ic .Root }
49- return NewSnapshotter (ic .Root )
50- },
51- })
52- }
53-
5441type snapshotter struct {
5542 device string // device of the root
5643 root string // root provides paths for internal storage.
You can’t perform that action at this time.
0 commit comments