From 59f372cb0875f800015abe989d4eba6b8df92e42 Mon Sep 17 00:00:00 2001 From: Sam Berning <113054166+sam-berning@users.noreply.github.com> Date: Tue, 24 Jan 2023 16:44:07 -0600 Subject: [PATCH] fix!: persists nerdctl user data (#182) Signed-off-by: Sam Berning Issue #, if available: https://github.com/runfinch/finch/issues/180 *Description of changes:* Changes format of persistent disk to support saving nerdctl user data *Testing done:* ``` $ finch run --name test-container -v ~/scratch:/scratch alpine ls /scratch $ finch vm stop $ finch vm remove $ finch vm init $ finch start --attach test-container ``` - [x] I've reviewed the guidance in CONTRIBUTING.md #### License Acceptance By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license. Signed-off-by: Sam Berning --- finch.yaml | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/finch.yaml b/finch.yaml index 14a337bb8..1ded9ee58 100644 --- a/finch.yaml +++ b/finch.yaml @@ -149,7 +149,11 @@ provision: script: | #!/bin/bash sudo chown $USER /mnt/lima-finch - sudo mount --bind /mnt/lima-finch ~/.local/share/containerd + mkdir -p /mnt/lima-finch/containerd + mkdir -p /mnt/lima-finch/nerdctl + mkdir -p ~/.local/share/nerdctl + sudo mount --bind /mnt/lima-finch/containerd ~/.local/share/containerd + sudo mount --bind /mnt/lima-finch/nerdctl ~/.local/share/nerdctl systemctl --user restart containerd.service # Probe scripts to check readiness.