Skip to content

Commit

Permalink
Merge branch 'main' into fix-create-device-message
Browse files Browse the repository at this point in the history
  • Loading branch information
Callisto13 authored Dec 16, 2021
2 parents dbd64fa + 45622b0 commit b834202
Show file tree
Hide file tree
Showing 6 changed files with 6 additions and 12 deletions.
2 changes: 1 addition & 1 deletion infrastructure/containerd/config.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ const (
supportedSnapshotters = "overlayfs,native,devmapper"
)

// Config holds the contaierd configuration.
// Config holds the containerd configuration.
type Config struct {
// SnapshotterKernel is the name of the containerd snapshotter to use for kernel images.
SnapshotterKernel string
Expand Down
6 changes: 0 additions & 6 deletions internal/command/flags/flags.go
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,6 @@ const (
firecrackerBinFlag = "firecracker-bin"
firecrackerDetachFlag = "firecracker-detach"
containerdSocketFlag = "containerd-socket"
volSnapshotterFlag = "containerd-volume-ss"
kernelSnapshotterFlag = "containerd-kernel-ss"
containerdNamespace = "containerd-ns"
maximumRetryFlag = "maximum-retry"
Expand Down Expand Up @@ -115,11 +114,6 @@ func AddContainerDFlagsToCommand(cmd *cobra.Command, cfg *config.Config) error {
defaults.ContainerdKernelSnapshotter,
"The name of the snapshotter to use with containerd for kernel/initrd images.")

cmd.Flags().StringVar(&cfg.CtrSnapshotterVolume,
volSnapshotterFlag,
defaults.ContainerdVolumeSnapshotter,
"The name of the snapshotter to use with containerd for volume images.")

cmd.Flags().StringVar(&cfg.CtrNamespace,
containerdNamespace,
defaults.ContainerdNamespace,
Expand Down
2 changes: 0 additions & 2 deletions internal/config/config.go
Original file line number Diff line number Diff line change
Expand Up @@ -26,8 +26,6 @@ type Config struct {
ParentIface string
// CtrSnapshotterKernel is the name of the containerd snapshotter to use for kernel images.
CtrSnapshotterKernel string
// CtrSnapshotterVolume is the name of the containerd snapshotter to use for volume (inc initrd) images.
CtrSnapshotterVolume string
// CtrSocketPath is the path to the containerd socket.
CtrSocketPath string
// CtrNamespace is the default containerd namespace to use
Expand Down
3 changes: 2 additions & 1 deletion internal/inject/wire.go
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ import (
"github.com/weaveworks/flintlock/infrastructure/network"
"github.com/weaveworks/flintlock/infrastructure/ulid"
"github.com/weaveworks/flintlock/internal/config"
"github.com/weaveworks/flintlock/pkg/defaults"
)

func InitializePorts(cfg *config.Config) (*ports.Collection, error) {
Expand Down Expand Up @@ -58,7 +59,7 @@ func InitializeGRPCServer(app application.App) ports.MicroVMGRPCService {
func containerdConfig(cfg *config.Config) *containerd.Config {
return &containerd.Config{
SnapshotterKernel: cfg.CtrSnapshotterKernel,
SnapshotterVolume: cfg.CtrSnapshotterVolume,
SnapshotterVolume: defaults.ContainerdVolumeSnapshotter,
SocketPath: cfg.CtrSocketPath,
Namespace: cfg.CtrNamespace,
}
Expand Down
3 changes: 2 additions & 1 deletion internal/inject/wire_gen.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion pkg/defaults/defaults.go
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ const (
// ContainerdSocket is the defaults path for the containerd socket.
ContainerdSocket = "/run/containerd/containerd.sock"

// ContainerdVolumeSnapshotter is the name of the default snapshotter to use for volumes.
// ContainerdVolumeSnapshotter is the name of the snapshotter used for volumes.
ContainerdVolumeSnapshotter = "devmapper"

// ContainerdKernelSnapshotter is the name of the default snapshotter to use for kernek/initrd.
Expand Down

0 comments on commit b834202

Please sign in to comment.