containerd-stress: add snapshotter option for stress test to use
containerd-stress utility needs to be able to run with snapshotter passed by user in cli in order to be able to stress test snapshotters. This adds a cli option --snapshotter="<snapshotter-name>" Signed-off-by: Alakesh Haloi <alakeshh@amazon.com>
This commit is contained in:
@@ -42,6 +42,7 @@ func (w *execWorker) exec(ctx, tctx context.Context) {
|
||||
id := fmt.Sprintf("exec-container-%d", w.id)
|
||||
c, err := w.client.NewContainer(ctx, id,
|
||||
containerd.WithNewSnapshot(id, w.image),
|
||||
containerd.WithSnapshotter(w.snapshotter),
|
||||
containerd.WithNewSpec(oci.WithImageConfig(w.image), oci.WithUsername("games"), oci.WithProcessArgs("sleep", "30d")),
|
||||
)
|
||||
if err != nil {
|
||||
|
||||
Reference in New Issue
Block a user