forked from TrueCloudLab/frostfs-node
[#1770] node: Reread config files on SIGHUP
Signed-off-by: Pavel Karpy <carpawell@nspcc.ru>
This commit is contained in:
parent
6fc3268ebf
commit
ab3ef7110e
2 changed files with 22 additions and 1 deletions
|
@ -154,6 +154,11 @@ func (a *applicationConfiguration) readConfig(c *config.Config) error {
|
|||
if a._read {
|
||||
// clear if it is rereading
|
||||
*a = applicationConfiguration{}
|
||||
|
||||
err := c.Reload()
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
} else {
|
||||
// update the status
|
||||
a._read = true
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue