Skip to content

Commit

Permalink
Change site and machine namespace to use continent name
Browse files Browse the repository at this point in the history
- Used to be hub fullname previously which is not exported to the object
plenary, making impossible to locate the site template (not included
by default in the object plenary)
- Hosts must be rebuilt to use the new namespace

Fixes quattor#104

Change-Id: I71e59ffa750a264b88ecf35ae3e6ebecd73f98e2
  • Loading branch information
jouvin authored and Aquilon main user committed Jul 13, 2018
1 parent f991825 commit bc863fd
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion lib/aquilon/worker/templates/city.py
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ class PlenaryCity(Plenary):

@classmethod
def template_name(cls, dbcity):
return "%s/%s/%s/config" % (cls.prefix, dbcity.hub.fullname.lower(),
return "%s/%s/%s/config" % (cls.prefix, dbcity.continent.name,
dbcity.name)

def body(self, lines):
Expand Down
2 changes: 1 addition & 1 deletion lib/aquilon/worker/templates/machine.py
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ def get_rack_name(cls, dbmachine):
@classmethod
def template_name(cls, dbmachine):
loc = dbmachine.location
return "%s/%s/%s/%s/%s" % (cls.prefix, loc.hub.fullname.lower(),
return "%s/%s/%s/%s/%s" % (cls.prefix, loc.continent.name,
loc.building, cls.get_rack_name(dbmachine), dbmachine.label)

def __init__(self, dbobj, **kwargs):
Expand Down

0 comments on commit bc863fd

Please sign in to comment.