forked from TrueCloudLab/frostfs-node
[#306] cmd/node: Rename permitted_keys config value to authorized_keys
Signed-off-by: Leonard Lyubich <leonard@nspcc.ru>
This commit is contained in:
parent
0a0ee89665
commit
73e99fa590
2 changed files with 3 additions and 3 deletions
|
@ -424,7 +424,7 @@ func defaultConfiguration(v *viper.Viper) {
|
||||||
v.SetDefault(cfgObjectRangePoolSize, 10)
|
v.SetDefault(cfgObjectRangePoolSize, 10)
|
||||||
v.SetDefault(cfgObjectRangeHashPoolSize, 10)
|
v.SetDefault(cfgObjectRangeHashPoolSize, 10)
|
||||||
|
|
||||||
v.SetDefault(cfgCtrlSvcAllowedKeys, []string{})
|
v.SetDefault(cfgCtrlSvcAuthorizedKeys, []string{})
|
||||||
}
|
}
|
||||||
|
|
||||||
func (c *cfg) LocalAddress() *network.Address {
|
func (c *cfg) LocalAddress() *network.Address {
|
||||||
|
|
|
@ -15,14 +15,14 @@ import (
|
||||||
const (
|
const (
|
||||||
cfgCtrlSvcSection = "control"
|
cfgCtrlSvcSection = "control"
|
||||||
|
|
||||||
cfgCtrlSvcAllowedKeys = cfgCtrlSvcSection + ".permitted_keys"
|
cfgCtrlSvcAuthorizedKeys = cfgCtrlSvcSection + ".authorized_keys"
|
||||||
|
|
||||||
cfgCtrlSvcGRPCSection = cfgCtrlSvcSection + ".grpc"
|
cfgCtrlSvcGRPCSection = cfgCtrlSvcSection + ".grpc"
|
||||||
cfgCtrlGRPCEndpoint = cfgCtrlSvcGRPCSection + ".endpoint"
|
cfgCtrlGRPCEndpoint = cfgCtrlSvcGRPCSection + ".endpoint"
|
||||||
)
|
)
|
||||||
|
|
||||||
func initControlService(c *cfg) {
|
func initControlService(c *cfg) {
|
||||||
strKeys := c.viper.GetStringSlice(cfgCtrlSvcAllowedKeys)
|
strKeys := c.viper.GetStringSlice(cfgCtrlSvcAuthorizedKeys)
|
||||||
keys := make([][]byte, 0, len(strKeys)+1) // +1 for node key
|
keys := make([][]byte, 0, len(strKeys)+1) // +1 for node key
|
||||||
|
|
||||||
keys = append(keys, crypto.MarshalPublicKey(&c.key.PublicKey))
|
keys = append(keys, crypto.MarshalPublicKey(&c.key.PublicKey))
|
||||||
|
|
Loading…
Reference in a new issue