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

Commit

Permalink
accept Ingress without rules
Browse files Browse the repository at this point in the history
  • Loading branch information
hjacobs committed Dec 1, 2018
1 parent b776bb7 commit 56bf2b9
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion kube_resource_report/report.py
Original file line number Diff line number Diff line change
Expand Up @@ -303,7 +303,7 @@ def query_cluster(
namespace, name = item["metadata"]["namespace"], item["metadata"]["name"]
labels = item["metadata"].get("labels", {})
application = labels.get("application", labels.get("app", ""))
for rule in item["spec"]["rules"]:
for rule in item["spec"].get("rules", []):
host = rule.get('host', '')
ingress = [namespace, name, application, host, 0]
if host and not no_ingress_status:
Expand Down

0 comments on commit 56bf2b9

Please sign in to comment.