nodes.py: autogenerate hostname if not set in nodefile
This commit is contained in:
parent
067b498bf2
commit
ae82e9cd51
3 changed files with 4 additions and 2 deletions
4
nodes.py
4
nodes.py
|
@ -5,3 +5,7 @@ nodes = {}
|
||||||
for node in Path(join(repo_path, "nodes")).rglob("*.py"):
|
for node in Path(join(repo_path, "nodes")).rglob("*.py"):
|
||||||
with open(node, 'r') as f:
|
with open(node, 'r') as f:
|
||||||
exec(f.read())
|
exec(f.read())
|
||||||
|
|
||||||
|
for name, data in nodes.items():
|
||||||
|
if 'hostname' not in data.keys():
|
||||||
|
data['hostname'] = '.'.join(reversed(name.split('.'))) + '.kunbox.net'
|
||||||
|
|
|
@ -1,5 +1,4 @@
|
||||||
nodes['htz-cloud.pirmasens'] = {
|
nodes['htz-cloud.pirmasens'] = {
|
||||||
'hostname': '195.201.90.143',
|
|
||||||
'bundles': [
|
'bundles': [
|
||||||
],
|
],
|
||||||
'metadata': {
|
'metadata': {
|
||||||
|
|
|
@ -1,5 +1,4 @@
|
||||||
nodes['htz.ex42-1048908'] = {
|
nodes['htz.ex42-1048908'] = {
|
||||||
'hostname': '94.130.52.224',
|
|
||||||
'bundles': [
|
'bundles': [
|
||||||
'nginx',
|
'nginx',
|
||||||
'riot-web',
|
'riot-web',
|
||||||
|
|
Loading…
Reference in a new issue