Skip to content

Commit

Permalink
Add the cluster.id node keyword to the node dict
Browse files Browse the repository at this point in the history
  • Loading branch information
cvaroqui committed Feb 6, 2018
1 parent 805c77c commit f4284ca
Show file tree
Hide file tree
Showing 2 changed files with 26 additions and 0 deletions.
13 changes: 13 additions & 0 deletions lib/nodedict.py
Expand Up @@ -826,6 +826,18 @@ def __init__(self):
text="The syslog host to send logs to. If neither host nor port are specified and if /dev/log exists, the messages are posted to /dev/log."
)

class KeywordClusterId(Keyword):
def __init__(self):
Keyword.__init__(
self,
section="cluster",
keyword="id",
at=True,
order=15,
default_text="<auto-generated>",
text="This information is fetched from the join command payload received from the joined node."
)

class KeywordClusterName(Keyword):
def __init__(self):
Keyword.__init__(
Expand Down Expand Up @@ -1183,6 +1195,7 @@ def __init__(self):
self += KeywordSyslogLevel()
self += KeywordSyslogHost()
self += KeywordSyslogPort()
self += KeywordClusterId()
self += KeywordClusterName()
self += KeywordClusterSecret()
self += KeywordClusterNodes()
Expand Down
13 changes: 13 additions & 0 deletions usr/share/doc/template.node.cluster.conf
Expand Up @@ -5,6 +5,19 @@
##############################################################################

[cluster]
#
# keyword: id
# ----------------------------------------------------------------------------
# scopable: True
# required: False
# default: <auto-generated>
# scope order: specific > generic
#
# desc: This information is fetched from the join command payload received
# from the joined node.
#
;id = <auto-generated>

#
# keyword: name
# ----------------------------------------------------------------------------
Expand Down

0 comments on commit f4284ca

Please sign in to comment.