mirror of
https://github.com/xcat2/confluent.git
synced 2024-11-23 10:02:04 +00:00
Add dns domain to deployment
This permits the deployment profiles to pull in specified DNS domain.
This commit is contained in:
parent
eec7236110
commit
e696566b42
@ -491,6 +491,9 @@ node = {
|
||||
'description': ('Fingerprint of the SSH key of the OS running on the '
|
||||
'system.'),
|
||||
},
|
||||
'dns.domain': {
|
||||
'description': 'DNS Domain searched by default by the system'
|
||||
},
|
||||
'dns.servers': {
|
||||
'description': 'DNS Server or servers to provide to node',
|
||||
},
|
||||
|
@ -64,7 +64,7 @@ def handle_request(env, start_response):
|
||||
ncfg['ipv4_netmask'] = netutil.cidr_to_mask(ncfg['prefix'])
|
||||
deployinfo = cfg.get_node_attributes(
|
||||
nodename, ('deployment.*', 'console.method', 'crypted.rootpassword',
|
||||
'services.*'))
|
||||
'dns.*'))
|
||||
deployinfo = deployinfo.get(nodename, {})
|
||||
profile = deployinfo.get(
|
||||
'deployment.pendingprofile', {}).get('value', '')
|
||||
@ -117,6 +117,8 @@ def handle_request(env, start_response):
|
||||
for dns in deployinfo.get(
|
||||
'dns.servers', {}).get('value', '').split(','):
|
||||
ncfg['nameservers'].append(dns)
|
||||
dnsdomain = dedployinfo.get('dns.domain', {}).get('value', None)
|
||||
ncfg['dnsdomain'] = dnsdomain
|
||||
start_response('200 OK', (('Content-Type', retype),))
|
||||
yield dumper(ncfg)
|
||||
elif env['PATH_INFO'] == '/self/sshcert':
|
||||
|
Loading…
Reference in New Issue
Block a user