Skip to content

Commit

Permalink
Get ARBORIST_URL from manifest (#304)
Browse files Browse the repository at this point in the history
  • Loading branch information
paulineribeyre authored Oct 4, 2019
1 parent d145442 commit b2e25bb
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 6 deletions.
6 changes: 4 additions & 2 deletions sheepdog/api.py
Original file line number Diff line number Diff line change
Expand Up @@ -149,8 +149,10 @@ def app_init(app):
except KeyError:
app.logger.error("Secret key not set in config! Authentication will not work")

if app.config.get("ARBORIST"):
app.auth = ArboristClient(arborist_base_url=app.config["ARBORIST"])
# ARBORIST deprecated, replaced by ARBORIST_URL
arborist_url = os.environ.get("ARBORIST_URL", os.environ.get("ARBORIST"))
if arborist_url:
app.auth = ArboristClient(arborist_base_url=arborist_url)
else:
app.logger.info("Using default Arborist base URL")
app.auth = ArboristClient()
Expand Down
2 changes: 0 additions & 2 deletions sheepdog/dev_settings.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,6 @@
"user_domain_name": env.get("KEYSTONE_DOMAIN"),
}

ARBORIST = "http://arborist-service/"

# Storage
CLEVERSAFE_HOST = env.get("CLEVERSAFE_HOST", "cleversafe.service.consul")

Expand Down
2 changes: 0 additions & 2 deletions sheepdog/test_settings.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,6 @@
"user_domain_name": "some_domain",
}

ARBORIST = "http://arborist-service/"

SUBMISSION = {"bucket": "test_submission", "host": "host"}


Expand Down

0 comments on commit b2e25bb

Please sign in to comment.