From 8944f7ace953281e8fd5f6e723c2532434397a27 Mon Sep 17 00:00:00 2001 From: Carlos Eduardo Arango Gutierrez Date: Mon, 8 Jan 2024 19:23:36 +0100 Subject: [PATCH] Fix Delete Signed-off-by: Carlos Eduardo Arango Gutierrez --- README.md | 2 +- cmd/delete/delete.go | 3 +++ 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index e24cd1e9..45f30e4f 100644 --- a/README.md +++ b/README.md @@ -68,7 +68,7 @@ spec: - 192.168.1.0/26 image: architecture: amd64 - imageId: ami-0fe8bec493a81c7da + imageId: ami-0fe8bec493a81c7da # Ubuntu 22.04 image containerRuntime: install: true name: containerd diff --git a/cmd/delete/delete.go b/cmd/delete/delete.go index d8b692eb..697c7308 100644 --- a/cmd/delete/delete.go +++ b/cmd/delete/delete.go @@ -82,6 +82,9 @@ func (m command) build() *cli.Command { } // read hostUrl from cache + if opts.cachePath == "" { + opts.cachePath = filepath.Join(os.Getenv("HOME"), ".cache", "holodeck") + } opts.cachefile = filepath.Join(opts.cachePath, opts.cfg.Name+".yaml") opts.cache, err = jyaml.UnmarshalFromFile[v1alpha1.Environment](opts.cachefile) if err != nil {