From e63f9faab8d1b7cff4a0322e5c124830cf7502f6 Mon Sep 17 00:00:00 2001 From: Leonard Lyubich Date: Wed, 10 Feb 2021 13:47:49 +0300 Subject: [PATCH] [#316] cmd/node: Make UN-LOCODE attribute mandatory in the configuration Signed-off-by: Leonard Lyubich --- cmd/neofs-node/attributes.go | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/cmd/neofs-node/attributes.go b/cmd/neofs-node/attributes.go index 36990d6b7..d2a188334 100644 --- a/cmd/neofs-node/attributes.go +++ b/cmd/neofs-node/attributes.go @@ -46,10 +46,14 @@ type wellKnownNodeAttrDesc struct { defaultVal string } +// TODO: define attribute keys in API lib. +const attrKeyLocode = "UN-LOCODE" + func listWellKnownAttrDesc() map[string]wellKnownNodeAttrDesc { return map[string]wellKnownNodeAttrDesc{ netmap.PriceAttr: {defaultVal: strconv.FormatUint(defaultPrice, 10)}, netmap.CapacityAttr: {defaultVal: strconv.FormatUint(defaultCapacity, 10)}, + attrKeyLocode: {explicit: true}, } }