refactor: move registry path to const
This commit is contained in:
1 parent
a90f6bdee8
commit
e13561ec4d
3 files changed
+5
-4
No files matched your search
@@ -76,7 +76,7 @@ func CommandInitialize() error {
|
||||
return fmt.Errorf("Error installing k3s: %w", installerCmd.ExitError)
|
||||
}
|
||||
|
||||
if err := common.TouchFile("/etc/rancher/k3s/registries.yaml"); err != nil {
|
||||
if err := common.TouchFile(RegistryConfigPath); err != nil {
|
||||
return fmt.Errorf("Error creating initial registries.yaml file")
|
||||
}
|
||||
|
||||
@@ -84,7 +84,7 @@ func CommandInitialize() error {
|
||||
"setfacl",
|
||||
"-m",
|
||||
"user:dokku:rwx",
|
||||
"/etc/rancher/k3s/registries.yaml",
|
||||
RegistryConfigPath,
|
||||
}, " "))
|
||||
if !registryAclCmd.Execute() {
|
||||
return fmt.Errorf("Error updating acls on k3s registries.yaml file: %w", registryAclCmd.ExitError)
|
||||
|
||||
Reference in new issue
Block a user