Allow registering device without requiring the creation of the config file.
Some checks failed
Fly Deploy / Deploy app (push) Has been cancelled

Signed-off-by: jmug <u.g.a.mariano@gmail.com>
This commit is contained in:
Mariano Uvalle 2025-05-10 14:26:20 -07:00
parent c041a5feee
commit 8445a7546e
2 changed files with 12 additions and 5 deletions

View file

@ -22,7 +22,7 @@ type ConfigFile struct {
var Path string
func EnsureAndGet() (ConfigFile, error) {
err := os.MkdirAll(Path, os.FileMode(int(0660)))
err := os.MkdirAll(Path, os.FileMode(int(0770)))
if err != nil {
return ConfigFile{}, fmt.Errorf("could not create config directory: %w", err)
}
@ -38,7 +38,7 @@ func EnsureAndGet() (ConfigFile, error) {
}
func Write(c ConfigFile) error {
err := os.MkdirAll(Path, os.FileMode(int(0660)))
err := os.MkdirAll(Path, os.FileMode(int(0770)))
if err != nil {
return err
}