From 1a85191939505aff3fcf104e46d2a721d0265767 Mon Sep 17 00:00:00 2001 From: ChengyuZhu6 Date: Fri, 15 Dec 2023 12:08:23 +0800 Subject: [PATCH 1/3] misc: add daemon_mode option to guest pull config `daemon_mode` should be specified in guest pull config, even if it is none. This ensures that guest pull config is consistent with other configs and avoids confusion. Fixes #568 Signed-off-by: ChengyuZhu6 --- misc/snapshotter/config-coco-guest-pulling.toml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/misc/snapshotter/config-coco-guest-pulling.toml b/misc/snapshotter/config-coco-guest-pulling.toml index 0cc77b0bd4..2378f363cf 100644 --- a/misc/snapshotter/config-coco-guest-pulling.toml +++ b/misc/snapshotter/config-coco-guest-pulling.toml @@ -6,6 +6,9 @@ root = "/var/lib/containerd-nydus" # The snapshotter's GRPC server socket, containerd will connect to plugin on this socket address = "/run/containerd-nydus/containerd-nydus-grpc.sock" +# No nydusd daemon needed +daemon_mode = "none" + [daemon] # Enable proxy mode fs_driver = "proxy" From 5ec75bc671cd234ac7bbe700ccb005a7ae6d65b6 Mon Sep 17 00:00:00 2001 From: ChengyuZhu6 Date: Fri, 15 Dec 2023 12:15:49 +0800 Subject: [PATCH 2/3] misc: Delete blank lines in snapshotter config Delete blank lines in snapshotter config. Signed-off-by: ChengyuZhu6 --- misc/snapshotter/config-coco-guest-pulling.toml | 5 +---- misc/snapshotter/config-coco-host-sharing.toml | 1 - misc/snapshotter/config.toml | 2 +- 3 files changed, 2 insertions(+), 6 deletions(-) diff --git a/misc/snapshotter/config-coco-guest-pulling.toml b/misc/snapshotter/config-coco-guest-pulling.toml index 2378f363cf..eeba9a7b2e 100644 --- a/misc/snapshotter/config-coco-guest-pulling.toml +++ b/misc/snapshotter/config-coco-guest-pulling.toml @@ -1,11 +1,8 @@ version = 1 - # Snapshotter's own home directory where it stores and creates necessary resources root = "/var/lib/containerd-nydus" - # The snapshotter's GRPC server socket, containerd will connect to plugin on this socket address = "/run/containerd-nydus/containerd-nydus-grpc.sock" - # No nydusd daemon needed daemon_mode = "none" @@ -15,4 +12,4 @@ fs_driver = "proxy" [snapshot] # Insert Kata volume information to `Mount.Options` -enable_kata_volume = true +enable_kata_volume = true \ No newline at end of file diff --git a/misc/snapshotter/config-coco-host-sharing.toml b/misc/snapshotter/config-coco-host-sharing.toml index 9d8313cc37..e52812d243 100644 --- a/misc/snapshotter/config-coco-host-sharing.toml +++ b/misc/snapshotter/config-coco-host-sharing.toml @@ -1,4 +1,3 @@ - version = 1 # Snapshotter's own home directory where it stores and creates necessary resources root = "/var/lib/containerd-nydus" diff --git a/misc/snapshotter/config.toml b/misc/snapshotter/config.toml index 9f2fce5506..9dfc3c28c3 100644 --- a/misc/snapshotter/config.toml +++ b/misc/snapshotter/config.toml @@ -129,4 +129,4 @@ max_concurrent_proc = 0 # - "image_block": generate a raw block disk image with tarfs for an image # - "layer_block_with_verity": generate a raw block disk image with tarfs for a layer with dm-verity info # - "image_block_with_verity": generate a raw block disk image with tarfs for an image with dm-verity info -export_mode = "" +export_mode = "" \ No newline at end of file From af40ded62b6ee4ae7dd1c5989a432bb6950ad92f Mon Sep 17 00:00:00 2001 From: ChengyuZhu6 Date: Fri, 15 Dec 2023 12:43:39 +0800 Subject: [PATCH 3/3] misc: add comments for daemon_mode on snapshotter config Add comments for daemon_mode on snapshotter config. Signed-off-by: ChengyuZhu6 --- misc/snapshotter/config.toml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/misc/snapshotter/config.toml b/misc/snapshotter/config.toml index 9dfc3c28c3..b0c82ca429 100644 --- a/misc/snapshotter/config.toml +++ b/misc/snapshotter/config.toml @@ -3,6 +3,8 @@ version = 1 root = "/var/lib/containerd-nydus" # The snapshotter's GRPC server socket, containerd will connect to plugin on this socket address = "/run/containerd-nydus/containerd-nydus-grpc.sock" +# The nydus daemon mode can be one of the following options: multiple, dedicated, shared, or none. +# If `daemon_mode` option is not specified, the default value is multiple. daemon_mode = "dedicated" # Whether snapshotter should try to clean up resources when it is closed cleanup_on_close = false