From 473ecd7e96735382d11e47df16c18edd4e440b8c Mon Sep 17 00:00:00 2001 From: Gregory Kurtzer Date: Mon, 13 Sep 2021 22:30:49 -0700 Subject: [PATCH] Allow chmod on both file and directory --- internal/app/wwctl/overlay/chmod/main.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/internal/app/wwctl/overlay/chmod/main.go b/internal/app/wwctl/overlay/chmod/main.go index b6eb4cad..1e95b451 100644 --- a/internal/app/wwctl/overlay/chmod/main.go +++ b/internal/app/wwctl/overlay/chmod/main.go @@ -44,7 +44,7 @@ func CobraRunE(cmd *cobra.Command, args []string) error { overlayFile := path.Join(overlaySourceDir, fileName) - if !util.IsFile(overlayFile) { + if !util.IsFile(overlayFile) && !util.IsDir(overlayFile) { wwlog.Printf(wwlog.ERROR, "File does not exist within overlay: %s:%s\n", overlayName, fileName) os.Exit(1) }