@daocloud-proto/kangaroo 0.5.0-48 → 0.5.0-481

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.
@@ -0,0 +1,9 @@
1
+ /* eslint-disable */
2
+ // @ts-nocheck
3
+ /*
4
+ * This file is a generated Typescript file for GRPC Gateway, DO NOT MODIFY
5
+ */
6
+ export type Any = {
7
+ typeUrl?: string
8
+ value?: Uint8Array
9
+ }
@@ -26,6 +26,8 @@ export enum PermissionsType {
26
26
  DeleteManagedHarbor = "DeleteManagedHarbor",
27
27
  UpdateManagedHarbor = "UpdateManagedHarbor",
28
28
  GetManagedHarbor = "GetManagedHarbor",
29
+ CreateImage = "CreateImage",
30
+ UpdateImage = "UpdateImage",
29
31
  }
30
32
 
31
33
  export type GlobalPermissionsResponse = {
@@ -8,6 +8,12 @@ import * as KangarooIoApiTypesObjectmeta from "../../types/objectmeta.pb"
8
8
  import * as KangarooIoApiTypesPage from "../../types/page.pb"
9
9
  import * as KangarooIoApiHarborV1alpha1Redis from "./redis.pb"
10
10
 
11
+ export enum TLSType {
12
+ TLS_TYPE_UNSPECIFIED = "TLS_TYPE_UNSPECIFIED",
13
+ SELF_SIGNED = "SELF_SIGNED",
14
+ CUSTOM = "CUSTOM",
15
+ }
16
+
11
17
  export enum VerifyHarborOperatorResponseHarborOperatorStatus {
12
18
  STATUS_UNSPECIFIED = "STATUS_UNSPECIFIED",
13
19
  STATUS_HARBOR_OPERATOR_IS_NOT_INSTALLED = "STATUS_HARBOR_OPERATOR_IS_NOT_INSTALLED",
@@ -33,6 +39,7 @@ export enum OCIStorageSpecStorageType {
33
39
  STORAGE_UNSPECIFIED = "STORAGE_UNSPECIFIED",
34
40
  S3 = "S3",
35
41
  STORAGE_CLASS = "STORAGE_CLASS",
42
+ MCAMEL_MINIO = "MCAMEL_MINIO",
36
43
  }
37
44
 
38
45
  export enum ExposeSpecExposeType {
@@ -49,6 +56,16 @@ export enum HarborClusterStatusClusterStatus {
49
56
  UNHEALTHY = "UNHEALTHY",
50
57
  }
51
58
 
59
+ export enum HarborClusterStatusTargetClusterStatus {
60
+ TARGET_CLUSTER_STATUS_UNSPECIFIED = "TARGET_CLUSTER_STATUS_UNSPECIFIED",
61
+ TARGET_CLUSTER_STATUS_RUNNING = "TARGET_CLUSTER_STATUS_RUNNING",
62
+ TARGET_CLUSTER_STATUS_FAILED = "TARGET_CLUSTER_STATUS_FAILED",
63
+ TARGET_CLUSTER_STATUS_UNKNOWN = "TARGET_CLUSTER_STATUS_UNKNOWN",
64
+ TARGET_CLUSTER_STATUS_DELETING = "TARGET_CLUSTER_STATUS_DELETING",
65
+ TARGET_CLUSTER_STATUS_CREATING = "TARGET_CLUSTER_STATUS_CREATING",
66
+ TARGET_CLUSTER_STATUS_UPDATING = "TARGET_CLUSTER_STATUS_UPDATING",
67
+ }
68
+
52
69
  export type GetHarborParamsRequest = {
53
70
  cluster?: string
54
71
  }
@@ -62,6 +79,7 @@ export type GetHarborParamsResponse = {
62
79
  export type ResourceNameList = {
63
80
  name?: string
64
81
  default?: boolean
82
+ hwameistorReplicas?: number
65
83
  }
66
84
 
67
85
  export type VerifyHarborOperatorRequest = {
@@ -82,6 +100,13 @@ export type VerifyNamespaceQuotaRequest = {
82
100
 
83
101
  export type VerifyNamespaceQuotaResponse = {
84
102
  status?: boolean
103
+ cpu?: QuotaResponse
104
+ memory?: QuotaResponse
105
+ }
106
+
107
+ export type QuotaResponse = {
108
+ request?: string
109
+ allocatable?: string
85
110
  }
86
111
 
87
112
  export type HarborCluster = {
@@ -101,6 +126,7 @@ export type HarborClusterSpec = {
101
126
  userSyncToHarbor?: boolean
102
127
  adminPassword?: string
103
128
  enableTrivy?: boolean
129
+ enableMetrics?: boolean
104
130
  }
105
131
 
106
132
  export type Resources = {
@@ -119,6 +145,10 @@ export type DBBuiltInModeSpec = {
119
145
  }
120
146
 
121
147
  export type DBMcamelModeSpec = {
148
+ cluster?: string
149
+ namespace?: string
150
+ name?: string
151
+ workspace?: string
122
152
  }
123
153
 
124
154
  export type DBExternalModeSpec = {
@@ -154,9 +184,18 @@ export type CacheExternalModeSpec = {
154
184
  export type OCIStorageSpec = {
155
185
  type?: OCIStorageSpecStorageType
156
186
  s3Spec?: S3Spec
187
+ mcamelMinioSpec?: McamelMinioSpec
157
188
  scSpec?: StorageClassSpec
158
189
  }
159
190
 
191
+ export type McamelMinioSpec = {
192
+ name?: string
193
+ namespace?: string
194
+ cluster?: string
195
+ workspace?: string
196
+ bucket?: string
197
+ }
198
+
160
199
  export type StorageClassSpec = {
161
200
  name?: string
162
201
  resource?: Resources
@@ -179,6 +218,12 @@ export type ExposeSpec = {
179
218
  nodePortSpec?: ExposeNodePortSpec
180
219
  externalUrl?: string
181
220
  exposeHttps?: boolean
221
+ httpsSpec?: HttpsSpec
222
+ }
223
+
224
+ export type HttpsSpec = {
225
+ namespace?: string
226
+ name?: string
182
227
  }
183
228
 
184
229
  export type ExposeIngressSpec = {
@@ -195,6 +240,7 @@ export type ExposeNodePortSpec = {
195
240
 
196
241
  export type HarborClusterStatus = {
197
242
  status?: HarborClusterStatusClusterStatus
243
+ targetClusterStatus?: HarborClusterStatusTargetClusterStatus
198
244
  }
199
245
 
200
246
  export type CreateHarborClusterRequest = {
@@ -210,6 +256,7 @@ export type UpdateHarborClusterRequest = {
210
256
  namespace?: string
211
257
  name?: string
212
258
  spec?: HarborClusterSpec
259
+ metadata?: KangarooIoApiTypesObjectmeta.ObjectMeta
213
260
  }
214
261
 
215
262
  export type GetHarborClusterRequest = {
@@ -244,4 +291,40 @@ export type VerifyNodePortRequest = {
244
291
 
245
292
  export type VerifyNodePortResponse = {
246
293
  status?: boolean
294
+ }
295
+
296
+ export type ListTLSRequest = {
297
+ cluster?: string
298
+ namespace?: string
299
+ }
300
+
301
+ export type ListTLSResponse = {
302
+ items?: ListTLSResponseItem[]
303
+ }
304
+
305
+ export type ListTLSResponseItem = {
306
+ namespace?: string
307
+ name?: string
308
+ type?: TLSType
309
+ }
310
+
311
+ export type CheckDependServiceRequest = {
312
+ name?: string
313
+ namespace?: string
314
+ cluster?: string
315
+ database?: DatabaseSpec
316
+ cache?: CacheSpec
317
+ storage?: OCIStorageSpec
318
+ }
319
+
320
+ export type CheckResponse = {
321
+ completed?: boolean
322
+ isPass?: boolean
323
+ message?: string
324
+ }
325
+
326
+ export type CheckDependServiceResponse = {
327
+ db?: CheckResponse
328
+ cache?: CheckResponse
329
+ storage?: CheckResponse
247
330
  }
@@ -0,0 +1,34 @@
1
+ /* eslint-disable */
2
+ // @ts-nocheck
3
+ /*
4
+ * This file is a generated Typescript file for GRPC Gateway, DO NOT MODIFY
5
+ */
6
+
7
+ import * as KangarooIoApiTypesPage from "../../types/page.pb"
8
+
9
+ export enum MinioStatus {
10
+ MINIO_STATUS_UNSPECIFIED = "MINIO_STATUS_UNSPECIFIED",
11
+ MINIO_STATUS_FAILED = "MINIO_STATUS_FAILED",
12
+ MINIO_STATUS_RUNNING = "MINIO_STATUS_RUNNING",
13
+ MINIO_STATUS_CREATING = "MINIO_STATUS_CREATING",
14
+ }
15
+
16
+ export type MinioSummary = {
17
+ name?: string
18
+ cluster?: string
19
+ namespace?: string
20
+ buckets?: string[]
21
+ address?: string[]
22
+ status?: MinioStatus
23
+ }
24
+
25
+ export type ListMinioRequest = {
26
+ workspace?: string
27
+ page?: number
28
+ pageSize?: number
29
+ }
30
+
31
+ export type ListMinioResponse = {
32
+ items?: MinioSummary[]
33
+ pagination?: KangarooIoApiTypesPage.Page
34
+ }
@@ -0,0 +1,33 @@
1
+ /* eslint-disable */
2
+ // @ts-nocheck
3
+ /*
4
+ * This file is a generated Typescript file for GRPC Gateway, DO NOT MODIFY
5
+ */
6
+
7
+ import * as KangarooIoApiTypesPage from "../../types/page.pb"
8
+
9
+ export enum PostgresqlStatus {
10
+ PG_STATUS_UNSPECIFIED = "PG_STATUS_UNSPECIFIED",
11
+ PG_STATUS_RUNNING = "PG_STATUS_RUNNING",
12
+ PG_STATUS_CREATING = "PG_STATUS_CREATING",
13
+ PG_STATUS_FAILED = "PG_STATUS_FAILED",
14
+ }
15
+
16
+ export type PostgresqlSummary = {
17
+ name?: string
18
+ cluster?: string
19
+ namespace?: string
20
+ status?: PostgresqlStatus
21
+ numberOfInstances?: number
22
+ }
23
+
24
+ export type ListPostgresqlRequest = {
25
+ workspace?: string
26
+ page?: number
27
+ pageSize?: number
28
+ }
29
+
30
+ export type ListPostgresqlResponse = {
31
+ items?: PostgresqlSummary[]
32
+ pagination?: KangarooIoApiTypesPage.Page
33
+ }
@@ -6,7 +6,10 @@
6
6
 
7
7
  import * as fm from "../../../../fetch.pb"
8
8
  import * as GoogleProtobufEmpty from "../../../../google/protobuf/empty.pb"
9
+ import * as KangarooIoApiTypesObjectmeta from "../../types/objectmeta.pb"
9
10
  import * as KangarooIoApiHarborV1alpha1Harbor from "./harbor.pb"
11
+ import * as KangarooIoApiHarborV1alpha1Minio from "./minio.pb"
12
+ import * as KangarooIoApiHarborV1alpha1Postgresql from "./postgresql.pb"
10
13
  import * as KangarooIoApiHarborV1alpha1Redis from "./redis.pb"
11
14
  export class Harbor {
12
15
  static GetHarborParams(req: KangarooIoApiHarborV1alpha1Harbor.GetHarborParamsRequest, initReq?: fm.InitReq): Promise<KangarooIoApiHarborV1alpha1Harbor.GetHarborParamsResponse> {
@@ -39,4 +42,22 @@ export class Harbor {
39
42
  static ListRedis(req: KangarooIoApiHarborV1alpha1Redis.ListRedisRequest, initReq?: fm.InitReq): Promise<KangarooIoApiHarborV1alpha1Redis.ListRedisResponse> {
40
43
  return fm.fetchReq<KangarooIoApiHarborV1alpha1Redis.ListRedisRequest, KangarooIoApiHarborV1alpha1Redis.ListRedisResponse>(`/apis/kangaroo.io/v1alpha1/workspace/${req["workspace"]}/redis?${fm.renderURLSearchParams(req, ["workspace"])}`, {...initReq, method: "GET"})
41
44
  }
45
+ static ListPostgresql(req: KangarooIoApiHarborV1alpha1Postgresql.ListPostgresqlRequest, initReq?: fm.InitReq): Promise<KangarooIoApiHarborV1alpha1Postgresql.ListPostgresqlResponse> {
46
+ return fm.fetchReq<KangarooIoApiHarborV1alpha1Postgresql.ListPostgresqlRequest, KangarooIoApiHarborV1alpha1Postgresql.ListPostgresqlResponse>(`/apis/kangaroo.io/v1alpha1/workspace/${req["workspace"]}/postgresql?${fm.renderURLSearchParams(req, ["workspace"])}`, {...initReq, method: "GET"})
47
+ }
48
+ static ListMinio(req: KangarooIoApiHarborV1alpha1Minio.ListMinioRequest, initReq?: fm.InitReq): Promise<KangarooIoApiHarborV1alpha1Minio.ListMinioResponse> {
49
+ return fm.fetchReq<KangarooIoApiHarborV1alpha1Minio.ListMinioRequest, KangarooIoApiHarborV1alpha1Minio.ListMinioResponse>(`/apis/kangaroo.io/v1alpha1/workspace/${req["workspace"]}/minio?${fm.renderURLSearchParams(req, ["workspace"])}`, {...initReq, method: "GET"})
50
+ }
51
+ static ListTLSSecret(req: KangarooIoApiHarborV1alpha1Harbor.ListTLSRequest, initReq?: fm.InitReq): Promise<KangarooIoApiHarborV1alpha1Harbor.ListTLSResponse> {
52
+ return fm.fetchReq<KangarooIoApiHarborV1alpha1Harbor.ListTLSRequest, KangarooIoApiHarborV1alpha1Harbor.ListTLSResponse>(`/apis/kangaroo.io/v1alpha1/cluster/${req["cluster"]}/namespace/${req["namespace"]}/tls?${fm.renderURLSearchParams(req, ["cluster", "namespace"])}`, {...initReq, method: "GET"})
53
+ }
54
+ static CreateVerifyDependService(req: KangarooIoApiHarborV1alpha1Harbor.CheckDependServiceRequest, initReq?: fm.InitReq): Promise<GoogleProtobufEmpty.Empty> {
55
+ return fm.fetchReq<KangarooIoApiHarborV1alpha1Harbor.CheckDependServiceRequest, GoogleProtobufEmpty.Empty>(`/apis/kangaroo.io/v1alpha1/cluster/${req["cluster"]}/namespace/${req["namespace"]}/harbors/${req["name"]}/verify`, {...initReq, method: "POST", body: JSON.stringify(req)})
56
+ }
57
+ static GetVerifyDependService(req: KangarooIoApiTypesObjectmeta.ObjectMeta, initReq?: fm.InitReq): Promise<KangarooIoApiHarborV1alpha1Harbor.CheckDependServiceResponse> {
58
+ return fm.fetchReq<KangarooIoApiTypesObjectmeta.ObjectMeta, KangarooIoApiHarborV1alpha1Harbor.CheckDependServiceResponse>(`/apis/kangaroo.io/v1alpha1/cluster/${req["cluster"]}/namespace/${req["namespace"]}/harbors/${req["name"]}/verify?${fm.renderURLSearchParams(req, ["cluster", "namespace", "name"])}`, {...initReq, method: "GET"})
59
+ }
60
+ static SyncHarborStatus(req: KangarooIoApiTypesObjectmeta.ObjectMeta, initReq?: fm.InitReq): Promise<GoogleProtobufEmpty.Empty> {
61
+ return fm.fetchReq<KangarooIoApiTypesObjectmeta.ObjectMeta, GoogleProtobufEmpty.Empty>(`/apis/kangaroo.io/v1alpha1/cluster/${req["cluster"]}/namespace/${req["namespace"]}/harbors/${req["name"]}/sync?${fm.renderURLSearchParams(req, ["cluster", "namespace", "name"])}`, {...initReq, method: "GET"})
62
+ }
42
63
  }
@@ -4,8 +4,15 @@
4
4
  * This file is a generated Typescript file for GRPC Gateway, DO NOT MODIFY
5
5
  */
6
6
 
7
+ import * as KangarooIoApiRegistryV1alpha1Registry from "../../registry/v1alpha1/registry.pb"
7
8
  import * as KangarooIoApiTypesPage from "../../types/page.pb"
8
9
 
10
+ export enum RegistrySecretHealth {
11
+ health_unspecified = "health_unspecified",
12
+ healthy = "healthy",
13
+ unhealthy = "unhealthy",
14
+ }
15
+
9
16
  export enum ListRepositoriesRequestSortBy {
10
17
  unspecified = "unspecified",
11
18
  pull_count = "pull_count",
@@ -51,6 +58,9 @@ export type RegistrySecret = {
51
58
  alias?: string
52
59
  host?: string
53
60
  name?: string
61
+ health?: RegistrySecretHealth
62
+ registryType?: KangarooIoApiRegistryV1alpha1Registry.RegistryType
63
+ scope?: string
54
64
  }
55
65
 
56
66
  export type ListRegistryResponse = {
@@ -63,6 +73,13 @@ export type ListProjectRequest = {
63
73
  registry?: string
64
74
  page?: number
65
75
  pageSize?: number
76
+ fuzzyName?: string
77
+ }
78
+
79
+ export type GetProjectRequest = {
80
+ workspace?: string
81
+ registry?: string
82
+ project?: string
66
83
  }
67
84
 
68
85
  export type ListProjectResponse = {
@@ -75,6 +92,8 @@ export type ListProjectResponseItem = {
75
92
  public?: boolean
76
93
  total?: string
77
94
  createTime?: string
95
+ retentionId?: string
96
+ projectId?: string
78
97
  }
79
98
 
80
99
  export type Repository = {
@@ -83,6 +102,7 @@ export type Repository = {
83
102
  tagCount?: string
84
103
  pullCount?: string
85
104
  updateTime?: string
105
+ description?: string
86
106
  }
87
107
 
88
108
  export type ListRepositoriesRequest = {
@@ -230,6 +250,7 @@ export type ListRegistryProjectRequest = {
230
250
  registry?: string
231
251
  page?: number
232
252
  pageSize?: number
253
+ onlyBind?: boolean
233
254
  }
234
255
 
235
256
  export type RegistryProjectResponse = {
@@ -305,6 +326,8 @@ export type APIListProjectRequest = {
305
326
  public?: boolean
306
327
  page?: number
307
328
  pageSize?: number
329
+ onlyBind?: boolean
330
+ all?: boolean
308
331
  }
309
332
 
310
333
  export type APIListProjectResponse = {
@@ -400,7 +423,6 @@ export type GetScannerOfProjectResponse = {
400
423
  export type GetPushCommandRequest = {
401
424
  workspace?: string
402
425
  registry?: string
403
- project?: string
404
426
  expired?: string
405
427
  }
406
428
 
@@ -408,4 +430,23 @@ export type GetPushCommandResponse = {
408
430
  cmd?: string
409
431
  expired?: string
410
432
  expiredAt?: string
433
+ }
434
+
435
+ export type UpdateRepositoryDescriptionRequest = {
436
+ workspace?: string
437
+ registry?: string
438
+ project?: string
439
+ repository?: string
440
+ description?: string
441
+ }
442
+
443
+ export type UpdateRepositoryDescriptionResponse = {
444
+ description?: string
445
+ }
446
+
447
+ export type GetRepositoryRequest = {
448
+ workspace?: string
449
+ registry?: string
450
+ project?: string
451
+ repository?: string
411
452
  }
@@ -0,0 +1,152 @@
1
+ /* eslint-disable */
2
+ // @ts-nocheck
3
+ /*
4
+ * This file is a generated Typescript file for GRPC Gateway, DO NOT MODIFY
5
+ */
6
+
7
+ import * as KangarooIoApiTypesPage from "../../types/page.pb"
8
+
9
+ export enum RetentionRuleTemplate {
10
+ RETENTION_RULE_TEMPLATE_UNSPECIFIED = "RETENTION_RULE_TEMPLATE_UNSPECIFIED",
11
+ N_DAYS_SINCE_LAST_PULL = "N_DAYS_SINCE_LAST_PULL",
12
+ N_DAYS_SINCE_LAST_PUSH = "N_DAYS_SINCE_LAST_PUSH",
13
+ TYPE_ALWAYS = "TYPE_ALWAYS",
14
+ LATEST_PULLED_N = "LATEST_PULLED_N",
15
+ LATEST_PUSHED_K = "LATEST_PUSHED_K",
16
+ }
17
+
18
+ export enum RetentionRuleTriggerKind {
19
+ RETENTION_RULE_TRIGGER_KIND_UNSPECIFIED = "RETENTION_RULE_TRIGGER_KIND_UNSPECIFIED",
20
+ MANUAL = "MANUAL",
21
+ SCHEDULED = "SCHEDULED",
22
+ }
23
+
24
+ export enum RetentionDecoration {
25
+ RETENTION_DECORATION_UNSPECIFIED = "RETENTION_DECORATION_UNSPECIFIED",
26
+ REPO_MATCHES = "REPO_MATCHES",
27
+ REPO_EXCLUDES = "REPO_EXCLUDES",
28
+ }
29
+
30
+ export enum RetentionExecutionStatus {
31
+ RETENTION_EXECUTION_STATUS_UNSPECIFIED = "RETENTION_EXECUTION_STATUS_UNSPECIFIED",
32
+ RETENTION_EXECUTION_STATUS_RUNNING = "RETENTION_EXECUTION_STATUS_RUNNING",
33
+ RETENTION_EXECUTION_STATUS_STOPPED = "RETENTION_EXECUTION_STATUS_STOPPED",
34
+ RETENTION_EXECUTION_STATUS_SUCCEED = "RETENTION_EXECUTION_STATUS_SUCCEED",
35
+ RETENTION_EXECUTION_STATUS_ERROR = "RETENTION_EXECUTION_STATUS_ERROR",
36
+ }
37
+
38
+ export enum RetentionExecutionTrigger {
39
+ RETENTION_EXECUTION_TRIGGER_MANUAL = "RETENTION_EXECUTION_TRIGGER_MANUAL",
40
+ RETENTION_EXECUTION_TRIGGER_SCHEDULED = "RETENTION_EXECUTION_TRIGGER_SCHEDULED",
41
+ }
42
+
43
+ export type RetentionPolicy = {
44
+ algorithm?: string
45
+ id?: string
46
+ rules?: RetentionRule[]
47
+ scope?: RetentionPolicyScope
48
+ trigger?: RetentionRuleTrigger
49
+ }
50
+
51
+ export type RetentionRule = {
52
+ action?: string
53
+ disabled?: boolean
54
+ params?: {[key: string]: string}
55
+ scopeSelectors?: RetentionSelector[]
56
+ template?: RetentionRuleTemplate
57
+ }
58
+
59
+ export type RetentionPolicyScope = {
60
+ level?: string
61
+ ref?: string
62
+ }
63
+
64
+ export type RetentionRuleTrigger = {
65
+ kind?: RetentionRuleTriggerKind
66
+ settings?: RetentionRuleTriggerSettings
67
+ }
68
+
69
+ export type RetentionRuleTriggerSettings = {
70
+ cron?: string
71
+ }
72
+
73
+ export type RetentionSelector = {
74
+ decoration?: RetentionDecoration
75
+ extras?: string
76
+ kind?: string
77
+ pattern?: string
78
+ }
79
+
80
+ export type GetRetentionRequest = {
81
+ registry?: string
82
+ retentionId?: string
83
+ workspace?: string
84
+ }
85
+
86
+ export type UpdateRetentionRequest = {
87
+ registry?: string
88
+ retention?: RetentionPolicy
89
+ workspace?: string
90
+ retentionId?: string
91
+ }
92
+
93
+ export type RetentionExecution = {
94
+ dryRun?: boolean
95
+ endTime?: string
96
+ id?: string
97
+ policyId?: string
98
+ startTime?: string
99
+ status?: RetentionExecutionStatus
100
+ trigger?: RetentionExecutionTrigger
101
+ }
102
+
103
+ export type ListRetentionExecutionsRequest = {
104
+ registry?: string
105
+ retentionId?: string
106
+ workspace?: string
107
+ page?: number
108
+ pageSize?: number
109
+ }
110
+
111
+ export type ListRetentionExecutionsResponse = {
112
+ items?: RetentionExecution[]
113
+ pagination?: KangarooIoApiTypesPage.Page
114
+ }
115
+
116
+ export type CreateRetentionExecutionRequest = {
117
+ registry?: string
118
+ retentionId?: string
119
+ workspace?: string
120
+ dryRun?: boolean
121
+ }
122
+
123
+ export type StopRetentionExecutionRequest = {
124
+ registry?: string
125
+ retentionId?: string
126
+ workspace?: string
127
+ executionId?: string
128
+ }
129
+
130
+ export type CreateRetentionRuleRequest = {
131
+ registry?: string
132
+ retentionId?: string
133
+ workspace?: string
134
+ rule?: RetentionRule
135
+ }
136
+
137
+ export type CreateRetentionRuleResponse = {
138
+ rule?: RetentionRule[]
139
+ }
140
+
141
+ export type DeleteRetentionRuleRequest = {
142
+ registry?: string
143
+ retentionId?: string
144
+ workspace?: string
145
+ rule?: RetentionRule[]
146
+ }
147
+
148
+ export type CreateRetentionRequest = {
149
+ registry?: string
150
+ retention?: RetentionPolicy
151
+ workspace?: string
152
+ }
@@ -7,6 +7,7 @@
7
7
  import * as fm from "../../../../fetch.pb"
8
8
  import * as GoogleProtobufEmpty from "../../../../google/protobuf/empty.pb"
9
9
  import * as KangarooIoApiImageV1alpha1Image from "./image.pb"
10
+ import * as KangarooIoApiImageV1alpha1Retention from "./retention.pb"
10
11
  export class Image {
11
12
  static ListRegistry(req: KangarooIoApiImageV1alpha1Image.ListRegistryRequest, initReq?: fm.InitReq): Promise<KangarooIoApiImageV1alpha1Image.ListRegistryResponse> {
12
13
  return fm.fetchReq<KangarooIoApiImageV1alpha1Image.ListRegistryRequest, KangarooIoApiImageV1alpha1Image.ListRegistryResponse>(`/apis/kangaroo.io/v1alpha1/workspaces/${req["workspace"]}/registries/summary?${fm.renderURLSearchParams(req, ["workspace"])}`, {...initReq, method: "GET"})
@@ -14,9 +15,18 @@ export class Image {
14
15
  static ListProject(req: KangarooIoApiImageV1alpha1Image.ListProjectRequest, initReq?: fm.InitReq): Promise<KangarooIoApiImageV1alpha1Image.ListProjectResponse> {
15
16
  return fm.fetchReq<KangarooIoApiImageV1alpha1Image.ListProjectRequest, KangarooIoApiImageV1alpha1Image.ListProjectResponse>(`/apis/kangaroo.io/v1alpha1/workspaces/${req["workspace"]}/registries/${req["registry"]}/projects?${fm.renderURLSearchParams(req, ["workspace", "registry"])}`, {...initReq, method: "GET"})
16
17
  }
18
+ static GetProject(req: KangarooIoApiImageV1alpha1Image.GetProjectRequest, initReq?: fm.InitReq): Promise<KangarooIoApiImageV1alpha1Image.ListProjectResponseItem> {
19
+ return fm.fetchReq<KangarooIoApiImageV1alpha1Image.GetProjectRequest, KangarooIoApiImageV1alpha1Image.ListProjectResponseItem>(`/apis/kangaroo.io/v1alpha1/workspaces/${req["workspace"]}/registries/${req["registry"]}/projects/${req["project"]}?${fm.renderURLSearchParams(req, ["workspace", "registry", "project"])}`, {...initReq, method: "GET"})
20
+ }
17
21
  static ListRepositories(req: KangarooIoApiImageV1alpha1Image.ListRepositoriesRequest, initReq?: fm.InitReq): Promise<KangarooIoApiImageV1alpha1Image.ListRepositoriesResponse> {
18
22
  return fm.fetchReq<KangarooIoApiImageV1alpha1Image.ListRepositoriesRequest, KangarooIoApiImageV1alpha1Image.ListRepositoriesResponse>(`/apis/kangaroo.io/v1alpha1/workspaces/${req["workspace"]}/registries/${req["registry"]}/projects/${req["project"]}/repositories?${fm.renderURLSearchParams(req, ["workspace", "registry", "project"])}`, {...initReq, method: "GET"})
19
23
  }
24
+ static UpdateRepositoryDescription(req: KangarooIoApiImageV1alpha1Image.UpdateRepositoryDescriptionRequest, initReq?: fm.InitReq): Promise<KangarooIoApiImageV1alpha1Image.UpdateRepositoryDescriptionResponse> {
25
+ return fm.fetchReq<KangarooIoApiImageV1alpha1Image.UpdateRepositoryDescriptionRequest, KangarooIoApiImageV1alpha1Image.UpdateRepositoryDescriptionResponse>(`/apis/kangaroo.io/v1alpha1/workspaces/${req["workspace"]}/registries/${req["registry"]}/projects/${req["project"]}/repositories/${req["repository"]}`, {...initReq, method: "PUT", body: JSON.stringify(req)})
26
+ }
27
+ static GetRepository(req: KangarooIoApiImageV1alpha1Image.GetRepositoryRequest, initReq?: fm.InitReq): Promise<KangarooIoApiImageV1alpha1Image.Repository> {
28
+ return fm.fetchReq<KangarooIoApiImageV1alpha1Image.GetRepositoryRequest, KangarooIoApiImageV1alpha1Image.Repository>(`/apis/kangaroo.io/v1alpha1/workspaces/${req["workspace"]}/registries/${req["registry"]}/projects/${req["project"]}/repositories/${req["repository"]}?${fm.renderURLSearchParams(req, ["workspace", "registry", "project", "repository"])}`, {...initReq, method: "GET"})
29
+ }
20
30
  static ListArtifacts(req: KangarooIoApiImageV1alpha1Image.ListArtifactsRequest, initReq?: fm.InitReq): Promise<KangarooIoApiImageV1alpha1Image.ListArtifactsResponse> {
21
31
  return fm.fetchReq<KangarooIoApiImageV1alpha1Image.ListArtifactsRequest, KangarooIoApiImageV1alpha1Image.ListArtifactsResponse>(`/apis/kangaroo.io/v1alpha1/workspaces/${req["workspace"]}/registries/${req["registry"]}/projects/${req["project"]}/repositories/${req["repository"]}/artifacts?${fm.renderURLSearchParams(req, ["workspace", "registry", "project", "repository"])}`, {...initReq, method: "GET"})
22
32
  }
@@ -42,7 +52,7 @@ export class Image {
42
52
  return fm.fetchReq<KangarooIoApiImageV1alpha1Image.GetScanReportRequest, KangarooIoApiImageV1alpha1Image.GetScanReportResponse>(`/apis/kangaroo.io/v1alpha1/workspaces/${req["workspace"]}/registries/${req["registry"]}/projects/${req["project"]}/repositories/${req["repository"]}/artifacts/${req["digest"]}/scan/${req["report"]}?${fm.renderURLSearchParams(req, ["workspace", "registry", "project", "repository", "digest", "report"])}`, {...initReq, method: "GET"})
43
53
  }
44
54
  static GetPushCommand(req: KangarooIoApiImageV1alpha1Image.GetPushCommandRequest, initReq?: fm.InitReq): Promise<KangarooIoApiImageV1alpha1Image.GetPushCommandResponse> {
45
- return fm.fetchReq<KangarooIoApiImageV1alpha1Image.GetPushCommandRequest, KangarooIoApiImageV1alpha1Image.GetPushCommandResponse>(`/apis/kangaroo.io/v1alpha1/workspaces/${req["workspace"]}/registries/${req["registry"]}/project/${req["project"]}/push?${fm.renderURLSearchParams(req, ["workspace", "registry", "project"])}`, {...initReq, method: "GET"})
55
+ return fm.fetchReq<KangarooIoApiImageV1alpha1Image.GetPushCommandRequest, KangarooIoApiImageV1alpha1Image.GetPushCommandResponse>(`/apis/kangaroo.io/v1alpha1/workspaces/${req["workspace"]}/registries/${req["registry"]}/push?${fm.renderURLSearchParams(req, ["workspace", "registry"])}`, {...initReq, method: "GET"})
46
56
  }
47
57
  static GetScannerOfProject(req: KangarooIoApiImageV1alpha1Image.GetScannerOfProjectRequest, initReq?: fm.InitReq): Promise<KangarooIoApiImageV1alpha1Image.GetScannerOfProjectResponse> {
48
58
  return fm.fetchReq<KangarooIoApiImageV1alpha1Image.GetScannerOfProjectRequest, KangarooIoApiImageV1alpha1Image.GetScannerOfProjectResponse>(`/apis/kangaroo.io/v1alpha1/registries/${req["registry"]}/project/${req["project"]}/scanner?${fm.renderURLSearchParams(req, ["registry", "project"])}`, {...initReq, method: "GET"})
@@ -77,4 +87,24 @@ export class Image {
77
87
  static APIListArtifacts(req: KangarooIoApiImageV1alpha1Image.APIListArtifactsRequest, initReq?: fm.InitReq): Promise<KangarooIoApiImageV1alpha1Image.APIListArtifactsResponse> {
78
88
  return fm.fetchReq<KangarooIoApiImageV1alpha1Image.APIListArtifactsRequest, KangarooIoApiImageV1alpha1Image.APIListArtifactsResponse>(`/apis/kangaroo.io/v1alpha1/select/registries/${req["registry"]}/projects/${req["project"]}/repositories/${req["repository"]}/artifacts?${fm.renderURLSearchParams(req, ["registry", "project", "repository"])}`, {...initReq, method: "GET"})
79
89
  }
90
+ }
91
+ export class Retention {
92
+ static GetRetention(req: KangarooIoApiImageV1alpha1Retention.GetRetentionRequest, initReq?: fm.InitReq): Promise<KangarooIoApiImageV1alpha1Retention.RetentionPolicy> {
93
+ return fm.fetchReq<KangarooIoApiImageV1alpha1Retention.GetRetentionRequest, KangarooIoApiImageV1alpha1Retention.RetentionPolicy>(`/apis/kangaroo.io/v1alpha1/workspaces/${req["workspace"]}/registries/${req["registry"]}/retention/${req["retentionId"]}?${fm.renderURLSearchParams(req, ["workspace", "registry", "retentionId"])}`, {...initReq, method: "GET"})
94
+ }
95
+ static CreateRetention(req: KangarooIoApiImageV1alpha1Retention.CreateRetentionRequest, initReq?: fm.InitReq): Promise<GoogleProtobufEmpty.Empty> {
96
+ return fm.fetchReq<KangarooIoApiImageV1alpha1Retention.CreateRetentionRequest, GoogleProtobufEmpty.Empty>(`/apis/kangaroo.io/v1alpha1/workspaces/${req["workspace"]}/registries/${req["registry"]}/retention`, {...initReq, method: "POST", body: JSON.stringify(req)})
97
+ }
98
+ static UpdateRetention(req: KangarooIoApiImageV1alpha1Retention.UpdateRetentionRequest, initReq?: fm.InitReq): Promise<KangarooIoApiImageV1alpha1Retention.RetentionPolicy> {
99
+ return fm.fetchReq<KangarooIoApiImageV1alpha1Retention.UpdateRetentionRequest, KangarooIoApiImageV1alpha1Retention.RetentionPolicy>(`/apis/kangaroo.io/v1alpha1/workspaces/${req["workspace"]}/registries/${req["registry"]}/retention/${req["retentionId"]}`, {...initReq, method: "PUT", body: JSON.stringify(req)})
100
+ }
101
+ static ListRetentionExecutions(req: KangarooIoApiImageV1alpha1Retention.ListRetentionExecutionsRequest, initReq?: fm.InitReq): Promise<KangarooIoApiImageV1alpha1Retention.ListRetentionExecutionsResponse> {
102
+ return fm.fetchReq<KangarooIoApiImageV1alpha1Retention.ListRetentionExecutionsRequest, KangarooIoApiImageV1alpha1Retention.ListRetentionExecutionsResponse>(`/apis/kangaroo.io/v1alpha1/workspaces/${req["workspace"]}/registries/${req["registry"]}/retention/${req["retentionId"]}/executions?${fm.renderURLSearchParams(req, ["workspace", "registry", "retentionId"])}`, {...initReq, method: "GET"})
103
+ }
104
+ static CreateRetentionExecution(req: KangarooIoApiImageV1alpha1Retention.CreateRetentionExecutionRequest, initReq?: fm.InitReq): Promise<GoogleProtobufEmpty.Empty> {
105
+ return fm.fetchReq<KangarooIoApiImageV1alpha1Retention.CreateRetentionExecutionRequest, GoogleProtobufEmpty.Empty>(`/apis/kangaroo.io/v1alpha1/workspaces/${req["workspace"]}/registries/${req["registry"]}/retention/${req["retentionId"]}/executions`, {...initReq, method: "POST", body: JSON.stringify(req)})
106
+ }
107
+ static StopRetentionExecution(req: KangarooIoApiImageV1alpha1Retention.StopRetentionExecutionRequest, initReq?: fm.InitReq): Promise<GoogleProtobufEmpty.Empty> {
108
+ return fm.fetchReq<KangarooIoApiImageV1alpha1Retention.StopRetentionExecutionRequest, GoogleProtobufEmpty.Empty>(`/apis/kangaroo.io/v1alpha1/workspaces/${req["workspace"]}/registries/${req["registry"]}/retention/${req["retentionId"]}/executions/${req["executionId"]}`, {...initReq, method: "PUT"})
109
+ }
80
110
  }
@@ -19,6 +19,12 @@ export enum IntegratedType {
19
19
  Manual = "Manual",
20
20
  }
21
21
 
22
+ export enum RegistryTarGetClusterStatus {
23
+ TARGET_CLUSTER_STATUS_UNSPECIFIED = "TARGET_CLUSTER_STATUS_UNSPECIFIED",
24
+ TARGET_CLUSTER_STATUS_NOT_FOUND = "TARGET_CLUSTER_STATUS_NOT_FOUND",
25
+ TARGET_CLUSTER_STATUS_NORMAL = "TARGET_CLUSTER_STATUS_NORMAL",
26
+ }
27
+
22
28
  export enum RegistryStatusClusterStatus {
23
29
  CLUSTER_STATUS_UNSPECIFIED = "CLUSTER_STATUS_UNSPECIFIED",
24
30
  HEALTHY = "HEALTHY",
@@ -33,6 +39,8 @@ export type Registry = {
33
39
  integratedType?: IntegratedType
34
40
  status?: RegistryStatus
35
41
  createAt?: string
42
+ isExist?: boolean
43
+ clusterStatus?: RegistryTarGetClusterStatus
36
44
  }
37
45
 
38
46
  export type RegistryStatus = {
@@ -63,6 +71,7 @@ export type ListRegistryRequest = {
63
71
  page?: number
64
72
  pageSize?: number
65
73
  fuzzyName?: string
74
+ intergratedType?: IntegratedType
66
75
  }
67
76
 
68
77
  export type ListRegistryResponse = {
@@ -70,6 +79,18 @@ export type ListRegistryResponse = {
70
79
  pagination?: KangarooIoApiTypesPage.Page
71
80
  }
72
81
 
82
+ export type ListFilterRegistryRequest = {
83
+ page?: number
84
+ pageSize?: number
85
+ registry?: string
86
+ fuzzyName?: string
87
+ }
88
+
89
+ export type ListFilterRegistryResponse = {
90
+ items?: Registry[]
91
+ pagination?: KangarooIoApiTypesPage.Page
92
+ }
93
+
73
94
  export type RegistryAdminCredential = {
74
95
  username?: string
75
96
  password?: string
@@ -155,4 +176,14 @@ export type GetRegistryTypeRequest = {
155
176
  export type GetRegistryTypeResponse = {
156
177
  registry?: string
157
178
  type?: RegistryType
179
+ }
180
+
181
+ export type RegistryRobotInfoRequest = {
182
+ registry?: string
183
+ workspace?: string
184
+ }
185
+
186
+ export type RegistryRobotInfoResponse = {
187
+ username?: string
188
+ password?: string
158
189
  }
@@ -6,7 +6,7 @@
6
6
 
7
7
  import * as KangarooIoApiTypesPage from "../../types/page.pb"
8
8
 
9
- export enum native_registry_type {
9
+ export enum NativeRegistryType {
10
10
  NATIVE_REGISTRY_UNSPECIFIED = "NATIVE_REGISTRY_UNSPECIFIED",
11
11
  NATIVE_REGISTRY_DOCKER_REGISTRY = "NATIVE_REGISTRY_DOCKER_REGISTRY",
12
12
  NATIVE_REGISTRY_HARBOR = "NATIVE_REGISTRY_HARBOR",
@@ -45,6 +45,12 @@ export enum FilterFilterType {
45
45
  TAG = "TAG",
46
46
  }
47
47
 
48
+ export enum FilterDecoration {
49
+ DECORATION_UNSPECIFIED = "DECORATION_UNSPECIFIED",
50
+ DECORATION_MATCHES = "DECORATION_MATCHES",
51
+ DECORATION_EXCLUDES = "DECORATION_EXCLUDES",
52
+ }
53
+
48
54
  export enum ExecutionStatus {
49
55
  STATUS_UNSPECIFIED = "STATUS_UNSPECIFIED",
50
56
  STATUS_STOPPED = "STATUS_STOPPED",
@@ -77,13 +83,14 @@ export type ListNativeRegistryRequest = {
77
83
 
78
84
  export type NativeRegistry = {
79
85
  id?: string
80
- type?: native_registry_type
86
+ type?: NativeRegistryType
81
87
  name?: string
82
88
  url?: string
83
89
  nativeRegistryCredential?: NativeRegistryCredential
84
90
  insecure?: boolean
85
91
  description?: string
86
92
  status?: NativeRegistryregistry_status
93
+ creationTime?: string
87
94
  }
88
95
 
89
96
  export type NativeRegistryCredential = {
@@ -98,7 +105,7 @@ export type ListNativeRegistryResponse = {
98
105
  }
99
106
 
100
107
  export type NativeRegistrySpec = {
101
- type?: native_registry_type
108
+ type?: NativeRegistryType
102
109
  name?: string
103
110
  url?: string
104
111
  nativeRegistryCredential?: NativeRegistryCredential
@@ -125,7 +132,7 @@ export type DeleteNativeRegistryRequest = {
125
132
  }
126
133
 
127
134
  export type Policy = {
128
- disRegistry?: NativeRegistry
135
+ destRegistry?: NativeRegistry
129
136
  srcRegistry?: NativeRegistry
130
137
  enabled?: boolean
131
138
  creationTime?: string
@@ -135,6 +142,7 @@ export type Policy = {
135
142
  override?: boolean
136
143
  name?: string
137
144
  description?: string
145
+ destNamespace?: string
138
146
  filters?: Filter[]
139
147
  trigger?: Trigger
140
148
  }
@@ -147,6 +155,7 @@ export type Trigger = {
147
155
  export type Filter = {
148
156
  type?: FilterFilterType
149
157
  value?: string
158
+ decoration?: FilterDecoration
150
159
  }
151
160
 
152
161
  export type ListPoliciesRequest = {
@@ -196,6 +205,8 @@ export type ListExecutionsRequest = {
196
205
  page?: number
197
206
  pageSize?: number
198
207
  policyId?: string
208
+ status?: string
209
+ trigger?: string
199
210
  }
200
211
 
201
212
  export type ListExecutionsResponse = {
@@ -209,11 +220,12 @@ export type CreatePolicyRequest = {
209
220
  description?: string
210
221
  trigger?: Trigger
211
222
  filters?: Filter[]
212
- srcRegistry?: NativeRegistry
213
- disRegistry?: NativeRegistry
223
+ srcRegistryId?: string
224
+ destRegistryId?: string
214
225
  enabled?: boolean
215
226
  override?: boolean
216
227
  destNamespace?: string
228
+ speed?: number
217
229
  }
218
230
 
219
231
  export type UpdatePolicyRequest = {
@@ -224,10 +236,11 @@ export type UpdatePolicyRequest = {
224
236
  trigger?: Trigger
225
237
  filters?: Filter[]
226
238
  srcRegistry?: NativeRegistry
227
- disRegistry?: NativeRegistry
239
+ destRegistry?: NativeRegistry
228
240
  enabled?: boolean
229
241
  override?: boolean
230
242
  destNamespace?: string
243
+ speed?: number
231
244
  }
232
245
 
233
246
  export type GetExecutionRequest = {
@@ -250,7 +263,7 @@ export type ListReplicationTasksResponse = {
250
263
  }
251
264
 
252
265
  export type ReplicationTask = {
253
- dstResource?: string
266
+ destResource?: string
254
267
  endTime?: string
255
268
  executionId?: string
256
269
  id?: string
@@ -48,6 +48,12 @@ export class Registries {
48
48
  static GetStorageStatistic(req: KangarooIoApiRegistryV1alpha1Registry.GetStorageStatisticRequest, initReq?: fm.InitReq): Promise<KangarooIoApiRegistryV1alpha1Registry.GetStorageStatisticResponse> {
49
49
  return fm.fetchReq<KangarooIoApiRegistryV1alpha1Registry.GetStorageStatisticRequest, KangarooIoApiRegistryV1alpha1Registry.GetStorageStatisticResponse>(`/apis/kangaroo.io/v1alpha1/registries/${req["registry"]}/storage_statistic?${fm.renderURLSearchParams(req, ["registry"])}`, {...initReq, method: "GET"})
50
50
  }
51
+ static ListFilterRegistry(req: KangarooIoApiRegistryV1alpha1Registry.ListFilterRegistryRequest, initReq?: fm.InitReq): Promise<KangarooIoApiRegistryV1alpha1Registry.ListFilterRegistryResponse> {
52
+ return fm.fetchReq<KangarooIoApiRegistryV1alpha1Registry.ListFilterRegistryRequest, KangarooIoApiRegistryV1alpha1Registry.ListFilterRegistryResponse>(`/apis/kangaroo.io/v1alpha1/filter_registries/${req["registry"]}/registries?${fm.renderURLSearchParams(req, ["registry"])}`, {...initReq, method: "GET"})
53
+ }
54
+ static GetRegistryRobotInfo(req: KangarooIoApiRegistryV1alpha1Registry.RegistryRobotInfoRequest, initReq?: fm.InitReq): Promise<KangarooIoApiRegistryV1alpha1Registry.RegistryRobotInfoResponse> {
55
+ return fm.fetchReq<KangarooIoApiRegistryV1alpha1Registry.RegistryRobotInfoRequest, KangarooIoApiRegistryV1alpha1Registry.RegistryRobotInfoResponse>(`/apis/kangaroo.io/v1alpha1/workspaces/${req["workspace"]}/registries/${req["registry"]}/robot_info?${fm.renderURLSearchParams(req, ["workspace", "registry"])}`, {...initReq, method: "GET"})
56
+ }
51
57
  }
52
58
  export class Replications {
53
59
  static ListNativeRegistry(req: KangarooIoApiRegistryV1alpha1Replication.ListNativeRegistryRequest, initReq?: fm.InitReq): Promise<KangarooIoApiRegistryV1alpha1Replication.ListNativeRegistryResponse> {
@@ -69,7 +75,7 @@ export class Replications {
69
75
  return fm.fetchReq<KangarooIoApiRegistryV1alpha1Replication.DeletePolicyRequest, GoogleProtobufEmpty.Empty>(`/apis/kangaroo.io/v1alpha1/registries/${req["registry"]}/policies/${req["policyId"]}`, {...initReq, method: "DELETE"})
70
76
  }
71
77
  static CreateExecution(req: KangarooIoApiRegistryV1alpha1Replication.CreateExecutionRequest, initReq?: fm.InitReq): Promise<GoogleProtobufEmpty.Empty> {
72
- return fm.fetchReq<KangarooIoApiRegistryV1alpha1Replication.CreateExecutionRequest, GoogleProtobufEmpty.Empty>(`/apis/kangaroo.io/v1alpha1/registries/${req["registry"]}/executions`, {...initReq, method: "POST"})
78
+ return fm.fetchReq<KangarooIoApiRegistryV1alpha1Replication.CreateExecutionRequest, GoogleProtobufEmpty.Empty>(`/apis/kangaroo.io/v1alpha1/registries/${req["registry"]}/executions`, {...initReq, method: "POST", body: JSON.stringify(req)})
73
79
  }
74
80
  static StopExecution(req: KangarooIoApiRegistryV1alpha1Replication.StopExecutionRequest, initReq?: fm.InitReq): Promise<GoogleProtobufEmpty.Empty> {
75
81
  return fm.fetchReq<KangarooIoApiRegistryV1alpha1Replication.StopExecutionRequest, GoogleProtobufEmpty.Empty>(`/apis/kangaroo.io/v1alpha1/registries/${req["registry"]}/executions/${req["executionId"]}`, {...initReq, method: "PUT"})
@@ -0,0 +1,17 @@
1
+ /* eslint-disable */
2
+ // @ts-nocheck
3
+ /*
4
+ * This file is a generated Typescript file for GRPC Gateway, DO NOT MODIFY
5
+ */
6
+
7
+ import * as fm from "../../../../fetch.pb"
8
+ import * as GoogleProtobufEmpty from "../../../../google/protobuf/empty.pb"
9
+ import * as KangarooIoApiUploadV1alpha1Upload from "./upload.pb"
10
+ export class Uploader {
11
+ static UploadOCI(req: KangarooIoApiUploadV1alpha1Upload.UploadOCIRequest, initReq?: fm.InitReq): Promise<GoogleProtobufEmpty.Empty> {
12
+ return fm.fetchReq<KangarooIoApiUploadV1alpha1Upload.UploadOCIRequest, GoogleProtobufEmpty.Empty>(`/apis/upload.kangaroo.io/v1alpha1/registries/${req["registry"]}/upload`, {...initReq, method: "POST", body: JSON.stringify(req)})
13
+ }
14
+ static DownloadOCI(req: KangarooIoApiUploadV1alpha1Upload.DownloadOCIRequest, initReq?: fm.InitReq): Promise<GoogleProtobufEmpty.Empty> {
15
+ return fm.fetchReq<KangarooIoApiUploadV1alpha1Upload.DownloadOCIRequest, GoogleProtobufEmpty.Empty>(`/apis/upload.kangaroo.io/v1alpha1/registries/${req["registry"]}/download?${fm.renderURLSearchParams(req, ["registry"])}`, {...initReq, method: "GET"})
16
+ }
17
+ }
@@ -0,0 +1,15 @@
1
+ /* eslint-disable */
2
+ // @ts-nocheck
3
+ /*
4
+ * This file is a generated Typescript file for GRPC Gateway, DO NOT MODIFY
5
+ */
6
+ export type UploadOCIRequest = {
7
+ registry?: string
8
+ imageUrl?: string
9
+ file?: Uint8Array
10
+ }
11
+
12
+ export type DownloadOCIRequest = {
13
+ registry?: string
14
+ imageUrl?: string
15
+ }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name":"@daocloud-proto/kangaroo",
3
- "version":"0.5.0-48",
3
+ "version":"0.5.0-481",
4
4
  "description": "",
5
5
  "main": "index.js",
6
6
  "scripts": {