qontract-reconcile 0.10.2.dev88__py3-none-any.whl → 0.10.2.dev90__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.dev88.dist-info → qontract_reconcile-0.10.2.dev90.dist-info}/METADATA +1 -1
- {qontract_reconcile-0.10.2.dev88.dist-info → qontract_reconcile-0.10.2.dev90.dist-info}/RECORD +10 -10
- reconcile/external_resources/integration_secrets_sync.py +4 -1
- reconcile/fleet_labeler/integration.py +4 -0
- reconcile/fleet_labeler/merge_request.py +1 -0
- reconcile/fleet_labeler/ocm.py +5 -1
- reconcile/gql_definitions/fleet_labeler/fleet_labels.py +2 -0
- reconcile/gql_definitions/introspection.json +16 -0
- {qontract_reconcile-0.10.2.dev88.dist-info → qontract_reconcile-0.10.2.dev90.dist-info}/WHEEL +0 -0
- {qontract_reconcile-0.10.2.dev88.dist-info → qontract_reconcile-0.10.2.dev90.dist-info}/entry_points.txt +0 -0
{qontract_reconcile-0.10.2.dev88.dist-info → qontract_reconcile-0.10.2.dev90.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.dev90
|
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.dev88.dist-info → qontract_reconcile-0.10.2.dev90.dist-info}/RECORD
RENAMED
@@ -198,7 +198,7 @@ reconcile/external_resources/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NM
|
|
198
198
|
reconcile/external_resources/aws.py,sha256=wzN3GHxyqVa4Lqqg5HdogqNW2RM532t0ZiKaQeVGOL4,10968
|
199
199
|
reconcile/external_resources/factories.py,sha256=C0QHT0soEv6z99-ELAAE19S5MaMHhV0t1fSiQn0Coc4,5970
|
200
200
|
reconcile/external_resources/integration.py,sha256=JF38M7R0Z4ADUTx57TZqSZH9k_xpPlbAxQAcGyIISuM,6925
|
201
|
-
reconcile/external_resources/integration_secrets_sync.py,sha256=
|
201
|
+
reconcile/external_resources/integration_secrets_sync.py,sha256=CImwt_tyS3MMGpkjI_0gZqYt4XgqIw4BtdJiDH2xrCk,1700
|
202
202
|
reconcile/external_resources/manager.py,sha256=mvFfcXPzvNqDWDgKTK8eiSe6C_FUvBtben3bSqrqSoc,18246
|
203
203
|
reconcile/external_resources/meta.py,sha256=noaytFzmShpzLA_ebGh7wuP45mOfHIOnnoUxivjDa1I,672
|
204
204
|
reconcile/external_resources/metrics.py,sha256=KiBjMUaN_z0cSkF_7Ar_a8RiuiwVqjyMcVdISlxhzXE,3898
|
@@ -208,11 +208,11 @@ reconcile/external_resources/secrets_sync.py,sha256=ZDxzGZ6wC4zxLhA7-L39xDRH6rzU
|
|
208
208
|
reconcile/external_resources/state.py,sha256=gF3ACdl7YiUlbQ4uEGrD6i_Txxqr6mT9f8IFlTQ-8dY,13176
|
209
209
|
reconcile/fleet_labeler/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
210
210
|
reconcile/fleet_labeler/dependencies.py,sha256=ZOpmtwgxEPBWU2yHRc6rhPwlvqhwYSsNMJQ_jVq1dLI,2993
|
211
|
-
reconcile/fleet_labeler/integration.py,sha256=
|
212
|
-
reconcile/fleet_labeler/merge_request.py,sha256=
|
211
|
+
reconcile/fleet_labeler/integration.py,sha256=GR-LUDfDp29VNy1aSLun1UwEOQ1AAXXC18ZdngdCsRg,8976
|
212
|
+
reconcile/fleet_labeler/merge_request.py,sha256=SfGxXInxeJzVnsTtO0ZC9-PesUJMdpKxKY9eCB6ms-g,1538
|
213
213
|
reconcile/fleet_labeler/meta.py,sha256=DF7O4T9wvQ7-xTWXvuNw1OG_F0SBmRrjFBtVy9wWh9U,146
|
214
214
|
reconcile/fleet_labeler/metrics.py,sha256=wx9BmXLsN67m-aSsf81iB7Ehj5SzUsS2WB75isUReZg,662
|
215
|
-
reconcile/fleet_labeler/ocm.py,sha256=
|
215
|
+
reconcile/fleet_labeler/ocm.py,sha256=25UVRQDcbcJFQgg4WDXvUI5M8w9yqr0noiy90-sbQjY,2699
|
216
216
|
reconcile/fleet_labeler/validate.py,sha256=gzc2tt7h9F60h7dcyJfEmsnjnfuux5Jtc_WzrIqr-5k,2541
|
217
217
|
reconcile/fleet_labeler/vcs.py,sha256=6UHUQ08AGAHXF7629I6X-T_E1pvx96LxjS66EeOzve4,1108
|
218
218
|
reconcile/glitchtip/README.md,sha256=rfXT6jNP9khJW65jL7I2PgoxvxgcGGuJF8NpbzufEQ4,4335
|
@@ -224,7 +224,7 @@ reconcile/glitchtip_project_alerts/integration.py,sha256=BgMx-NyV9mTuv7Sotb2OioC
|
|
224
224
|
reconcile/glitchtip_project_dsn/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
225
225
|
reconcile/glitchtip_project_dsn/integration.py,sha256=2iugub-kHYkHNK33n0v9_TeWonuxCPah_VkoTPvaajE,8077
|
226
226
|
reconcile/gql_definitions/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
227
|
-
reconcile/gql_definitions/introspection.json,sha256=
|
227
|
+
reconcile/gql_definitions/introspection.json,sha256=nBoWZM_ilrKlbCUF9cbRe7D1jsTqHqfGkLQW2gbleBM,2239254
|
228
228
|
reconcile/gql_definitions/acs/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
229
229
|
reconcile/gql_definitions/acs/acs_instances.py,sha256=L91WW9LbhJbBSrECqShQpFtjoBOsmNIYLRpMbx1io5o,2181
|
230
230
|
reconcile/gql_definitions/acs/acs_policies.py,sha256=bN5i4mks10Z23KJSj7jqp966Osq2dps4d-sPH9gjxEA,7008
|
@@ -314,7 +314,7 @@ reconcile/gql_definitions/external_resources/external_resources_settings.py,sha2
|
|
314
314
|
reconcile/gql_definitions/external_resources/fragments/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
315
315
|
reconcile/gql_definitions/external_resources/fragments/external_resources_module_overrides.py,sha256=T_qWCRtzU8F9frebBXG9TkeQdrKGt3R9YinSngPoFqM,1262
|
316
316
|
reconcile/gql_definitions/fleet_labeler/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
317
|
-
reconcile/gql_definitions/fleet_labeler/fleet_labels.py,sha256=
|
317
|
+
reconcile/gql_definitions/fleet_labeler/fleet_labels.py,sha256=rII_VzEfjGibY1lJXMBMKdCeV7kaNyRXk9-J9-neBoU,4412
|
318
318
|
reconcile/gql_definitions/fragments/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
319
319
|
reconcile/gql_definitions/fragments/aus_organization.py,sha256=uBKbTuBa3CZmTXR5HOcGhRcu2U9kM93KbYmoWTxcpB0,4767
|
320
320
|
reconcile/gql_definitions/fragments/aws_account_common.py,sha256=3-7ZAP6GSff7Z2Syz2VQCLY4IySqBOSVmceaRiVNQpw,2385
|
@@ -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.dev90.dist-info/METADATA,sha256=ITNNwFXdctUPEAooDO8HTV-cc3Z7izzfNugSWuoAFwU,24565
|
790
|
+
qontract_reconcile-0.10.2.dev90.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
|
791
|
+
qontract_reconcile-0.10.2.dev90.dist-info/entry_points.txt,sha256=5i9l54La3vQrDLAdwDKQWC0iG4sV9RRfOb1BpvzOWLc,698
|
792
|
+
qontract_reconcile-0.10.2.dev90.dist-info/RECORD,,
|
@@ -27,7 +27,10 @@ def run(dry_run: bool, thread_pool_size: int) -> None:
|
|
27
27
|
secret_reader = create_secret_reader(use_vault=vault_settings.vault)
|
28
28
|
er_settings = get_settings()
|
29
29
|
|
30
|
-
namespaces = [
|
30
|
+
namespaces = [
|
31
|
+
ns for ns in get_namespaces() if not ns.delete and ns.external_resources
|
32
|
+
]
|
33
|
+
|
31
34
|
er_inventory = ExternalResourcesInventory(namespaces)
|
32
35
|
m_inventory = load_module_inventory(get_modules())
|
33
36
|
|
@@ -104,6 +104,7 @@ class FleetLabelerIntegration(QontractReconcileIntegration[NoParams]):
|
|
104
104
|
{
|
105
105
|
"name": cluster.name,
|
106
106
|
"clusterId": cluster.cluster_id,
|
107
|
+
"subscriptionId": cluster.subscription_id,
|
107
108
|
"serverUrl": cluster.server_url,
|
108
109
|
"subscriptionLabels": cluster.subscription_labels_content,
|
109
110
|
}
|
@@ -128,6 +129,7 @@ class FleetLabelerIntegration(QontractReconcileIntegration[NoParams]):
|
|
128
129
|
|
129
130
|
name: str
|
130
131
|
server_url: str
|
132
|
+
subscription_id: str
|
131
133
|
label_default: FleetLabelDefaultV1
|
132
134
|
|
133
135
|
all_current_cluster_ids = {cluster.cluster_id for cluster in spec.clusters}
|
@@ -145,6 +147,7 @@ class FleetLabelerIntegration(QontractReconcileIntegration[NoParams]):
|
|
145
147
|
clusters[cluster.cluster_id].append(
|
146
148
|
ClusterData(
|
147
149
|
label_default=label_default,
|
150
|
+
subscription_id=cluster.subscription_id,
|
148
151
|
name=cluster.name,
|
149
152
|
server_url=cluster.server_url,
|
150
153
|
)
|
@@ -172,6 +175,7 @@ class FleetLabelerIntegration(QontractReconcileIntegration[NoParams]):
|
|
172
175
|
clusters_to_add = [
|
173
176
|
YamlCluster(
|
174
177
|
cluster_id=cluster_id,
|
178
|
+
subscription_id=cluster_info.subscription_id,
|
175
179
|
name=cluster_info.name,
|
176
180
|
server_url=cluster_info.server_url,
|
177
181
|
subscription_labels_content=self._render_default_labels(
|
reconcile/fleet_labeler/ocm.py
CHANGED
@@ -26,16 +26,20 @@ class Cluster(BaseModel):
|
|
26
26
|
cluster_id: str
|
27
27
|
server_url: str
|
28
28
|
name: str
|
29
|
+
subscription_id: str
|
29
30
|
subscription_labels: dict[str, str]
|
30
31
|
|
31
32
|
@staticmethod
|
32
33
|
def from_cluster_details(cluster: ClusterDetails) -> Cluster:
|
33
|
-
|
34
|
+
console_url = (
|
34
35
|
cluster.ocm_cluster.console.url if cluster.ocm_cluster.console else ""
|
35
36
|
)
|
37
|
+
api_url = cluster.ocm_cluster.api_url or ""
|
38
|
+
server_url = api_url or console_url or ""
|
36
39
|
|
37
40
|
return Cluster(
|
38
41
|
cluster_id=cluster.ocm_cluster.id,
|
42
|
+
subscription_id=cluster.ocm_cluster.subscription.id,
|
39
43
|
server_url=server_url,
|
40
44
|
name=cluster.ocm_cluster.name,
|
41
45
|
subscription_labels={
|
@@ -58,6 +58,7 @@ query FleetLabelSpecs {
|
|
58
58
|
clusters {
|
59
59
|
name
|
60
60
|
serverUrl
|
61
|
+
subscriptionId
|
61
62
|
clusterId
|
62
63
|
subscriptionLabels
|
63
64
|
}
|
@@ -103,6 +104,7 @@ class FleetLabelDefaultV1(ConfiguredBaseModel):
|
|
103
104
|
class FleetClusterV1(ConfiguredBaseModel):
|
104
105
|
name: str = Field(..., alias="name")
|
105
106
|
server_url: str = Field(..., alias="serverUrl")
|
107
|
+
subscription_id: str = Field(..., alias="subscriptionId")
|
106
108
|
cluster_id: str = Field(..., alias="clusterId")
|
107
109
|
subscription_labels: Json = Field(..., alias="subscriptionLabels")
|
108
110
|
|
@@ -34632,6 +34632,22 @@
|
|
34632
34632
|
"isDeprecated": false,
|
34633
34633
|
"deprecationReason": null
|
34634
34634
|
},
|
34635
|
+
{
|
34636
|
+
"name": "subscriptionId",
|
34637
|
+
"description": null,
|
34638
|
+
"args": [],
|
34639
|
+
"type": {
|
34640
|
+
"kind": "NON_NULL",
|
34641
|
+
"name": null,
|
34642
|
+
"ofType": {
|
34643
|
+
"kind": "SCALAR",
|
34644
|
+
"name": "String",
|
34645
|
+
"ofType": null
|
34646
|
+
}
|
34647
|
+
},
|
34648
|
+
"isDeprecated": false,
|
34649
|
+
"deprecationReason": null
|
34650
|
+
},
|
34635
34651
|
{
|
34636
34652
|
"name": "subscriptionLabels",
|
34637
34653
|
"description": null,
|
{qontract_reconcile-0.10.2.dev88.dist-info → qontract_reconcile-0.10.2.dev90.dist-info}/WHEEL
RENAMED
File without changes
|
File without changes
|