qontract-reconcile 0.10.2.dev96__py3-none-any.whl → 0.10.2.dev97__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.2.dev96.dist-info → qontract_reconcile-0.10.2.dev97.dist-info}/METADATA +1 -1
- {qontract_reconcile-0.10.2.dev96.dist-info → qontract_reconcile-0.10.2.dev97.dist-info}/RECORD +6 -6
- reconcile/external_resources/aws.py +14 -0
- reconcile/external_resources/reconciler.py +1 -1
- {qontract_reconcile-0.10.2.dev96.dist-info → qontract_reconcile-0.10.2.dev97.dist-info}/WHEEL +0 -0
- {qontract_reconcile-0.10.2.dev96.dist-info → qontract_reconcile-0.10.2.dev97.dist-info}/entry_points.txt +0 -0
{qontract_reconcile-0.10.2.dev96.dist-info → qontract_reconcile-0.10.2.dev97.dist-info}/METADATA
RENAMED
@@ -1,6 +1,6 @@
|
|
1
1
|
Metadata-Version: 2.4
|
2
2
|
Name: qontract-reconcile
|
3
|
-
Version: 0.10.2.
|
3
|
+
Version: 0.10.2.dev97
|
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
|
{qontract_reconcile-0.10.2.dev96.dist-info → qontract_reconcile-0.10.2.dev97.dist-info}/RECORD
RENAMED
@@ -195,7 +195,7 @@ reconcile/endpoints_discovery/integration.py,sha256=ecjIZK_h6JO2wUhUmJlZ9pjOh60n
|
|
195
195
|
reconcile/endpoints_discovery/merge_request.py,sha256=_yLb4tnvoZMCko8rta2C_CvOInJa9pa3HzSmHNtjgGU,2978
|
196
196
|
reconcile/endpoints_discovery/merge_request_manager.py,sha256=a8zTIQIpRrUwXexZClwpQnnkEoS6XNZLJziI9x7ly0s,6389
|
197
197
|
reconcile/external_resources/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
198
|
-
reconcile/external_resources/aws.py,sha256=
|
198
|
+
reconcile/external_resources/aws.py,sha256=q9ub1vI4meG8YzM6A88Q422XkTu6Y3ja12GuMjCwISs,11631
|
199
199
|
reconcile/external_resources/factories.py,sha256=C0QHT0soEv6z99-ELAAE19S5MaMHhV0t1fSiQn0Coc4,5970
|
200
200
|
reconcile/external_resources/integration.py,sha256=JF38M7R0Z4ADUTx57TZqSZH9k_xpPlbAxQAcGyIISuM,6925
|
201
201
|
reconcile/external_resources/integration_secrets_sync.py,sha256=CImwt_tyS3MMGpkjI_0gZqYt4XgqIw4BtdJiDH2xrCk,1700
|
@@ -203,7 +203,7 @@ reconcile/external_resources/manager.py,sha256=mvFfcXPzvNqDWDgKTK8eiSe6C_FUvBtbe
|
|
203
203
|
reconcile/external_resources/meta.py,sha256=noaytFzmShpzLA_ebGh7wuP45mOfHIOnnoUxivjDa1I,672
|
204
204
|
reconcile/external_resources/metrics.py,sha256=KiBjMUaN_z0cSkF_7Ar_a8RiuiwVqjyMcVdISlxhzXE,3898
|
205
205
|
reconcile/external_resources/model.py,sha256=HrSkmAjOqw0aT3CsZKXKMLyocM__8XO5qHb-dXcoagw,13747
|
206
|
-
reconcile/external_resources/reconciler.py,sha256
|
206
|
+
reconcile/external_resources/reconciler.py,sha256=wB8cB5pmqDJ1_t5_Aly4mrULGnI3OQaKqUZCB_Z9RWw,9573
|
207
207
|
reconcile/external_resources/secrets_sync.py,sha256=ZDxzGZ6wC4zxLhA7-L39xDRH6rzUM285gytuzmRQdlw,16208
|
208
208
|
reconcile/external_resources/state.py,sha256=gF3ACdl7YiUlbQ4uEGrD6i_Txxqr6mT9f8IFlTQ-8dY,13176
|
209
209
|
reconcile/fleet_labeler/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
@@ -786,7 +786,7 @@ tools/saas_promotion_state/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJ
|
|
786
786
|
tools/saas_promotion_state/saas_promotion_state.py,sha256=UfwwRLS5Ya4_Nh1w5n1dvoYtchQvYE9yj1VANt2IKqI,3925
|
787
787
|
tools/sre_checkpoints/__init__.py,sha256=CDaDaywJnmRCLyl_NCcvxi-Zc0hTi_3OdwKiFOyS39I,145
|
788
788
|
tools/sre_checkpoints/util.py,sha256=zEDbGr18ZeHNQwW8pUsr2JRjuXIPz--WAGJxZo9sv_Y,894
|
789
|
-
qontract_reconcile-0.10.2.
|
790
|
-
qontract_reconcile-0.10.2.
|
791
|
-
qontract_reconcile-0.10.2.
|
792
|
-
qontract_reconcile-0.10.2.
|
789
|
+
qontract_reconcile-0.10.2.dev97.dist-info/METADATA,sha256=KiU0I9ajpxPWox3p0C64xeanHOSJ1CxNhJjgBDfTcrA,24565
|
790
|
+
qontract_reconcile-0.10.2.dev97.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
|
791
|
+
qontract_reconcile-0.10.2.dev97.dist-info/entry_points.txt,sha256=5i9l54La3vQrDLAdwDKQWC0iG4sV9RRfOb1BpvzOWLc,698
|
792
|
+
qontract_reconcile-0.10.2.dev97.dist-info/RECORD,,
|
@@ -139,6 +139,17 @@ class AWSRdsFactory(AWSDefaultResourceFactory):
|
|
139
139
|
"aws", provisioner, "kms", identifier
|
140
140
|
)
|
141
141
|
|
142
|
+
def _get_region_from_az(self, az: str) -> str:
|
143
|
+
if not az or len(az) < 2:
|
144
|
+
raise ValueError(
|
145
|
+
f"Invalid availability zone: '{az}'. Availability zone must have at least 2 characters."
|
146
|
+
)
|
147
|
+
if not az[-1].isalpha():
|
148
|
+
raise ValueError(
|
149
|
+
f"Invalid availability zone: '{az}'. The AZ should end with a letter (e.g., 'us-east-1a')."
|
150
|
+
)
|
151
|
+
return az[:-1]
|
152
|
+
|
142
153
|
def resolve(
|
143
154
|
self,
|
144
155
|
spec: ExternalResourceSpec,
|
@@ -168,6 +179,9 @@ class AWSRdsFactory(AWSDefaultResourceFactory):
|
|
168
179
|
"identifier": sourcedb["identifier"],
|
169
180
|
"region": sourcedb_region,
|
170
181
|
}
|
182
|
+
# If AZ is set, but not the region, the region is got from the AZ
|
183
|
+
if "availability_zone" in data and "region" not in data:
|
184
|
+
data["region"] = self._get_region_from_az(data["availability_zone"])
|
171
185
|
|
172
186
|
kms_key_id: str = data.get("kms_key_id", None)
|
173
187
|
if kms_key_id and not kms_key_id.startswith("arn:"):
|
@@ -85,7 +85,7 @@ class ReconciliationK8sJob(K8sJob, BaseModel, frozen=True):
|
|
85
85
|
return {
|
86
86
|
"provision_provider": self.reconciliation.key.provision_provider,
|
87
87
|
"provisioner": self.reconciliation.key.provisioner_name,
|
88
|
-
"provider": self.reconciliation.key.
|
88
|
+
"provider": self.reconciliation.key.provider,
|
89
89
|
"identifier": self.reconciliation.key.identifier,
|
90
90
|
}
|
91
91
|
|
{qontract_reconcile-0.10.2.dev96.dist-info → qontract_reconcile-0.10.2.dev97.dist-info}/WHEEL
RENAMED
File without changes
|
File without changes
|