We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 30dfd9a commit 4bbeb19Copy full SHA for 4bbeb19
validate.go
@@ -53,7 +53,8 @@ var bundleValidateCommand = cli.Command{
53
logrus.Fatal(err)
54
}
55
56
- sf, err := os.Open(path.Join(inputPath, "config.json"))
+ configPath := path.Join(inputPath, "config.json")
57
+ sf, err := os.Open(configPath)
58
if err != nil {
59
60
@@ -75,6 +76,11 @@ var bundleValidateCommand = cli.Command{
75
76
} else if !fi.IsDir() {
77
logrus.Fatalf("Rootfs: %v is not a directory.", spec.Root.Path)
78
79
+
80
+ if path.Dir(configPath) != path.Dir(rootfsPath) {
81
+ logrus.Fatalf("Root filesystem and 'config.json' must be present in a single directory.")
82
+ }
83
84
bundleValidate(spec, rootfsPath)
85
logrus.Infof("Bundle validation succeeded.")
86
},
0 commit comments