@maxim_mazurok/gapi.client.gkehub-v1 0.0.20231103 → 0.0.20231114

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.
Files changed (3) hide show
  1. package/index.d.ts +152 -13
  2. package/package.json +1 -1
  3. package/tests.ts +175 -13
package/index.d.ts CHANGED
@@ -9,7 +9,7 @@
9
9
  // This file was generated by https://github.com/Maxim-Mazurok/google-api-typings-generator. Please do not edit it manually.
10
10
  // In case of any problems please post issue to https://github.com/Maxim-Mazurok/google-api-typings-generator
11
11
  // Generated from: https://gkehub.googleapis.com/$discovery/rest?version=v1
12
- // Revision: 20231103
12
+ // Revision: 20231114
13
13
 
14
14
  /// <reference types="gapi.client" />
15
15
 
@@ -82,6 +82,14 @@ declare namespace gapi.client {
82
82
  workloadIdentityPool?:
83
83
  string;
84
84
  }
85
+ interface BinaryAuthorizationConfig {
86
+ /** Optional. Mode of operation for binauthz policy evaluation. */
87
+ evaluationMode?:
88
+ string;
89
+ /** Optional. Binauthz policies that apply to this cluster. */
90
+ policyBindings?:
91
+ PolicyBinding[];
92
+ }
85
93
  interface Binding {
86
94
  /**
87
95
  * The condition that is associated with this binding. If the condition evaluates to `true`, then this binding applies to the current request. If the condition evaluates to `false`,
@@ -115,10 +123,136 @@ declare namespace gapi.client {
115
123
  // tslint:disable-next-line:no-empty-interface
116
124
  interface CancelOperationRequest {
117
125
  }
126
+ interface ClusterUpgradeFleetSpec {
127
+ /** Allow users to override some properties of each GKE upgrade. */
128
+ gkeUpgradeOverrides?:
129
+ ClusterUpgradeGKEUpgradeOverride[];
130
+ /** Required. Post conditions to evaluate to mark an upgrade COMPLETE. Required. */
131
+ postConditions?:
132
+ ClusterUpgradePostConditions;
133
+ /**
134
+ * This fleet consumes upgrades that have COMPLETE status code in the upstream fleets. See UpgradeStatus.Code for code definitions. The fleet name should be either fleet project number
135
+ * or id. This is defined as repeated for future proof reasons. Initial implementation will enforce at most one upstream fleet.
136
+ */
137
+ upstreamFleets?:
138
+ string[];
139
+ }
140
+ interface ClusterUpgradeFleetState {
141
+ /** This fleets whose upstream_fleets contain the current fleet. The fleet name should be either fleet project number or id. */
142
+ downstreamFleets?:
143
+ string[];
144
+ /** Feature state for GKE clusters. */
145
+ gkeState?:
146
+ ClusterUpgradeGKEUpgradeFeatureState;
147
+ /**
148
+ * A list of memberships ignored by the feature. For example, manually upgraded clusters can be ignored if they are newer than the default versions of its release channel. The
149
+ * membership resource is in the format: `projects/{p}/locations/{l}/membership/{m}`.
150
+ */
151
+ ignored?:
152
+ { [P in string]: ClusterUpgradeIgnoredMembership };
153
+ }
154
+ interface ClusterUpgradeGKEUpgrade {
155
+ /** Name of the upgrade, e.g., "k8s_control_plane". It should be a valid upgrade name. It must not exceet 99 characters. */
156
+ name?:
157
+ string;
158
+ /** Version of the upgrade, e.g., "1.22.1-gke.100". It should be a valid version. It must not exceet 99 characters. */
159
+ version?:
160
+ string;
161
+ }
162
+ interface ClusterUpgradeGKEUpgradeFeatureCondition {
163
+ /** Reason why the feature is in this status. */
164
+ reason?:
165
+ string;
166
+ /** Status of the condition, one of True, False, Unknown. */
167
+ status?:
168
+ string;
169
+ /** Type of the condition, for example, "ready". */
170
+ type?:
171
+ string;
172
+ /** Last timestamp the condition was updated. */
173
+ updateTime?:
174
+ string;
175
+ }
176
+ interface ClusterUpgradeGKEUpgradeFeatureState {
177
+ /** Current conditions of the feature. */
178
+ conditions?:
179
+ ClusterUpgradeGKEUpgradeFeatureCondition[];
180
+ /** Upgrade state. It will eventually replace `state`. */
181
+ upgradeState?:
182
+ ClusterUpgradeGKEUpgradeState[];
183
+ }
184
+ interface ClusterUpgradeGKEUpgradeOverride {
185
+ /** Required. Post conditions to override for the specified upgrade (name + version). Required. */
186
+ postConditions?:
187
+ ClusterUpgradePostConditions;
188
+ /** Required. Which upgrade to override. Required. */
189
+ upgrade?:
190
+ ClusterUpgradeGKEUpgrade;
191
+ }
192
+ interface ClusterUpgradeGKEUpgradeState {
193
+ /** Number of GKE clusters in each status code. */
194
+ stats?:
195
+ { [P in string]: string };
196
+ /** Status of the upgrade. */
197
+ status?:
198
+ ClusterUpgradeUpgradeStatus;
199
+ /** Which upgrade to track the state. */
200
+ upgrade?:
201
+ ClusterUpgradeGKEUpgrade;
202
+ }
203
+ interface ClusterUpgradeIgnoredMembership {
204
+ /** Time when the membership was first set to ignored. */
205
+ ignoredTime?:
206
+ string;
207
+ /** Reason why the membership is ignored. */
208
+ reason?:
209
+ string;
210
+ }
211
+ interface ClusterUpgradeMembershipGKEUpgradeState {
212
+ /** Status of the upgrade. */
213
+ status?:
214
+ ClusterUpgradeUpgradeStatus;
215
+ /** Which upgrade to track the state. */
216
+ upgrade?:
217
+ ClusterUpgradeGKEUpgrade;
218
+ }
219
+ interface ClusterUpgradeMembershipState {
220
+ /** Project number or id of the fleet. It is set only for Memberships that are part of fleet-based Rollout Sequencing. */
221
+ fleet?:
222
+ string;
223
+ /** Whether this membership is ignored by the feature. For example, manually upgraded clusters can be ignored if they are newer than the default versions of its release channel. */
224
+ ignored?:
225
+ ClusterUpgradeIgnoredMembership;
226
+ /** Fully qualified scope names that this clusters is bound to which also have rollout sequencing enabled. */
227
+ scopes?:
228
+ string[];
229
+ /** Actual upgrade state against desired. */
230
+ upgrades?:
231
+ ClusterUpgradeMembershipGKEUpgradeState[];
232
+ }
233
+ interface ClusterUpgradePostConditions {
234
+ /** Required. Amount of time to "soak" after a rollout has been finished before marking it COMPLETE. Cannot exceed 30 days. Required. */
235
+ soaking?:
236
+ string;
237
+ }
238
+ interface ClusterUpgradeUpgradeStatus {
239
+ /** Status code of the upgrade. */
240
+ code?:
241
+ string;
242
+ /** Reason for this status. */
243
+ reason?:
244
+ string;
245
+ /** Last timestamp the status was updated. */
246
+ updateTime?:
247
+ string;
248
+ }
118
249
  interface CommonFeatureSpec {
119
250
  /** Appdevexperience specific spec. */
120
251
  appdevexperience?:
121
252
  any;
253
+ /** ClusterUpgrade (fleet-based) feature spec. */
254
+ clusterupgrade?:
255
+ ClusterUpgradeFleetSpec;
122
256
  /** FleetObservability feature spec. */
123
257
  fleetobservability?:
124
258
  FleetObservabilityFeatureSpec;
@@ -130,6 +264,9 @@ declare namespace gapi.client {
130
264
  /** Appdevexperience specific state. */
131
265
  appdevexperience?:
132
266
  AppDevExperienceFeatureState;
267
+ /** ClusterUpgrade fleet-level state. */
268
+ clusterupgrade?:
269
+ ClusterUpgradeFleetState;
133
270
  /** FleetObservability feature state. */
134
271
  fleetobservability?:
135
272
  FleetObservabilityFeatureState;
@@ -180,12 +317,6 @@ declare namespace gapi.client {
180
317
  /** Specifies whether the Config Sync Repo is in "hierarchical" or "unstructured" mode. */
181
318
  sourceFormat?:
182
319
  string;
183
- /**
184
- * Set to true to stop syncing configs for a single cluster when automatic Feature management is enabled. Default to false. The field will be ignored when automatic Feature management
185
- * is disabled.
186
- */
187
- stopSyncing?:
188
- boolean;
189
320
  }
190
321
  interface ConfigManagementConfigSyncDeploymentState {
191
322
  /** Deployment state of admission-webhook */
@@ -368,9 +499,6 @@ declare namespace gapi.client {
368
499
  /** Hierarchy Controller configuration for the cluster. */
369
500
  hierarchyController?:
370
501
  ConfigManagementHierarchyControllerConfig;
371
- /** Enables automatic Feature management. */
372
- management?:
373
- string;
374
502
  /** Policy Controller configuration for the cluster. */
375
503
  policyController?:
376
504
  ConfigManagementPolicyController;
@@ -527,6 +655,9 @@ declare namespace gapi.client {
527
655
  TypeMeta;
528
656
  }
529
657
  interface DefaultClusterConfig {
658
+ /** Optional. Enable/Disable binary authorization features for the cluster. */
659
+ binaryAuthorizationConfig?:
660
+ BinaryAuthorizationConfig;
530
661
  /** Enable/Disable Security Posture features for the cluster. */
531
662
  securityPostureConfig?:
532
663
  SecurityPostureConfig;
@@ -1157,6 +1288,9 @@ declare namespace gapi.client {
1157
1288
  /** Appdevexperience specific state. */
1158
1289
  appdevexperience?:
1159
1290
  AppDevExperienceFeatureState;
1291
+ /** ClusterUpgrade state. */
1292
+ clusterupgrade?:
1293
+ ClusterUpgradeMembershipState;
1160
1294
  /** Config Management-specific state. */
1161
1295
  configmanagement?:
1162
1296
  ConfigManagementMembershipState;
@@ -1370,6 +1504,11 @@ declare namespace gapi.client {
1370
1504
  version?:
1371
1505
  number;
1372
1506
  }
1507
+ interface PolicyBinding {
1508
+ /** The relative resource name of the binauthz platform policy to audit. GKE platform policies have the following format: `projects/{project_number}/platforms/gke/policies/{policy_id}`. */
1509
+ name?:
1510
+ string;
1511
+ }
1373
1512
  interface PolicyControllerBundleInstallSpec {
1374
1513
  /** The set of namespaces to be exempted from the bundle. */
1375
1514
  exemptedNamespaces?:
@@ -1530,7 +1669,7 @@ declare namespace gapi.client {
1530
1669
  labels?:
1531
1670
  { [P in string]: string };
1532
1671
  /**
1533
- * The resource name for the rbacrolebinding `projects/{project}/locations/{location}/namespaces/{namespace}/rbacrolebindings/{rbacrolebinding}` or
1672
+ * The resource name for the rbacrolebinding `projects/{project}/locations/{location}/scopes/{scope}/rbacrolebindings/{rbacrolebinding}` or
1534
1673
  * `projects/{project}/locations/{location}/memberships/{membership}/rbacrolebindings/{rbacrolebinding}`
1535
1674
  */
1536
1675
  name?:
@@ -4245,7 +4384,7 @@ declare namespace gapi.client {
4245
4384
  key?:
4246
4385
  string;
4247
4386
  /**
4248
- * The resource name for the rbacrolebinding `projects/{project}/locations/{location}/namespaces/{namespace}/rbacrolebindings/{rbacrolebinding}` or
4387
+ * The resource name for the rbacrolebinding `projects/{project}/locations/{location}/scopes/{scope}/rbacrolebindings/{rbacrolebinding}` or
4249
4388
  * `projects/{project}/locations/{location}/memberships/{membership}/rbacrolebindings/{rbacrolebinding}`
4250
4389
  */
4251
4390
  name:
@@ -4292,7 +4431,7 @@ declare namespace gapi.client {
4292
4431
  key?:
4293
4432
  string;
4294
4433
  /**
4295
- * The resource name for the rbacrolebinding `projects/{project}/locations/{location}/namespaces/{namespace}/rbacrolebindings/{rbacrolebinding}` or
4434
+ * The resource name for the rbacrolebinding `projects/{project}/locations/{location}/scopes/{scope}/rbacrolebindings/{rbacrolebinding}` or
4296
4435
  * `projects/{project}/locations/{location}/memberships/{membership}/rbacrolebindings/{rbacrolebinding}`
4297
4436
  */
4298
4437
  name:
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@maxim_mazurok/gapi.client.gkehub-v1",
3
- "version": "0.0.20231103",
3
+ "version": "0.0.20231114",
4
4
  "description": "TypeScript typings for GKE Hub API v1",
5
5
  "license": "MIT",
6
6
  "author": {
package/tests.ts CHANGED
@@ -3,7 +3,7 @@
3
3
  // This file was generated by https://github.com/Maxim-Mazurok/google-api-typings-generator. Please do not edit it manually.
4
4
  // In case of any problems please post issue to https://github.com/Maxim-Mazurok/google-api-typings-generator
5
5
 
6
- // Revision: 20231103
6
+ // Revision: 20231114
7
7
 
8
8
  gapi.load('client', async () => {
9
9
  /** now we can use gapi.client */
@@ -80,14 +80,12 @@ gapi.load('client', async () => {
80
80
  },
81
81
  preventDrift: true,
82
82
  sourceFormat: "Test string",
83
- stopSyncing: true,
84
83
  },
85
84
  hierarchyController: {
86
85
  enabled: true,
87
86
  enableHierarchicalResourceQuota: true,
88
87
  enablePodTreeLabels: true,
89
88
  },
90
- management: "Test string",
91
89
  policyController: {
92
90
  auditIntervalSeconds: "Test string",
93
91
  enabled: true,
@@ -232,14 +230,12 @@ gapi.load('client', async () => {
232
230
  },
233
231
  preventDrift: true,
234
232
  sourceFormat: "Test string",
235
- stopSyncing: true,
236
233
  },
237
234
  hierarchyController: {
238
235
  enabled: true,
239
236
  enableHierarchicalResourceQuota: true,
240
237
  enablePodTreeLabels: true,
241
238
  },
242
- management: "Test string",
243
239
  policyController: {
244
240
  auditIntervalSeconds: "Test string",
245
241
  enabled: true,
@@ -368,6 +364,29 @@ gapi.load('client', async () => {
368
364
  description: "Test string",
369
365
  },
370
366
  },
367
+ clusterupgrade: {
368
+ fleet: "Test string",
369
+ ignored: {
370
+ ignoredTime: "Test string",
371
+ reason: "Test string",
372
+ },
373
+ scopes: [
374
+ "Test string"
375
+ ],
376
+ upgrades: [
377
+ {
378
+ status: {
379
+ code: "Test string",
380
+ reason: "Test string",
381
+ updateTime: "Test string",
382
+ },
383
+ upgrade: {
384
+ name: "Test string",
385
+ version: "Test string",
386
+ },
387
+ }
388
+ ],
389
+ },
371
390
  configmanagement: {
372
391
  clusterName: "Test string",
373
392
  configSyncState: {
@@ -456,14 +475,12 @@ gapi.load('client', async () => {
456
475
  },
457
476
  preventDrift: true,
458
477
  sourceFormat: "Test string",
459
- stopSyncing: true,
460
478
  },
461
479
  hierarchyController: {
462
480
  enabled: true,
463
481
  enableHierarchicalResourceQuota: true,
464
482
  enablePodTreeLabels: true,
465
483
  },
466
- management: "Test string",
467
484
  policyController: {
468
485
  auditIntervalSeconds: "Test string",
469
486
  enabled: true,
@@ -620,6 +637,25 @@ gapi.load('client', async () => {
620
637
  spec: {
621
638
  appdevexperience: {
622
639
  },
640
+ clusterupgrade: {
641
+ gkeUpgradeOverrides: [
642
+ {
643
+ postConditions: {
644
+ soaking: "Test string",
645
+ },
646
+ upgrade: {
647
+ name: "Test string",
648
+ version: "Test string",
649
+ },
650
+ }
651
+ ],
652
+ postConditions: {
653
+ soaking: "Test string",
654
+ },
655
+ upstreamFleets: [
656
+ "Test string"
657
+ ],
658
+ },
623
659
  fleetobservability: {
624
660
  loggingConfig: {
625
661
  defaultConfig: {
@@ -641,6 +677,43 @@ gapi.load('client', async () => {
641
677
  description: "Test string",
642
678
  },
643
679
  },
680
+ clusterupgrade: {
681
+ downstreamFleets: [
682
+ "Test string"
683
+ ],
684
+ gkeState: {
685
+ conditions: [
686
+ {
687
+ reason: "Test string",
688
+ status: "Test string",
689
+ type: "Test string",
690
+ updateTime: "Test string",
691
+ }
692
+ ],
693
+ upgradeState: [
694
+ {
695
+ stats: {
696
+ A: "Test string"
697
+ },
698
+ status: {
699
+ code: "Test string",
700
+ reason: "Test string",
701
+ updateTime: "Test string",
702
+ },
703
+ upgrade: {
704
+ name: "Test string",
705
+ version: "Test string",
706
+ },
707
+ }
708
+ ],
709
+ },
710
+ ignored: {
711
+ A: {
712
+ ignoredTime: "Test string",
713
+ reason: "Test string",
714
+ }
715
+ },
716
+ },
644
717
  fleetobservability: {
645
718
  logging: {
646
719
  defaultLog: {
@@ -739,14 +812,12 @@ gapi.load('client', async () => {
739
812
  },
740
813
  preventDrift: true,
741
814
  sourceFormat: "Test string",
742
- stopSyncing: true,
743
815
  },
744
816
  hierarchyController: {
745
817
  enabled: true,
746
818
  enableHierarchicalResourceQuota: true,
747
819
  enablePodTreeLabels: true,
748
820
  },
749
- management: "Test string",
750
821
  policyController: {
751
822
  auditIntervalSeconds: "Test string",
752
823
  enabled: true,
@@ -891,14 +962,12 @@ gapi.load('client', async () => {
891
962
  },
892
963
  preventDrift: true,
893
964
  sourceFormat: "Test string",
894
- stopSyncing: true,
895
965
  },
896
966
  hierarchyController: {
897
967
  enabled: true,
898
968
  enableHierarchicalResourceQuota: true,
899
969
  enablePodTreeLabels: true,
900
970
  },
901
- management: "Test string",
902
971
  policyController: {
903
972
  auditIntervalSeconds: "Test string",
904
973
  enabled: true,
@@ -1027,6 +1096,29 @@ gapi.load('client', async () => {
1027
1096
  description: "Test string",
1028
1097
  },
1029
1098
  },
1099
+ clusterupgrade: {
1100
+ fleet: "Test string",
1101
+ ignored: {
1102
+ ignoredTime: "Test string",
1103
+ reason: "Test string",
1104
+ },
1105
+ scopes: [
1106
+ "Test string"
1107
+ ],
1108
+ upgrades: [
1109
+ {
1110
+ status: {
1111
+ code: "Test string",
1112
+ reason: "Test string",
1113
+ updateTime: "Test string",
1114
+ },
1115
+ upgrade: {
1116
+ name: "Test string",
1117
+ version: "Test string",
1118
+ },
1119
+ }
1120
+ ],
1121
+ },
1030
1122
  configmanagement: {
1031
1123
  clusterName: "Test string",
1032
1124
  configSyncState: {
@@ -1115,14 +1207,12 @@ gapi.load('client', async () => {
1115
1207
  },
1116
1208
  preventDrift: true,
1117
1209
  sourceFormat: "Test string",
1118
- stopSyncing: true,
1119
1210
  },
1120
1211
  hierarchyController: {
1121
1212
  enabled: true,
1122
1213
  enableHierarchicalResourceQuota: true,
1123
1214
  enablePodTreeLabels: true,
1124
1215
  },
1125
- management: "Test string",
1126
1216
  policyController: {
1127
1217
  auditIntervalSeconds: "Test string",
1128
1218
  enabled: true,
@@ -1279,6 +1369,25 @@ gapi.load('client', async () => {
1279
1369
  spec: {
1280
1370
  appdevexperience: {
1281
1371
  },
1372
+ clusterupgrade: {
1373
+ gkeUpgradeOverrides: [
1374
+ {
1375
+ postConditions: {
1376
+ soaking: "Test string",
1377
+ },
1378
+ upgrade: {
1379
+ name: "Test string",
1380
+ version: "Test string",
1381
+ },
1382
+ }
1383
+ ],
1384
+ postConditions: {
1385
+ soaking: "Test string",
1386
+ },
1387
+ upstreamFleets: [
1388
+ "Test string"
1389
+ ],
1390
+ },
1282
1391
  fleetobservability: {
1283
1392
  loggingConfig: {
1284
1393
  defaultConfig: {
@@ -1300,6 +1409,43 @@ gapi.load('client', async () => {
1300
1409
  description: "Test string",
1301
1410
  },
1302
1411
  },
1412
+ clusterupgrade: {
1413
+ downstreamFleets: [
1414
+ "Test string"
1415
+ ],
1416
+ gkeState: {
1417
+ conditions: [
1418
+ {
1419
+ reason: "Test string",
1420
+ status: "Test string",
1421
+ type: "Test string",
1422
+ updateTime: "Test string",
1423
+ }
1424
+ ],
1425
+ upgradeState: [
1426
+ {
1427
+ stats: {
1428
+ A: "Test string"
1429
+ },
1430
+ status: {
1431
+ code: "Test string",
1432
+ reason: "Test string",
1433
+ updateTime: "Test string",
1434
+ },
1435
+ upgrade: {
1436
+ name: "Test string",
1437
+ version: "Test string",
1438
+ },
1439
+ }
1440
+ ],
1441
+ },
1442
+ ignored: {
1443
+ A: {
1444
+ ignoredTime: "Test string",
1445
+ reason: "Test string",
1446
+ }
1447
+ },
1448
+ },
1303
1449
  fleetobservability: {
1304
1450
  logging: {
1305
1451
  defaultLog: {
@@ -1395,6 +1541,14 @@ gapi.load('client', async () => {
1395
1541
  }, {
1396
1542
  createTime: "Test string",
1397
1543
  defaultClusterConfig: {
1544
+ binaryAuthorizationConfig: {
1545
+ evaluationMode: "Test string",
1546
+ policyBindings: [
1547
+ {
1548
+ name: "Test string",
1549
+ }
1550
+ ],
1551
+ },
1398
1552
  securityPostureConfig: {
1399
1553
  mode: "Test string",
1400
1554
  vulnerabilityMode: "Test string",
@@ -1433,6 +1587,14 @@ gapi.load('client', async () => {
1433
1587
  }, {
1434
1588
  createTime: "Test string",
1435
1589
  defaultClusterConfig: {
1590
+ binaryAuthorizationConfig: {
1591
+ evaluationMode: "Test string",
1592
+ policyBindings: [
1593
+ {
1594
+ name: "Test string",
1595
+ }
1596
+ ],
1597
+ },
1436
1598
  securityPostureConfig: {
1437
1599
  mode: "Test string",
1438
1600
  vulnerabilityMode: "Test string",