From d04023572e47e5c18fa549fe7f7de301e8470c63 Mon Sep 17 00:00:00 2001 From: akutz Date: Wed, 2 Dec 2015 15:20:09 -0600 Subject: [PATCH] Fix for not setting Gofig global/user dirs This patch fixes the issue where the Gofig's global (/etc) and user ($HOME) directories were not set, resulting in the default config files not being loaded. --- core/core.go | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/core/core.go b/core/core.go index e1f4f1e9c..8a1ef5291 100644 --- a/core/core.go +++ b/core/core.go @@ -1,11 +1,19 @@ package core import ( + "fmt" + "github.com/akutz/gofig" + + "github.com/emccode/rexray/util" ) func init() { initDrivers() + + gofig.SetGlobalConfigPath(util.EtcDirPath()) + gofig.SetUserConfigPath(fmt.Sprintf("%s/.rexray", util.HomeDir())) + gofig.Register(globalRegistration()) gofig.Register(driverRegistration()) }