Skip to content
This repository has been archived by the owner on Oct 3, 2020. It is now read-only.

Commit

Permalink
#31 fix application look up
Browse files Browse the repository at this point in the history
  • Loading branch information
hjacobs committed Jul 31, 2018
1 parent 6d5cbd7 commit eceffdb
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions kube_resource_report/report.py
Original file line number Diff line number Diff line change
Expand Up @@ -339,14 +339,16 @@ def get_cluster_summaries(

def resolve_application_ids(applications: dict, teams: dict, application_registry: str):
with FuturesSession(max_workers=10, session=session) as futures_session:
futures_session.auth = cluster_discovery.OAuthTokenAuth("read-only")
auth = cluster_discovery.OAuthTokenAuth("read-only")

future_to_app = {}
for app_id, app in applications.items():
if app_id:
future_to_app[
futures_session.get(
application_registry + "/apps/" + app_id, timeout=5
application_registry + "/apps/" + app_id,
auth=auth,
timeout=5
)
] = app

Expand Down

0 comments on commit eceffdb

Please sign in to comment.