qontract-reconcile 0.10.1rc110__py3-none-any.whl → 0.10.1rc111__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {qontract_reconcile-0.10.1rc110.dist-info → qontract_reconcile-0.10.1rc111.dist-info}/METADATA +1 -1
- {qontract_reconcile-0.10.1rc110.dist-info → qontract_reconcile-0.10.1rc111.dist-info}/RECORD +8 -8
- reconcile/jenkins_job_builder.py +0 -5
- reconcile/queries.py +0 -1
- tools/app_interface_reporter.py +8 -100
- {qontract_reconcile-0.10.1rc110.dist-info → qontract_reconcile-0.10.1rc111.dist-info}/WHEEL +0 -0
- {qontract_reconcile-0.10.1rc110.dist-info → qontract_reconcile-0.10.1rc111.dist-info}/entry_points.txt +0 -0
- {qontract_reconcile-0.10.1rc110.dist-info → qontract_reconcile-0.10.1rc111.dist-info}/top_level.txt +0 -0
{qontract_reconcile-0.10.1rc110.dist-info → qontract_reconcile-0.10.1rc111.dist-info}/METADATA
RENAMED
@@ -1,6 +1,6 @@
|
|
1
1
|
Metadata-Version: 2.1
|
2
2
|
Name: qontract-reconcile
|
3
|
-
Version: 0.10.
|
3
|
+
Version: 0.10.1rc111
|
4
4
|
Summary: Collection of tools to reconcile services with their desired state as defined in the app-interface DB.
|
5
5
|
Home-page: https://github.com/app-sre/qontract-reconcile
|
6
6
|
Author: Red Hat App-SRE Team
|
{qontract_reconcile-0.10.1rc110.dist-info → qontract_reconcile-0.10.1rc111.dist-info}/RECORD
RENAMED
@@ -33,7 +33,7 @@ reconcile/gitlab_permissions.py,sha256=ciEKj_wnRbS_vs_ZwcUeD6HkWVe3osAuotFqJSmvd
|
|
33
33
|
reconcile/gitlab_projects.py,sha256=K3tFf_aD1W4Ijp5q-9Qek3kwFGEWPcZ1kd7tzFJ4GyQ,1781
|
34
34
|
reconcile/integrations_manager.py,sha256=ed1kFdGG6Z2agbN_agSp-pIyCQMyegF-OzH2EpUTkv8,8878
|
35
35
|
reconcile/jenkins_base.py,sha256=0Gocu3fU2YTltaxBlbDQOUvP-7CP2OSQV1ZRwtWeVXw,875
|
36
|
-
reconcile/jenkins_job_builder.py,sha256=
|
36
|
+
reconcile/jenkins_job_builder.py,sha256=tfar8m5dyYlOZxgoMBvs1Woa698PftZCrCsvTzL3tLg,3930
|
37
37
|
reconcile/jenkins_job_builds_cleaner.py,sha256=zK8gQgXY5Ab5aDk8yPiXg0ogUEBOGmbyo8wEEtK342k,3190
|
38
38
|
reconcile/jenkins_job_cleaner.py,sha256=8DetVJsUFf68ZtUwaO9Vg9ohAsua2uA0Q6ykI4j3K0w,1794
|
39
39
|
reconcile/jenkins_roles.py,sha256=hOLPiPs2Juv7l8mGBj5-e88DqgvLbLldf0Xk0ylUzHE,4577
|
@@ -87,7 +87,7 @@ reconcile/quay_mirror.py,sha256=9pwl1gLzRpsVXF5yPULM4ET_C5F8_xPmH8Mv8AS2AfI,1340
|
|
87
87
|
reconcile/quay_mirror_org.py,sha256=E1OdRe-ppxTkNCwu20iVRhEdG1fPDBroLY02NgiMN7c,10381
|
88
88
|
reconcile/quay_permissions.py,sha256=_3PCWjNWoU7VHlYgHzUevvL_jJmEMsWfXV_nzjeiyhU,4099
|
89
89
|
reconcile/quay_repos.py,sha256=7609RBVQihis96FNOOe-i9tCTYwcTVy4WpKAL6HpnkU,7031
|
90
|
-
reconcile/queries.py,sha256=
|
90
|
+
reconcile/queries.py,sha256=lQpqysAzm2649BkJxhaue107LT-mOpmITTyKoLnTPls,48422
|
91
91
|
reconcile/query_validator.py,sha256=oLEZIAsQCzxmmZ7b9dSw-OKuEjpI1dbVu4XfCfjpmi8,1503
|
92
92
|
reconcile/requests_sender.py,sha256=914iluuF4UVgG3VyxxtnHOu4yf6YKS2fIy6PViSsFTQ,3875
|
93
93
|
reconcile/resource_scraper.py,sha256=vo1N9vLJCYWvXlTwFRIpEuWjx_39ZV9zxJlpoPq4g3U,2330
|
@@ -581,7 +581,7 @@ release/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
581
581
|
release/test_version.py,sha256=4DKxDZkT0aoS6ibZFsH2fd_wNETij1qfn2pCgQtVCGo,2093
|
582
582
|
release/version.py,sha256=Ud36t9FxGHLubMrE2o5aaaZRGB9_9hU_z0RN9go0TQM,3876
|
583
583
|
tools/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
584
|
-
tools/app_interface_reporter.py,sha256=
|
584
|
+
tools/app_interface_reporter.py,sha256=mLFxy-hmkrv_B_MdfNfM7CzYPgnTHxPAW7s_Vj5Zlt8,18271
|
585
585
|
tools/glitchtip_access_reporter.py,sha256=oPBnk_YoDuljU3v0FaChzOwwnk4vap1xEE67QEjzdqs,2948
|
586
586
|
tools/glitchtip_access_revalidation.py,sha256=PXN5wxl6OX8sxddPaakDF3X79nFLvpm-lz0mWLVelw0,2806
|
587
587
|
tools/qontract_cli.py,sha256=uH3Ouo5ce_ic36AL3-DAML0XEy447bHYER1EwmnrsVs,86963
|
@@ -592,8 +592,8 @@ tools/sre_checkpoints/util.py,sha256=zEDbGr18ZeHNQwW8pUsr2JRjuXIPz--WAGJxZo9sv_Y
|
|
592
592
|
tools/test/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
593
593
|
tools/test/test_qontract_cli.py,sha256=awwTHEc2DWlykuqGIYM0WOBoSL0KRnOraCLk3C7izis,1401
|
594
594
|
tools/test/test_sre_checkpoints.py,sha256=SKqPPTl9ua0RFdSSofnoQX-JZE6dFLO3LRhfQzqtfh8,2607
|
595
|
-
qontract_reconcile-0.10.
|
596
|
-
qontract_reconcile-0.10.
|
597
|
-
qontract_reconcile-0.10.
|
598
|
-
qontract_reconcile-0.10.
|
599
|
-
qontract_reconcile-0.10.
|
595
|
+
qontract_reconcile-0.10.1rc111.dist-info/METADATA,sha256=hUSHlw5n1svKbjQbz_vdzbuN4BZR5ikP2VYpYQR1pYY,2291
|
596
|
+
qontract_reconcile-0.10.1rc111.dist-info/WHEEL,sha256=pkctZYzUS4AYVn6dJ-7367OJZivF2e8RA9b_ZBjif18,92
|
597
|
+
qontract_reconcile-0.10.1rc111.dist-info/entry_points.txt,sha256=Af70EWPJxsTiCNF6gA-pWdw1A0Heqn-PZF-oBc5NmiU,302
|
598
|
+
qontract_reconcile-0.10.1rc111.dist-info/top_level.txt,sha256=l5ISPoXzt0SdR4jVdkfa7RPSKNc8zAHYWAnR-Dw8Ey8,24
|
599
|
+
qontract_reconcile-0.10.1rc111.dist-info/RECORD,,
|
reconcile/jenkins_job_builder.py
CHANGED
@@ -44,11 +44,6 @@ QONTRACT_INTEGRATION = "jenkins-job-builder"
|
|
44
44
|
GENERATE_TYPE = ["jobs", "views"]
|
45
45
|
|
46
46
|
|
47
|
-
def get_openshift_saas_deploy_job_name(saas_file_name, env_name, settings):
|
48
|
-
job_template_name = settings["saasDeployJobTemplate"]
|
49
|
-
return f"{job_template_name}-{saas_file_name}-{env_name}"
|
50
|
-
|
51
|
-
|
52
47
|
def get_jenkins_configs():
|
53
48
|
gqlapi = gql.get_api()
|
54
49
|
return gqlapi.query(QUERY)["jenkins_configs"]
|
reconcile/queries.py
CHANGED
tools/app_interface_reporter.py
CHANGED
@@ -25,14 +25,7 @@ from reconcile.cli import (
|
|
25
25
|
log_level,
|
26
26
|
threaded,
|
27
27
|
)
|
28
|
-
from reconcile.jenkins_job_builder import
|
29
|
-
get_openshift_saas_deploy_job_name,
|
30
|
-
init_jjb,
|
31
|
-
)
|
32
|
-
from reconcile.typed_queries.saas_files import (
|
33
|
-
export_model,
|
34
|
-
get_saas_files,
|
35
|
-
)
|
28
|
+
from reconcile.jenkins_job_builder import init_jjb
|
36
29
|
from reconcile.utils.jjb_client import JJB
|
37
30
|
from reconcile.utils.mr import CreateAppInterfaceReporter
|
38
31
|
from reconcile.utils.runtime.environment import init_env
|
@@ -231,7 +224,6 @@ def get_apps_data(date, month_delta=1, thread_pool_size=10):
|
|
231
224
|
secret_reader = SecretReader(settings)
|
232
225
|
|
233
226
|
apps = queries.get_apps()
|
234
|
-
saas_files = [export_model(saas_file) for saas_file in get_saas_files()]
|
235
227
|
jjb: JJB = init_jjb(secret_reader)
|
236
228
|
jenkins_map = jenkins_base.get_jenkins_map()
|
237
229
|
time_limit = date - relativedelta(months=month_delta)
|
@@ -256,22 +248,6 @@ def get_apps_data(date, month_delta=1, thread_pool_size=10):
|
|
256
248
|
build_jobs = jjb.get_all_jobs(job_types=["build"])
|
257
249
|
jobs_to_get = build_jobs.copy()
|
258
250
|
|
259
|
-
saas_deploy_jobs = []
|
260
|
-
for saas_file in saas_files:
|
261
|
-
saas_file_name = saas_file["name"]
|
262
|
-
for template in saas_file["resourceTemplates"]:
|
263
|
-
for target in template["targets"]:
|
264
|
-
job = {}
|
265
|
-
job["env"] = target["namespace"]["environment"]["name"]
|
266
|
-
job["app"] = target["namespace"]["app"]["name"]
|
267
|
-
job["cluster"] = target["namespace"]["cluster"]["name"]
|
268
|
-
job["namespace"] = target["namespace"]["name"]
|
269
|
-
job["name"] = get_openshift_saas_deploy_job_name(
|
270
|
-
saas_file_name, job["env"], settings
|
271
|
-
)
|
272
|
-
job["saas_file_name"] = saas_file_name
|
273
|
-
saas_deploy_jobs.append(job)
|
274
|
-
|
275
251
|
job_history = get_build_history_pool(
|
276
252
|
jenkins_map, jobs_to_get, timestamp_limit, thread_pool_size
|
277
253
|
)
|
@@ -283,84 +259,16 @@ def get_apps_data(date, month_delta=1, thread_pool_size=10):
|
|
283
259
|
app_name = app["name"]
|
284
260
|
|
285
261
|
logging.info(f"collecting post-deploy jobs " f"information for {app_name}")
|
286
|
-
|
287
|
-
|
288
|
-
|
289
|
-
|
290
|
-
resource_types = saas_file["managedResourceTypes"]
|
291
|
-
|
292
|
-
# Only jobs of these types are expected to have a
|
293
|
-
# further post-deploy job
|
294
|
-
if not any(
|
295
|
-
[
|
296
|
-
"Deployment" in resource_types,
|
297
|
-
"DeploymentConfig" not in resource_types,
|
298
|
-
]
|
299
|
-
):
|
300
|
-
continue
|
301
|
-
|
302
|
-
for resource_template in saas_file["resourceTemplates"]:
|
303
|
-
for target in resource_template["targets"]:
|
304
|
-
cluster = target["namespace"]["cluster"]["name"]
|
305
|
-
namespace = target["namespace"]["name"]
|
306
|
-
post_deploy_jobs[cluster] = {}
|
307
|
-
post_deploy_jobs[cluster][namespace] = False
|
308
|
-
|
309
|
-
for saas_file in saas_files:
|
310
|
-
if saas_file["app"]["name"] != app_name:
|
311
|
-
continue
|
312
|
-
resource_types = saas_file["managedResourceTypes"]
|
313
|
-
if "Job" not in resource_types:
|
314
|
-
continue
|
315
|
-
for resource_template in saas_file["resourceTemplates"]:
|
316
|
-
for target in resource_template["targets"]:
|
317
|
-
|
318
|
-
cluster = target["namespace"]["cluster"]["name"]
|
319
|
-
namespace = target["namespace"]["name"]
|
320
|
-
|
321
|
-
# This block skips the check if the cluster/namespace
|
322
|
-
# has no Deployment/DeploymentConfig job associated.
|
323
|
-
if cluster not in post_deploy_jobs:
|
324
|
-
continue
|
325
|
-
if namespace not in post_deploy_jobs[cluster]:
|
326
|
-
continue
|
327
|
-
|
328
|
-
# Post-deploy job must depend on a openshift-saas-deploy
|
329
|
-
# job
|
330
|
-
if target["upstream"] is None or target["upstream"]["name"] is None:
|
331
|
-
continue
|
332
|
-
if target["upstream"]["name"].startswith("openshift-saas-deploy-"):
|
333
|
-
post_deploy_jobs[cluster][namespace] = True
|
334
|
-
|
335
|
-
app["post_deploy_jobs"] = post_deploy_jobs
|
262
|
+
# this is now empty as it referred to post_deploy jobs via Jenkins. This section
|
263
|
+
# should be removed when we publish a new content format or if we get promotion data
|
264
|
+
# differently.
|
265
|
+
app["post_deploy_jobs"] = {}
|
336
266
|
|
337
267
|
logging.info(f"collecting promotion history for {app_name}")
|
338
268
|
app["promotions"] = {}
|
339
|
-
|
340
|
-
|
341
|
-
|
342
|
-
if job["name"] not in job_history:
|
343
|
-
continue
|
344
|
-
history = job_history[job["name"]]
|
345
|
-
saas_file_name = job["saas_file_name"]
|
346
|
-
if saas_file_name not in app["promotions"]:
|
347
|
-
app["promotions"][saas_file_name] = [
|
348
|
-
{
|
349
|
-
"env": job["env"],
|
350
|
-
"cluster": job["cluster"],
|
351
|
-
"namespace": job["namespace"],
|
352
|
-
**history,
|
353
|
-
}
|
354
|
-
]
|
355
|
-
else:
|
356
|
-
app["promotions"][saas_file_name].append(
|
357
|
-
{
|
358
|
-
"env": job["env"],
|
359
|
-
"cluster": job["cluster"],
|
360
|
-
"namespace": job["namespace"],
|
361
|
-
**history,
|
362
|
-
}
|
363
|
-
)
|
269
|
+
# this is now empty as it referred to saas files promotions via Jenkins. This section
|
270
|
+
# should be removed when we publish a new content format or if we get promotion data
|
271
|
+
# differently.
|
364
272
|
|
365
273
|
logging.info(f"collecting merge activity for {app_name}")
|
366
274
|
app["merge_activity"] = {}
|
File without changes
|
File without changes
|
{qontract_reconcile-0.10.1rc110.dist-info → qontract_reconcile-0.10.1rc111.dist-info}/top_level.txt
RENAMED
File without changes
|