qontract-reconcile 0.10.2.dev36__py3-none-any.whl → 0.10.2.dev38__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.
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: qontract-reconcile
3
- Version: 0.10.2.dev36
3
+ Version: 0.10.2.dev38
4
4
  Summary: Collection of tools to reconcile services with their desired state as defined in the app-interface DB.
5
5
  Project-URL: homepage, https://github.com/app-sre/qontract-reconcile
6
6
  Project-URL: repository, https://github.com/app-sre/qontract-reconcile
@@ -195,7 +195,7 @@ reconcile/endpoints_discovery/integration.py,sha256=fzy5tv4c_6WoAZGGBNJ276NVNB1O
195
195
  reconcile/endpoints_discovery/merge_request.py,sha256=_yLb4tnvoZMCko8rta2C_CvOInJa9pa3HzSmHNtjgGU,2978
196
196
  reconcile/endpoints_discovery/merge_request_manager.py,sha256=wUMsumxv8RnWaRattax4HfoRlhtVzmgro3GiJJ1C4Vc,6392
197
197
  reconcile/external_resources/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
198
- reconcile/external_resources/aws.py,sha256=NSaOeHqFEcMaMxNjJwuQZosolgsJ8XRVvwkEEBj9vrw,7730
198
+ reconcile/external_resources/aws.py,sha256=2vimGEtcwcIyVaFvt5Ab2PAAWu2hawJyCu4fuZWSobI,7783
199
199
  reconcile/external_resources/factories.py,sha256=ldvm3n13IdE899Ei850NSf0RQ35rzsKJBCUkROrbE5Y,5579
200
200
  reconcile/external_resources/integration.py,sha256=JF38M7R0Z4ADUTx57TZqSZH9k_xpPlbAxQAcGyIISuM,6925
201
201
  reconcile/external_resources/integration_secrets_sync.py,sha256=dX09O3r6KURziUYYfiki10orNjOGVma-XojhVqd0ww4,1667
@@ -215,7 +215,7 @@ reconcile/glitchtip_project_alerts/integration.py,sha256=BgMx-NyV9mTuv7Sotb2OioC
215
215
  reconcile/glitchtip_project_dsn/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
216
216
  reconcile/glitchtip_project_dsn/integration.py,sha256=2iugub-kHYkHNK33n0v9_TeWonuxCPah_VkoTPvaajE,8077
217
217
  reconcile/gql_definitions/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
218
- reconcile/gql_definitions/introspection.json,sha256=WWQ1wCVxaP7aNIvIttoxVfFtZkODTopzAUv_bCZVNR4,2217602
218
+ reconcile/gql_definitions/introspection.json,sha256=ErIjLKDbNw4SLyGXhp9iGmL1RSfT0U7gU1A3tsn1674,2217790
219
219
  reconcile/gql_definitions/acs/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
220
220
  reconcile/gql_definitions/acs/acs_instances.py,sha256=L91WW9LbhJbBSrECqShQpFtjoBOsmNIYLRpMbx1io5o,2181
221
221
  reconcile/gql_definitions/acs/acs_policies.py,sha256=bN5i4mks10Z23KJSj7jqp966Osq2dps4d-sPH9gjxEA,7008
@@ -300,7 +300,7 @@ reconcile/gql_definitions/endpoints_discovery/apps.py,sha256=aBWRAwDUJQ32ghJS4cP
300
300
  reconcile/gql_definitions/external_resources/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
301
301
  reconcile/gql_definitions/external_resources/aws_accounts.py,sha256=XR69j9dpTQ0gv8y-AZN7AJ0dPvO-wbHscyCDgrax6Bk,2046
302
302
  reconcile/gql_definitions/external_resources/external_resources_modules.py,sha256=cbbvGq1Te9DP8XiFg3bp4Y0q6LxpGYov8ugcROPyPLI,2647
303
- reconcile/gql_definitions/external_resources/external_resources_namespaces.py,sha256=iW8zsC0eFULUVBTW9i2OHh3o7BTHiQIdmrJSk4CmjMo,45335
303
+ reconcile/gql_definitions/external_resources/external_resources_namespaces.py,sha256=dW7RrIA9gAJS7AHQwHggsJXhlSVnX0jV1c4W9e7a7Jc,45393
304
304
  reconcile/gql_definitions/external_resources/external_resources_settings.py,sha256=K8m9EKlfIVGP2KyqTduo7MMSKFjVC3yk5ZfO9hgdA7A,3192
305
305
  reconcile/gql_definitions/fragments/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
306
306
  reconcile/gql_definitions/fragments/aus_organization.py,sha256=uBKbTuBa3CZmTXR5HOcGhRcu2U9kM93KbYmoWTxcpB0,4767
@@ -323,7 +323,7 @@ reconcile/gql_definitions/fragments/prometheus_instance.py,sha256=12ltnV9kdEw6Ln
323
323
  reconcile/gql_definitions/fragments/resource_limits_requirements.py,sha256=ucskQ_a8RxvFl5-IWxz5kk3g4-5Pvh_W4N3nLmuKxi0,744
324
324
  reconcile/gql_definitions/fragments/resource_requests_requirements.py,sha256=TFKO4YALFPanSvZvIJFz0dCioBU7i73Q6hkDtGMvs9I,736
325
325
  reconcile/gql_definitions/fragments/resource_values.py,sha256=-N2lNRhWp8PgocmIeX3U9f3l90Q97N2lXoq1pXdb_LE,742
326
- reconcile/gql_definitions/fragments/saas_target_namespace.py,sha256=8kMXeD7u2bmdjn10zHmMJ80ScOhUp6KqSfWfjWZW-40,4001
326
+ reconcile/gql_definitions/fragments/saas_target_namespace.py,sha256=6f6WaerElaRi9_Ro-0CyWUkMHsbXlm0h9YXklftBwag,3991
327
327
  reconcile/gql_definitions/fragments/serviceaccount_token.py,sha256=2pG4rxAjvT-YsFBnm4zl301i7DCYznp99HOEGA-216I,1117
328
328
  reconcile/gql_definitions/fragments/terraform_state.py,sha256=S5QuTR9YlvUObiU7hevS9ybxZEssWoRGqCR9YtGwePs,1024
329
329
  reconcile/gql_definitions/fragments/upgrade_policy.py,sha256=cVza8zfra1E3yBsHiS-hKbys17fvv572GFnKshJjluE,1246
@@ -387,7 +387,7 @@ reconcile/gql_definitions/slack_usergroups/users.py,sha256=-_iOFxctoVpX2wJt1Drrk
387
387
  reconcile/gql_definitions/slo_documents/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
388
388
  reconcile/gql_definitions/slo_documents/slo_documents.py,sha256=pOrm9NXAonlo6Lxq6NkD3mHkZ53ZeBnZOZMkDvOEwds,3746
389
389
  reconcile/gql_definitions/status_board/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
390
- reconcile/gql_definitions/status_board/status_board.py,sha256=vHEzncabujkqbjJ-ibMYNJTODgTc4DMf4y6TW3I_7II,4700
390
+ reconcile/gql_definitions/status_board/status_board.py,sha256=BYq-1g_-AjNKHIKmY2rQT8l3ql4Mcwa_CIxN_FS4F6M,4690
391
391
  reconcile/gql_definitions/statuspage/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
392
392
  reconcile/gql_definitions/statuspage/statuspages.py,sha256=CTRzjiR9k41LqlkgyoNHwC2JERsoD_Run_aK7jw_Ono,5299
393
393
  reconcile/gql_definitions/templating/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
@@ -579,7 +579,7 @@ reconcile/utils/environ.py,sha256=psk07d2xyjbUzjOCDdNWgavaNolL_t2sq3sn2gFfY9k,50
579
579
  reconcile/utils/exceptions.py,sha256=DwfnWUpVOotpP79RWZ2pycmG6nKCL00RBIeZLYkQPW4,635
580
580
  reconcile/utils/expiration.py,sha256=3JaXH4psksR7z262k7FmdyREjCLqm66OpVMEbcfdWRo,1213
581
581
  reconcile/utils/extended_early_exit.py,sha256=QSktrmfw37zSRMNk930tDbQsVeKxaPPPD43e79DGwZw,6754
582
- reconcile/utils/external_resource_spec.py,sha256=bhH_xneFwATdFumTPkiQmcVKYI0gcaWuqV6FpFdf_P0,7006
582
+ reconcile/utils/external_resource_spec.py,sha256=qeupz4t4trd2uPjlHjf_AFA9Y-EKrMnaXi72tAuCxig,7177
583
583
  reconcile/utils/external_resources.py,sha256=YzTb0xAcNdmKO326mGQy7BmST56CZcdru4lX7ai_7kw,7579
584
584
  reconcile/utils/filtering.py,sha256=S4PbMHuFr3ED0P2Q_ea5CAaB7FimI62B-F5YTaKrphA,402
585
585
  reconcile/utils/git.py,sha256=wzVIYAeKlMGW538U1mkJWUI6h_mFRUY4lawh2AR8hw4,2345
@@ -746,7 +746,7 @@ tools/app_sre_tekton_access_reporter.py,sha256=o9prLUgQpwO3msRWc2as1xT1y9OB3znkp
746
746
  tools/app_sre_tekton_access_revalidation.py,sha256=66nHEaY-bIqxIhpcmwN8AvQZu6ZXenfkg4Fut0pVZRM,2726
747
747
  tools/glitchtip_access_reporter.py,sha256=o01A6b88t3Wie6tj_tJWWVo2J01LxQ_a9giGm4UzEaU,2901
748
748
  tools/glitchtip_access_revalidation.py,sha256=8kbBJk04mkq28kWoRDDkfCGIF3GRg3pJrFAh1sW0dbk,2821
749
- tools/qontract_cli.py,sha256=76jUbYqgF_ViudSg4rAJCBCLrrQV5aR0nMSlZwH3MWU,147170
749
+ tools/qontract_cli.py,sha256=6nb6kl6-1ZQpvBeUXEkeahUfIrTDUdEynkVTNLklj6o,147182
750
750
  tools/sd_app_sre_alert_report.py,sha256=jQpJdXVID68bSNtJNOGDh0-ei1CfEUS4Itr4MAaBNFA,5062
751
751
  tools/template_validation.py,sha256=qpKYaTgk0GOPGa2Ct5_5sKdwIHtCAKIBGzsMPuJU5fw,3371
752
752
  tools/cli_commands/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
@@ -773,7 +773,7 @@ tools/saas_promotion_state/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJ
773
773
  tools/saas_promotion_state/saas_promotion_state.py,sha256=UfwwRLS5Ya4_Nh1w5n1dvoYtchQvYE9yj1VANt2IKqI,3925
774
774
  tools/sre_checkpoints/__init__.py,sha256=CDaDaywJnmRCLyl_NCcvxi-Zc0hTi_3OdwKiFOyS39I,145
775
775
  tools/sre_checkpoints/util.py,sha256=zEDbGr18ZeHNQwW8pUsr2JRjuXIPz--WAGJxZo9sv_Y,894
776
- qontract_reconcile-0.10.2.dev36.dist-info/METADATA,sha256=TejW9L2qpoaGZmHQWVfvzeJ8qKB4L3lB7m3H3y18e2U,24665
777
- qontract_reconcile-0.10.2.dev36.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
778
- qontract_reconcile-0.10.2.dev36.dist-info/entry_points.txt,sha256=5i9l54La3vQrDLAdwDKQWC0iG4sV9RRfOb1BpvzOWLc,698
779
- qontract_reconcile-0.10.2.dev36.dist-info/RECORD,,
776
+ qontract_reconcile-0.10.2.dev38.dist-info/METADATA,sha256=YJv3o5j9e942RRf35TXd_ZICybLaOgLgeRCBuEHtfO0,24665
777
+ qontract_reconcile-0.10.2.dev38.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
778
+ qontract_reconcile-0.10.2.dev38.dist-info/entry_points.txt,sha256=5i9l54La3vQrDLAdwDKQWC0iG4sV9RRfOb1BpvzOWLc,698
779
+ qontract_reconcile-0.10.2.dev38.dist-info/RECORD,,
@@ -58,6 +58,8 @@ class AWSElasticacheFactory(AWSDefaultResourceFactory):
58
58
  if "replication_group_id" not in data:
59
59
  data["replication_group_id"] = spec.identifier
60
60
 
61
+ data["environment"] = spec.environment_type
62
+
61
63
  if cluster_mode := data.pop("cluster_mode", {}):
62
64
  for k, v in cluster_mode.items():
63
65
  data[k] = v
@@ -505,6 +505,7 @@ query ExternalResourcesNamespaces {
505
505
  }
506
506
  environment {
507
507
  name
508
+ labels
508
509
  }
509
510
  app {
510
511
  path
@@ -1071,6 +1072,7 @@ class NamespaceTerraformProviderResourceAWSV1(NamespaceExternalResourceV1):
1071
1072
 
1072
1073
  class EnvironmentV1(ConfiguredBaseModel):
1073
1074
  name: str = Field(..., alias="name")
1075
+ labels: str = Field(..., alias="labels")
1074
1076
 
1075
1077
 
1076
1078
  class AppV1(ConfiguredBaseModel):
@@ -34,7 +34,7 @@ class SaasSecretParametersV1(ConfiguredBaseModel):
34
34
 
35
35
  class EnvironmentV1(ConfiguredBaseModel):
36
36
  name: str = Field(..., alias="name")
37
- labels: Optional[Json] = Field(..., alias="labels")
37
+ labels: Json = Field(..., alias="labels")
38
38
  parameters: Optional[Json] = Field(..., alias="parameters")
39
39
  secret_parameters: Optional[list[SaasSecretParametersV1]] = Field(..., alias="secretParameters")
40
40
 
@@ -16224,9 +16224,13 @@
16224
16224
  "description": null,
16225
16225
  "args": [],
16226
16226
  "type": {
16227
- "kind": "SCALAR",
16228
- "name": "JSON",
16229
- "ofType": null
16227
+ "kind": "NON_NULL",
16228
+ "name": null,
16229
+ "ofType": {
16230
+ "kind": "SCALAR",
16231
+ "name": "JSON",
16232
+ "ofType": null
16233
+ }
16230
16234
  },
16231
16235
  "isDeprecated": false,
16232
16236
  "deprecationReason": null
@@ -119,7 +119,7 @@ class NamespaceV1(ConfiguredBaseModel):
119
119
 
120
120
  class EnvironmentV1(ConfiguredBaseModel):
121
121
  name: str = Field(..., alias="name")
122
- labels: Optional[Json] = Field(..., alias="labels")
122
+ labels: Json = Field(..., alias="labels")
123
123
  product: ProductV1 = Field(..., alias="product")
124
124
  namespaces: Optional[list[NamespaceV1]] = Field(..., alias="namespaces")
125
125
 
@@ -116,6 +116,11 @@ class ExternalResourceSpec:
116
116
  def cluster_name(self) -> str:
117
117
  return self.namespace["cluster"]["name"]
118
118
 
119
+ @property
120
+ def environment_type(self) -> str:
121
+ labels = json.loads(self.namespace["environment"]["labels"])
122
+ return labels.get("type", "production")
123
+
119
124
  @property
120
125
  def output_prefix(self) -> str:
121
126
  # Adhere to DNS-1123 subdomain names spec. It's reasonable to have provider
tools/qontract_cli.py CHANGED
@@ -2156,7 +2156,7 @@ def app_interface_merge_queue(ctx):
2156
2156
  settings = queries.get_app_interface_settings()
2157
2157
  instance = queries.get_gitlab_instance()
2158
2158
  gl = GitLabApi(instance, project_url=settings["repoUrl"], settings=settings)
2159
- merge_requests = glhk.get_merge_requests(True, gl)
2159
+ merge_requests = glhk.get_merge_requests(True, gl, state=None)
2160
2160
 
2161
2161
  columns = [
2162
2162
  "id",