diff options
Diffstat (limited to 'service/env/service.go')
-rw-r--r-- | service/env/service.go | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/service/env/service.go b/service/env/service.go index 0822d55a..b32a2f2b 100644 --- a/service/env/service.go +++ b/service/env/service.go @@ -15,7 +15,7 @@ func NewService(defaults map[string]string) *Service { if s.values == nil { s.values = make(map[string]string) } - + return s } @@ -33,3 +33,8 @@ func (s *Service) Init(cfg *Config) (bool, error) { func (s *Service) GetEnv() (map[string]string, error) { return s.values, nil } + +// SetEnv sets or creates environment value. +func (s *Service) SetEnv(key, value string) { + s.values[key] = value +} |