added code to check if the allowed_hosts param was set in the configuration file, if it was, then add the extra hosts to allowed hosts
This commit is contained in:
parent
ef95ecfebc
commit
d9e5f5edd1
1 changed files with 9 additions and 0 deletions
|
|
@ -197,6 +197,15 @@ def get_config(branchname):
|
|||
dataobject.project.user = config['project']['user']
|
||||
dataobject.project.group = config['project']['group']
|
||||
|
||||
dataobject.project.allowedhosts = list()
|
||||
_allowed = getattr(dataobject.project, 'allowedhosts')
|
||||
_allowed.append(dataobject.project.extendedname)
|
||||
_allowed.append(dataobject.project.host)
|
||||
|
||||
if 'allowed_hosts' in config['project']:
|
||||
for allowed in config['project']['allowed_hosts']:
|
||||
_allowed.append(allowed)
|
||||
|
||||
dataobject.project.sudo = config['project']['sudo']
|
||||
|
||||
#
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue