qontract-reconcile 0.10.2.dev224__py3-none-any.whl → 0.10.2.dev225__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.dev224
3
+ Version: 0.10.2.dev225
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
@@ -72,7 +72,7 @@ reconcile/openshift_prometheus_rules.py,sha256=onowXab248zmHH8SbYDTc1W1bl7JiqRFU
72
72
  reconcile/openshift_resourcequotas.py,sha256=yUi56PiOn3inMMfq_x_FEHmaW-reGipzoorjdar372g,2415
73
73
  reconcile/openshift_resources.py,sha256=I2nO_C37mG3rfyGrd4cGwN3mVseVGuTAHAyhFzLyqF4,1518
74
74
  reconcile/openshift_resources_base.py,sha256=728-5nEmWMviSnhQH-EbEp_876VI2PGgC8LnrIfbD3U,42890
75
- reconcile/openshift_rhcs_certs.py,sha256=obaklp0i-FsmFhY6y7K4bGHKkAUbb86GqqEaYrBo9-4,9985
75
+ reconcile/openshift_rhcs_certs.py,sha256=wty5ayzcIebe4-Vlkf1Zi3UzVqBU8WUtYmsOiYviWNs,10070
76
76
  reconcile/openshift_rolebindings.py,sha256=9mlJ2FjWUoH-rsjtasreA_hV-K5Z_YR00qR_RR60OZM,6555
77
77
  reconcile/openshift_routes.py,sha256=fXvuPSjcjVw1X3j2EQvUAdbOepmIFdKk-M3qP8QzPiw,1075
78
78
  reconcile/openshift_saas_deploy.py,sha256=T1dvb9zajisaJNjbnR6-AZHU-itscHtr4oCqLj8KCK0,13037
@@ -803,7 +803,7 @@ tools/saas_promotion_state/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJ
803
803
  tools/saas_promotion_state/saas_promotion_state.py,sha256=UfwwRLS5Ya4_Nh1w5n1dvoYtchQvYE9yj1VANt2IKqI,3925
804
804
  tools/sre_checkpoints/__init__.py,sha256=CDaDaywJnmRCLyl_NCcvxi-Zc0hTi_3OdwKiFOyS39I,145
805
805
  tools/sre_checkpoints/util.py,sha256=zEDbGr18ZeHNQwW8pUsr2JRjuXIPz--WAGJxZo9sv_Y,894
806
- qontract_reconcile-0.10.2.dev224.dist-info/METADATA,sha256=W3Bf8U-jYuU4vmo0bGfEFaWsoWUiQWDY2nmeQBHvr6U,24431
807
- qontract_reconcile-0.10.2.dev224.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
808
- qontract_reconcile-0.10.2.dev224.dist-info/entry_points.txt,sha256=5i9l54La3vQrDLAdwDKQWC0iG4sV9RRfOb1BpvzOWLc,698
809
- qontract_reconcile-0.10.2.dev224.dist-info/RECORD,,
806
+ qontract_reconcile-0.10.2.dev225.dist-info/METADATA,sha256=8pazfuHM34ELarU5erW8_-a8xPXh51Ne0bpQrLYYRSg,24431
807
+ qontract_reconcile-0.10.2.dev225.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
808
+ qontract_reconcile-0.10.2.dev225.dist-info/entry_points.txt,sha256=5i9l54La3vQrDLAdwDKQWC0iG4sV9RRfOb1BpvzOWLc,698
809
+ qontract_reconcile-0.10.2.dev225.dist-info/RECORD,,
@@ -35,7 +35,7 @@ from reconcile.utils.rhcsv2_certs import RhcsV2Cert, generate_cert
35
35
  from reconcile.utils.runtime.integration import DesiredStateShardConfig
36
36
  from reconcile.utils.secret_reader import create_secret_reader
37
37
  from reconcile.utils.semver_helper import make_semver
38
- from reconcile.utils.vault import SecretNotFound, _VaultClient
38
+ from reconcile.utils.vault import SecretNotFound, VaultClient
39
39
 
40
40
  QONTRACT_INTEGRATION = "openshift-rhcs-certs"
41
41
  QONTRACT_INTEGRATION_VERSION = make_semver(1, 9, 3)
@@ -115,12 +115,12 @@ def cert_expires_within_threshold(
115
115
  def get_vault_cert_secret(
116
116
  ns: NamespaceV1,
117
117
  cert_resource: NamespaceOpenshiftResourceRhcsCertV1,
118
- vault: _VaultClient,
118
+ vault: VaultClient,
119
119
  vault_base_path: str,
120
120
  ) -> dict | None:
121
121
  vault_cert_secret = None
122
122
  try:
123
- vault_cert_secret = vault.read_all({
123
+ vault_cert_secret = vault.read_all({ # type: ignore[attr-defined]
124
124
  "path": f"{vault_base_path}/{ns.cluster.name}/{ns.name}/{cert_resource.secret_name}"
125
125
  })
126
126
  except SecretNotFound:
@@ -134,7 +134,7 @@ def generate_vault_cert_secret(
134
134
  dry_run: bool,
135
135
  ns: NamespaceV1,
136
136
  cert_resource: NamespaceOpenshiftResourceRhcsCertV1,
137
- vault: _VaultClient,
137
+ vault: VaultClient,
138
138
  vault_base_path: str,
139
139
  issuer_url: str,
140
140
  ca_cert_url: str,
@@ -142,7 +142,7 @@ def generate_vault_cert_secret(
142
142
  logging.info(
143
143
  f"Creating cert with service account credentials for '{cert_resource.service_account_name}'. cluster='{ns.cluster.name}', namespace='{ns.name}', secret='{cert_resource.secret_name}'"
144
144
  )
145
- sa_password = vault.read(cert_resource.service_account_password.dict())
145
+ sa_password = vault.read(cert_resource.service_account_password.dict()) # type: ignore[attr-defined]
146
146
  if dry_run:
147
147
  rhcs_cert = RhcsV2Cert(
148
148
  certificate="PLACEHOLDER_CERT",
@@ -162,7 +162,7 @@ def generate_vault_cert_secret(
162
162
  logging.info(
163
163
  f"Writing cert details to Vault at {vault_base_path}/{ns.cluster.name}/{ns.name}/{cert_resource.secret_name}"
164
164
  )
165
- vault.write(
165
+ vault.write( # type: ignore[attr-defined]
166
166
  secret={
167
167
  "data": rhcs_cert.dict(by_alias=True),
168
168
  "path": f"{vault_base_path}/{ns.cluster.name}/{ns.name}/{cert_resource.secret_name}",
@@ -176,7 +176,7 @@ def fetch_openshift_resource_for_cert_resource(
176
176
  dry_run: bool,
177
177
  ns: NamespaceV1,
178
178
  cert_resource: NamespaceOpenshiftResourceRhcsCertV1,
179
- vault: _VaultClient,
179
+ vault: VaultClient,
180
180
  rhcs_settings: RhcsProviderSettingsV1,
181
181
  ) -> OR:
182
182
  vault_base_path = f"{rhcs_settings.vault_base_path}/{QONTRACT_INTEGRATION}"
@@ -217,7 +217,7 @@ def fetch_desired_state(
217
217
  ri: ResourceInventory,
218
218
  query_func: Callable,
219
219
  ) -> None:
220
- vault = _VaultClient()
220
+ vault = VaultClient()
221
221
  cert_provider = get_rhcs_provider_settings(query_func=query_func)
222
222
 
223
223
  for ns in namespaces: