Many fixes on code quality and CI #129

Merged
metal3d merged 21 commits from develop into master 2025-07-06 13:37:08 +00:00
2 changed files with 3 additions and 3 deletions
Showing only changes of commit 8999aabc21 - Show all commits

View File

@@ -95,7 +95,7 @@ func (chart *HelmChart) SaveTemplates(templateDir string) {
} }
servicename := template.Servicename servicename := template.Servicename
if err := os.MkdirAll(filepath.Join(templateDir, servicename), 0o755); err != nil { if err := os.MkdirAll(filepath.Join(templateDir, servicename), 0o600); err != nil {
fmt.Println(utils.IconFailure, err) fmt.Println(utils.IconFailure, err)
os.Exit(1) os.Exit(1)
} }
@@ -103,7 +103,7 @@ func (chart *HelmChart) SaveTemplates(templateDir string) {
// if the name is a path, create the directory // if the name is a path, create the directory
if strings.Contains(name, string(filepath.Separator)) { if strings.Contains(name, string(filepath.Separator)) {
name = filepath.Join(templateDir, name) name = filepath.Join(templateDir, name)
err := os.MkdirAll(filepath.Dir(name), 0o755) err := os.MkdirAll(filepath.Dir(name), 0o600)
if err != nil { if err != nil {
fmt.Println(utils.IconFailure, err) fmt.Println(utils.IconFailure, err)
os.Exit(1) os.Exit(1)

View File

@@ -173,7 +173,7 @@ func Convert(config ConvertOptions, dockerComposeFile ...string) error {
os.RemoveAll(config.OutputDir) os.RemoveAll(config.OutputDir)
// create the chart directory // create the chart directory
if err := os.MkdirAll(templateDir, 0o755); err != nil { if err := os.MkdirAll(templateDir, 0o600); err != nil {
fmt.Println(utils.IconFailure, err) fmt.Println(utils.IconFailure, err)
os.Exit(1) os.Exit(1)
} }