Skip to content

Commit

Permalink
Add query for saasFilesV2 (#56)
Browse files Browse the repository at this point in the history
  • Loading branch information
bsquizz authored Jun 2, 2021
1 parent 3571b71 commit 93453b9
Showing 1 changed file with 23 additions and 1 deletion.
24 changes: 23 additions & 1 deletion bonfire/qontract.py
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,27 @@
}
}
}
saasFilesV2 {
path
name
parameters
resourceTemplates {
name
path
url
parameters
targets {
namespace {
name
cluster {
name
}
}
ref
parameters
}
}
}
}
}
"""
Expand Down Expand Up @@ -238,7 +259,8 @@ def get_apps_for_env(env_name):
if app["parentApp"] and app["parentApp"].get("name") != "insights":
ignored_apps.add(app["name"])
continue
for saas_file in app.get("saasFiles", []):
saas_files = app.get("saasFiles", []) + app.get("saasFilesV2", [])
for saas_file in saas_files:
for resource_template in saas_file.get("resourceTemplates", []):
for target in resource_template.get("targets", []):
if target["namespace"]["name"] in env["namespaces"]:
Expand Down

0 comments on commit 93453b9

Please sign in to comment.