@daocloud-proto/kangaroo 0.5.0-28 → 0.5.0-281
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.
- package/google/protobuf/any.pb.ts +9 -0
- package/kangaroo.io/api/core/v1alpha1/auth.pb.ts +29 -2
- package/kangaroo.io/api/harbor/v1alpha1/harbor.pb.ts +64 -0
- package/kangaroo.io/api/harbor/v1alpha1/postgresql.pb.ts +33 -0
- package/kangaroo.io/api/harbor/v1alpha1/rpc.pb.ts +14 -0
- package/kangaroo.io/api/image/v1alpha1/image.pb.ts +44 -2
- package/kangaroo.io/api/image/v1alpha1/retention.pb.ts +152 -0
- package/kangaroo.io/api/image/v1alpha1/rpc.pb.ts +31 -1
- package/kangaroo.io/api/registry/v1alpha1/registry.pb.ts +13 -0
- package/kangaroo.io/api/registry/v1alpha1/replication.pb.ts +284 -0
- package/kangaroo.io/api/registry/v1alpha1/rpc.pb.ts +48 -0
- package/kangaroo.io/api/upload/v1alpha1/rpc.pb.ts +17 -0
- package/kangaroo.io/api/upload/v1alpha1/upload.pb.ts +15 -0
- package/package.json +1 -1
|
@@ -3,12 +3,39 @@
|
|
|
3
3
|
/*
|
|
4
4
|
* This file is a generated Typescript file for GRPC Gateway, DO NOT MODIFY
|
|
5
5
|
*/
|
|
6
|
+
|
|
7
|
+
export enum PermissionsType {
|
|
8
|
+
ScanImage = "ScanImage",
|
|
9
|
+
DeleteImage = "DeleteImage",
|
|
10
|
+
GetImage = "GetImage",
|
|
11
|
+
CreateImageKey = "CreateImageKey",
|
|
12
|
+
CreateConnectedRegistry = "CreateConnectedRegistry",
|
|
13
|
+
DeleteConnectedRegistry = "DeleteConnectedRegistry",
|
|
14
|
+
UpdateConnectedRegistry = "UpdateConnectedRegistry",
|
|
15
|
+
GetConnectedRegistry = "GetConnectedRegistry",
|
|
16
|
+
CreateRegistryIntegration = "CreateRegistryIntegration",
|
|
17
|
+
DeleteRegistryIntegration = "DeleteRegistryIntegration",
|
|
18
|
+
UpdateRegistryIntegration = "UpdateRegistryIntegration",
|
|
19
|
+
GetRegistryIntegration = "GetRegistryIntegration",
|
|
20
|
+
CreateRegistrySpace = "CreateRegistrySpace",
|
|
21
|
+
DeleteRegistrySpace = "DeleteRegistrySpace",
|
|
22
|
+
UpdateRegistrySpace = "UpdateRegistrySpace",
|
|
23
|
+
GetRegistrySpace = "GetRegistrySpace",
|
|
24
|
+
BindRegistrySpace = "BindRegistrySpace",
|
|
25
|
+
CreateManagedHarbor = "CreateManagedHarbor",
|
|
26
|
+
DeleteManagedHarbor = "DeleteManagedHarbor",
|
|
27
|
+
UpdateManagedHarbor = "UpdateManagedHarbor",
|
|
28
|
+
GetManagedHarbor = "GetManagedHarbor",
|
|
29
|
+
CreateImage = "CreateImage",
|
|
30
|
+
UpdateImage = "UpdateImage",
|
|
31
|
+
}
|
|
32
|
+
|
|
6
33
|
export type GlobalPermissionsResponse = {
|
|
7
|
-
permissions?:
|
|
34
|
+
permissions?: PermissionsType[]
|
|
8
35
|
}
|
|
9
36
|
|
|
10
37
|
export type WorkspacePermissionsResponse = {
|
|
11
|
-
permissions?:
|
|
38
|
+
permissions?: PermissionsType[]
|
|
12
39
|
}
|
|
13
40
|
|
|
14
41
|
export type WorkspacePermissionsRequest = {
|
|
@@ -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",
|
|
@@ -62,6 +68,7 @@ export type GetHarborParamsResponse = {
|
|
|
62
68
|
export type ResourceNameList = {
|
|
63
69
|
name?: string
|
|
64
70
|
default?: boolean
|
|
71
|
+
hwameistorReplicas?: number
|
|
65
72
|
}
|
|
66
73
|
|
|
67
74
|
export type VerifyHarborOperatorRequest = {
|
|
@@ -101,6 +108,7 @@ export type HarborClusterSpec = {
|
|
|
101
108
|
userSyncToHarbor?: boolean
|
|
102
109
|
adminPassword?: string
|
|
103
110
|
enableTrivy?: boolean
|
|
111
|
+
enableMetrics?: boolean
|
|
104
112
|
}
|
|
105
113
|
|
|
106
114
|
export type Resources = {
|
|
@@ -119,6 +127,10 @@ export type DBBuiltInModeSpec = {
|
|
|
119
127
|
}
|
|
120
128
|
|
|
121
129
|
export type DBMcamelModeSpec = {
|
|
130
|
+
cluster?: string
|
|
131
|
+
namespace?: string
|
|
132
|
+
name?: string
|
|
133
|
+
workspace?: string
|
|
122
134
|
}
|
|
123
135
|
|
|
124
136
|
export type DBExternalModeSpec = {
|
|
@@ -179,6 +191,12 @@ export type ExposeSpec = {
|
|
|
179
191
|
nodePortSpec?: ExposeNodePortSpec
|
|
180
192
|
externalUrl?: string
|
|
181
193
|
exposeHttps?: boolean
|
|
194
|
+
httpsSpec?: HttpsSpec
|
|
195
|
+
}
|
|
196
|
+
|
|
197
|
+
export type HttpsSpec = {
|
|
198
|
+
namespace?: string
|
|
199
|
+
name?: string
|
|
182
200
|
}
|
|
183
201
|
|
|
184
202
|
export type ExposeIngressSpec = {
|
|
@@ -244,4 +262,50 @@ export type VerifyNodePortRequest = {
|
|
|
244
262
|
|
|
245
263
|
export type VerifyNodePortResponse = {
|
|
246
264
|
status?: boolean
|
|
265
|
+
}
|
|
266
|
+
|
|
267
|
+
export type ListTLSRequest = {
|
|
268
|
+
cluster?: string
|
|
269
|
+
namespace?: string
|
|
270
|
+
}
|
|
271
|
+
|
|
272
|
+
export type ListTLSResponse = {
|
|
273
|
+
items?: ListTLSResponseItem[]
|
|
274
|
+
}
|
|
275
|
+
|
|
276
|
+
export type ListTLSResponseItem = {
|
|
277
|
+
namespace?: string
|
|
278
|
+
name?: string
|
|
279
|
+
type?: TLSType
|
|
280
|
+
}
|
|
281
|
+
|
|
282
|
+
export type CheckDependServiceRequest = {
|
|
283
|
+
name?: string
|
|
284
|
+
namespace?: string
|
|
285
|
+
cluster?: string
|
|
286
|
+
database?: DatabaseSpec
|
|
287
|
+
cache?: CacheSpec
|
|
288
|
+
storage?: OCIStorageSpec
|
|
289
|
+
}
|
|
290
|
+
|
|
291
|
+
export type DatabaseCheckResponse = {
|
|
292
|
+
status?: string
|
|
293
|
+
message?: string
|
|
294
|
+
}
|
|
295
|
+
|
|
296
|
+
export type CacheCheckResponse = {
|
|
297
|
+
status?: string
|
|
298
|
+
message?: string
|
|
299
|
+
}
|
|
300
|
+
|
|
301
|
+
export type StorageCheckResponse = {
|
|
302
|
+
status?: string
|
|
303
|
+
message?: string
|
|
304
|
+
}
|
|
305
|
+
|
|
306
|
+
export type CheckDependServiceResponse = {
|
|
307
|
+
completed?: boolean
|
|
308
|
+
db?: DatabaseCheckResponse
|
|
309
|
+
cache?: CacheCheckResponse
|
|
310
|
+
storage?: StorageCheckResponse
|
|
247
311
|
}
|
|
@@ -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,9 @@
|
|
|
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 KangarooIoApiHarborV1alpha1Postgresql from "./postgresql.pb"
|
|
10
12
|
import * as KangarooIoApiHarborV1alpha1Redis from "./redis.pb"
|
|
11
13
|
export class Harbor {
|
|
12
14
|
static GetHarborParams(req: KangarooIoApiHarborV1alpha1Harbor.GetHarborParamsRequest, initReq?: fm.InitReq): Promise<KangarooIoApiHarborV1alpha1Harbor.GetHarborParamsResponse> {
|
|
@@ -39,4 +41,16 @@ export class Harbor {
|
|
|
39
41
|
static ListRedis(req: KangarooIoApiHarborV1alpha1Redis.ListRedisRequest, initReq?: fm.InitReq): Promise<KangarooIoApiHarborV1alpha1Redis.ListRedisResponse> {
|
|
40
42
|
return fm.fetchReq<KangarooIoApiHarborV1alpha1Redis.ListRedisRequest, KangarooIoApiHarborV1alpha1Redis.ListRedisResponse>(`/apis/kangaroo.io/v1alpha1/workspace/${req["workspace"]}/redis?${fm.renderURLSearchParams(req, ["workspace"])}`, {...initReq, method: "GET"})
|
|
41
43
|
}
|
|
44
|
+
static ListPostgresql(req: KangarooIoApiHarborV1alpha1Postgresql.ListPostgresqlRequest, initReq?: fm.InitReq): Promise<KangarooIoApiHarborV1alpha1Postgresql.ListPostgresqlResponse> {
|
|
45
|
+
return fm.fetchReq<KangarooIoApiHarborV1alpha1Postgresql.ListPostgresqlRequest, KangarooIoApiHarborV1alpha1Postgresql.ListPostgresqlResponse>(`/apis/kangaroo.io/v1alpha1/workspace/${req["workspace"]}/postgresql?${fm.renderURLSearchParams(req, ["workspace"])}`, {...initReq, method: "GET"})
|
|
46
|
+
}
|
|
47
|
+
static ListTLSSecret(req: KangarooIoApiHarborV1alpha1Harbor.ListTLSRequest, initReq?: fm.InitReq): Promise<KangarooIoApiHarborV1alpha1Harbor.ListTLSResponse> {
|
|
48
|
+
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"})
|
|
49
|
+
}
|
|
50
|
+
static CreateVerifyDependService(req: KangarooIoApiHarborV1alpha1Harbor.CheckDependServiceRequest, initReq?: fm.InitReq): Promise<GoogleProtobufEmpty.Empty> {
|
|
51
|
+
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)})
|
|
52
|
+
}
|
|
53
|
+
static GetVerifyDependService(req: KangarooIoApiTypesObjectmeta.ObjectMeta, initReq?: fm.InitReq): Promise<KangarooIoApiHarborV1alpha1Harbor.CheckDependServiceResponse> {
|
|
54
|
+
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"})
|
|
55
|
+
}
|
|
42
56
|
}
|
|
@@ -6,6 +6,12 @@
|
|
|
6
6
|
|
|
7
7
|
import * as KangarooIoApiTypesPage from "../../types/page.pb"
|
|
8
8
|
|
|
9
|
+
export enum RegistrySecretHealth {
|
|
10
|
+
health_unspecified = "health_unspecified",
|
|
11
|
+
healthy = "healthy",
|
|
12
|
+
unhealthy = "unhealthy",
|
|
13
|
+
}
|
|
14
|
+
|
|
9
15
|
export enum ListRepositoriesRequestSortBy {
|
|
10
16
|
unspecified = "unspecified",
|
|
11
17
|
pull_count = "pull_count",
|
|
@@ -51,6 +57,7 @@ export type RegistrySecret = {
|
|
|
51
57
|
alias?: string
|
|
52
58
|
host?: string
|
|
53
59
|
name?: string
|
|
60
|
+
health?: RegistrySecretHealth
|
|
54
61
|
}
|
|
55
62
|
|
|
56
63
|
export type ListRegistryResponse = {
|
|
@@ -63,19 +70,36 @@ export type ListProjectRequest = {
|
|
|
63
70
|
registry?: string
|
|
64
71
|
page?: number
|
|
65
72
|
pageSize?: number
|
|
73
|
+
fuzzyName?: string
|
|
74
|
+
}
|
|
75
|
+
|
|
76
|
+
export type GetProjectRequest = {
|
|
77
|
+
workspace?: string
|
|
78
|
+
registry?: string
|
|
79
|
+
project?: string
|
|
66
80
|
}
|
|
67
81
|
|
|
68
82
|
export type ListProjectResponse = {
|
|
69
|
-
items?:
|
|
83
|
+
items?: ListProjectResponseItem[]
|
|
70
84
|
pagination?: KangarooIoApiTypesPage.Page
|
|
71
85
|
}
|
|
72
86
|
|
|
87
|
+
export type ListProjectResponseItem = {
|
|
88
|
+
name?: string
|
|
89
|
+
public?: boolean
|
|
90
|
+
total?: string
|
|
91
|
+
createTime?: string
|
|
92
|
+
retentionId?: string
|
|
93
|
+
projectId?: string
|
|
94
|
+
}
|
|
95
|
+
|
|
73
96
|
export type Repository = {
|
|
74
97
|
name?: string
|
|
75
98
|
public?: boolean
|
|
76
99
|
tagCount?: string
|
|
77
100
|
pullCount?: string
|
|
78
101
|
updateTime?: string
|
|
102
|
+
description?: string
|
|
79
103
|
}
|
|
80
104
|
|
|
81
105
|
export type ListRepositoriesRequest = {
|
|
@@ -393,7 +417,6 @@ export type GetScannerOfProjectResponse = {
|
|
|
393
417
|
export type GetPushCommandRequest = {
|
|
394
418
|
workspace?: string
|
|
395
419
|
registry?: string
|
|
396
|
-
project?: string
|
|
397
420
|
expired?: string
|
|
398
421
|
}
|
|
399
422
|
|
|
@@ -401,4 +424,23 @@ export type GetPushCommandResponse = {
|
|
|
401
424
|
cmd?: string
|
|
402
425
|
expired?: string
|
|
403
426
|
expiredAt?: string
|
|
427
|
+
}
|
|
428
|
+
|
|
429
|
+
export type UpdateRepositoryDescriptionRequest = {
|
|
430
|
+
workspace?: string
|
|
431
|
+
registry?: string
|
|
432
|
+
project?: string
|
|
433
|
+
repository?: string
|
|
434
|
+
description?: string
|
|
435
|
+
}
|
|
436
|
+
|
|
437
|
+
export type UpdateRepositoryDescriptionResponse = {
|
|
438
|
+
description?: string
|
|
439
|
+
}
|
|
440
|
+
|
|
441
|
+
export type GetRepositoryRequest = {
|
|
442
|
+
workspace?: string
|
|
443
|
+
registry?: string
|
|
444
|
+
project?: string
|
|
445
|
+
repository?: string
|
|
404
446
|
}
|
|
@@ -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"]}/
|
|
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
|
}
|
|
@@ -33,6 +33,7 @@ export type Registry = {
|
|
|
33
33
|
integratedType?: IntegratedType
|
|
34
34
|
status?: RegistryStatus
|
|
35
35
|
createAt?: string
|
|
36
|
+
isExist?: boolean
|
|
36
37
|
}
|
|
37
38
|
|
|
38
39
|
export type RegistryStatus = {
|
|
@@ -70,6 +71,18 @@ export type ListRegistryResponse = {
|
|
|
70
71
|
pagination?: KangarooIoApiTypesPage.Page
|
|
71
72
|
}
|
|
72
73
|
|
|
74
|
+
export type ListFilterRegistryRequest = {
|
|
75
|
+
page?: number
|
|
76
|
+
pageSize?: number
|
|
77
|
+
registry?: string
|
|
78
|
+
fuzzyName?: string
|
|
79
|
+
}
|
|
80
|
+
|
|
81
|
+
export type ListFilterRegistryResponse = {
|
|
82
|
+
items?: Registry[]
|
|
83
|
+
pagination?: KangarooIoApiTypesPage.Page
|
|
84
|
+
}
|
|
85
|
+
|
|
73
86
|
export type RegistryAdminCredential = {
|
|
74
87
|
username?: string
|
|
75
88
|
password?: string
|
|
@@ -0,0 +1,284 @@
|
|
|
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 NativeRegistryType {
|
|
10
|
+
NATIVE_REGISTRY_UNSPECIFIED = "NATIVE_REGISTRY_UNSPECIFIED",
|
|
11
|
+
NATIVE_REGISTRY_DOCKER_REGISTRY = "NATIVE_REGISTRY_DOCKER_REGISTRY",
|
|
12
|
+
NATIVE_REGISTRY_HARBOR = "NATIVE_REGISTRY_HARBOR",
|
|
13
|
+
NATIVE_REGISTRY_JFROG_ARTIFACTORY = "NATIVE_REGISTRY_JFROG_ARTIFACTORY",
|
|
14
|
+
}
|
|
15
|
+
|
|
16
|
+
export enum TriggerMode {
|
|
17
|
+
TRIGGER_MODEL_UNSPECIFIED = "TRIGGER_MODEL_UNSPECIFIED",
|
|
18
|
+
TRIGGER_MODEL_MANUAL = "TRIGGER_MODEL_MANUAL",
|
|
19
|
+
TRIGGER_MODEL_SCHEDULE = "TRIGGER_MODEL_SCHEDULE",
|
|
20
|
+
TRIGGER_MODEL_EVENT_BASED = "TRIGGER_MODEL_EVENT_BASED",
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
export enum NativeRegistryregistry_status {
|
|
24
|
+
UNSPECIFIED = "UNSPECIFIED",
|
|
25
|
+
HEALTHY = "HEALTHY",
|
|
26
|
+
UNHEALTHY = "UNHEALTHY",
|
|
27
|
+
}
|
|
28
|
+
|
|
29
|
+
export enum NativeRegistryCredentialcredential_type {
|
|
30
|
+
UNSPECIFIED = "UNSPECIFIED",
|
|
31
|
+
BASIC = "BASIC",
|
|
32
|
+
OAUTH = "OAUTH",
|
|
33
|
+
SECRET = "SECRET",
|
|
34
|
+
}
|
|
35
|
+
|
|
36
|
+
export enum CreateNativeRegistryRequestType {
|
|
37
|
+
UNSPECIFIED = "UNSPECIFIED",
|
|
38
|
+
INTEGRATION = "INTEGRATION",
|
|
39
|
+
NATIVE = "NATIVE",
|
|
40
|
+
}
|
|
41
|
+
|
|
42
|
+
export enum FilterFilterType {
|
|
43
|
+
UNSPECIFIED = "UNSPECIFIED",
|
|
44
|
+
NAME = "NAME",
|
|
45
|
+
TAG = "TAG",
|
|
46
|
+
}
|
|
47
|
+
|
|
48
|
+
export enum FilterDecoration {
|
|
49
|
+
DECORATION_UNSPECIFIED = "DECORATION_UNSPECIFIED",
|
|
50
|
+
DECORATION_MATCHES = "DECORATION_MATCHES",
|
|
51
|
+
DECORATION_EXCLUDES = "DECORATION_EXCLUDES",
|
|
52
|
+
}
|
|
53
|
+
|
|
54
|
+
export enum ExecutionStatus {
|
|
55
|
+
STATUS_UNSPECIFIED = "STATUS_UNSPECIFIED",
|
|
56
|
+
STATUS_STOPPED = "STATUS_STOPPED",
|
|
57
|
+
STATUS_SUCCEED = "STATUS_SUCCEED",
|
|
58
|
+
STATUS_FAILED = "STATUS_FAILED",
|
|
59
|
+
STATUS_IN_PROGRESS = "STATUS_IN_PROGRESS",
|
|
60
|
+
}
|
|
61
|
+
|
|
62
|
+
export enum ReplicationTaskOperation {
|
|
63
|
+
OPERATION_UNSPECIFIED = "OPERATION_UNSPECIFIED",
|
|
64
|
+
OPERATION_DELETE = "OPERATION_DELETE",
|
|
65
|
+
OPERATION_COPY = "OPERATION_COPY",
|
|
66
|
+
}
|
|
67
|
+
|
|
68
|
+
export enum ReplicationTaskStatus {
|
|
69
|
+
STATUS_UNSPECIFIED = "STATUS_UNSPECIFIED",
|
|
70
|
+
STATUS_STOPPED = "STATUS_STOPPED",
|
|
71
|
+
STATUS_SUCCEED = "STATUS_SUCCEED",
|
|
72
|
+
STATUS_FAILED = "STATUS_FAILED",
|
|
73
|
+
STATUS_PENDING = "STATUS_PENDING",
|
|
74
|
+
STATUS_IN_PROGRESS = "STATUS_IN_PROGRESS",
|
|
75
|
+
}
|
|
76
|
+
|
|
77
|
+
export type ListNativeRegistryRequest = {
|
|
78
|
+
registry?: string
|
|
79
|
+
page?: number
|
|
80
|
+
pageSize?: number
|
|
81
|
+
fuzzyName?: string
|
|
82
|
+
}
|
|
83
|
+
|
|
84
|
+
export type NativeRegistry = {
|
|
85
|
+
id?: string
|
|
86
|
+
type?: NativeRegistryType
|
|
87
|
+
name?: string
|
|
88
|
+
url?: string
|
|
89
|
+
nativeRegistryCredential?: NativeRegistryCredential
|
|
90
|
+
insecure?: boolean
|
|
91
|
+
description?: string
|
|
92
|
+
status?: NativeRegistryregistry_status
|
|
93
|
+
creationTime?: string
|
|
94
|
+
}
|
|
95
|
+
|
|
96
|
+
export type NativeRegistryCredential = {
|
|
97
|
+
accessKey?: string
|
|
98
|
+
accessSecret?: string
|
|
99
|
+
type?: NativeRegistryCredentialcredential_type
|
|
100
|
+
}
|
|
101
|
+
|
|
102
|
+
export type ListNativeRegistryResponse = {
|
|
103
|
+
items?: NativeRegistry[]
|
|
104
|
+
pagination?: KangarooIoApiTypesPage.Page
|
|
105
|
+
}
|
|
106
|
+
|
|
107
|
+
export type NativeRegistrySpec = {
|
|
108
|
+
type?: NativeRegistryType
|
|
109
|
+
name?: string
|
|
110
|
+
url?: string
|
|
111
|
+
nativeRegistryCredential?: NativeRegistryCredential
|
|
112
|
+
insecure?: boolean
|
|
113
|
+
description?: string
|
|
114
|
+
}
|
|
115
|
+
|
|
116
|
+
export type CreateNativeRegistryRequest = {
|
|
117
|
+
registry?: string
|
|
118
|
+
createType?: CreateNativeRegistryRequestType
|
|
119
|
+
integrationRegistry?: string[]
|
|
120
|
+
nativeRegistry?: NativeRegistrySpec
|
|
121
|
+
}
|
|
122
|
+
|
|
123
|
+
export type UpdateNativeRegistryRequest = {
|
|
124
|
+
registry?: string
|
|
125
|
+
nativeRegistryId?: string
|
|
126
|
+
nativeRegistry?: NativeRegistrySpec
|
|
127
|
+
}
|
|
128
|
+
|
|
129
|
+
export type DeleteNativeRegistryRequest = {
|
|
130
|
+
registry?: string
|
|
131
|
+
nativeRegistryId?: string
|
|
132
|
+
}
|
|
133
|
+
|
|
134
|
+
export type Policy = {
|
|
135
|
+
destRegistry?: NativeRegistry
|
|
136
|
+
srcRegistry?: NativeRegistry
|
|
137
|
+
enabled?: boolean
|
|
138
|
+
creationTime?: string
|
|
139
|
+
updateTime?: string
|
|
140
|
+
speed?: string
|
|
141
|
+
id?: string
|
|
142
|
+
override?: boolean
|
|
143
|
+
name?: string
|
|
144
|
+
description?: string
|
|
145
|
+
destNamespace?: string
|
|
146
|
+
filters?: Filter[]
|
|
147
|
+
trigger?: Trigger
|
|
148
|
+
}
|
|
149
|
+
|
|
150
|
+
export type Trigger = {
|
|
151
|
+
cron?: string
|
|
152
|
+
type?: TriggerMode
|
|
153
|
+
}
|
|
154
|
+
|
|
155
|
+
export type Filter = {
|
|
156
|
+
type?: FilterFilterType
|
|
157
|
+
value?: string
|
|
158
|
+
decoration?: FilterDecoration
|
|
159
|
+
}
|
|
160
|
+
|
|
161
|
+
export type ListPoliciesRequest = {
|
|
162
|
+
registry?: string
|
|
163
|
+
page?: number
|
|
164
|
+
pageSize?: number
|
|
165
|
+
fuzzyName?: string
|
|
166
|
+
}
|
|
167
|
+
|
|
168
|
+
export type ListPoliciesResponse = {
|
|
169
|
+
items?: Policy[]
|
|
170
|
+
pagination?: KangarooIoApiTypesPage.Page
|
|
171
|
+
}
|
|
172
|
+
|
|
173
|
+
export type DeletePolicyRequest = {
|
|
174
|
+
registry?: string
|
|
175
|
+
policyId?: string
|
|
176
|
+
}
|
|
177
|
+
|
|
178
|
+
export type CreateExecutionRequest = {
|
|
179
|
+
registry?: string
|
|
180
|
+
policyId?: string
|
|
181
|
+
}
|
|
182
|
+
|
|
183
|
+
export type StopExecutionRequest = {
|
|
184
|
+
registry?: string
|
|
185
|
+
executionId?: string
|
|
186
|
+
}
|
|
187
|
+
|
|
188
|
+
export type Execution = {
|
|
189
|
+
endTime?: string
|
|
190
|
+
failed?: string
|
|
191
|
+
id?: string
|
|
192
|
+
inProgress?: string
|
|
193
|
+
policyId?: string
|
|
194
|
+
startTime?: string
|
|
195
|
+
status?: ExecutionStatus
|
|
196
|
+
statusText?: string
|
|
197
|
+
stopped?: string
|
|
198
|
+
succeed?: string
|
|
199
|
+
total?: string
|
|
200
|
+
trigger?: TriggerMode
|
|
201
|
+
}
|
|
202
|
+
|
|
203
|
+
export type ListExecutionsRequest = {
|
|
204
|
+
registry?: string
|
|
205
|
+
page?: number
|
|
206
|
+
pageSize?: number
|
|
207
|
+
policyId?: string
|
|
208
|
+
status?: string
|
|
209
|
+
trigger?: string
|
|
210
|
+
}
|
|
211
|
+
|
|
212
|
+
export type ListExecutionsResponse = {
|
|
213
|
+
items?: Execution[]
|
|
214
|
+
pagination?: KangarooIoApiTypesPage.Page
|
|
215
|
+
}
|
|
216
|
+
|
|
217
|
+
export type CreatePolicyRequest = {
|
|
218
|
+
registry?: string
|
|
219
|
+
name?: string
|
|
220
|
+
description?: string
|
|
221
|
+
trigger?: Trigger
|
|
222
|
+
filters?: Filter[]
|
|
223
|
+
srcRegistryId?: string
|
|
224
|
+
destRegistryId?: string
|
|
225
|
+
enabled?: boolean
|
|
226
|
+
override?: boolean
|
|
227
|
+
destNamespace?: string
|
|
228
|
+
}
|
|
229
|
+
|
|
230
|
+
export type UpdatePolicyRequest = {
|
|
231
|
+
registry?: string
|
|
232
|
+
policyId?: string
|
|
233
|
+
name?: string
|
|
234
|
+
description?: string
|
|
235
|
+
trigger?: Trigger
|
|
236
|
+
filters?: Filter[]
|
|
237
|
+
srcRegistry?: NativeRegistry
|
|
238
|
+
destRegistry?: NativeRegistry
|
|
239
|
+
enabled?: boolean
|
|
240
|
+
override?: boolean
|
|
241
|
+
destNamespace?: string
|
|
242
|
+
}
|
|
243
|
+
|
|
244
|
+
export type GetExecutionRequest = {
|
|
245
|
+
registry?: string
|
|
246
|
+
executionId?: string
|
|
247
|
+
}
|
|
248
|
+
|
|
249
|
+
export type ListReplicationTasksRequest = {
|
|
250
|
+
registry?: string
|
|
251
|
+
executionId?: string
|
|
252
|
+
page?: number
|
|
253
|
+
pageSize?: number
|
|
254
|
+
resourceType?: string
|
|
255
|
+
status?: string
|
|
256
|
+
}
|
|
257
|
+
|
|
258
|
+
export type ListReplicationTasksResponse = {
|
|
259
|
+
items?: ReplicationTask[]
|
|
260
|
+
pagination?: KangarooIoApiTypesPage.Page
|
|
261
|
+
}
|
|
262
|
+
|
|
263
|
+
export type ReplicationTask = {
|
|
264
|
+
destResource?: string
|
|
265
|
+
endTime?: string
|
|
266
|
+
executionId?: string
|
|
267
|
+
id?: string
|
|
268
|
+
jobId?: string
|
|
269
|
+
operation?: ReplicationTaskOperation
|
|
270
|
+
resourceType?: string
|
|
271
|
+
srcResource?: string
|
|
272
|
+
startTime?: string
|
|
273
|
+
status?: ReplicationTaskStatus
|
|
274
|
+
}
|
|
275
|
+
|
|
276
|
+
export type GetReplicationTaskLogRequest = {
|
|
277
|
+
registry?: string
|
|
278
|
+
executionId?: string
|
|
279
|
+
taskId?: string
|
|
280
|
+
}
|
|
281
|
+
|
|
282
|
+
export type GetReplicationTaskLogResponse = {
|
|
283
|
+
log?: string
|
|
284
|
+
}
|
|
@@ -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 KangarooIoApiRegistryV1alpha1Registry from "./registry.pb"
|
|
10
|
+
import * as KangarooIoApiRegistryV1alpha1Replication from "./replication.pb"
|
|
10
11
|
export class Registries {
|
|
11
12
|
static CreateRegistry(req: KangarooIoApiRegistryV1alpha1Registry.CreateRegistryRequest, initReq?: fm.InitReq): Promise<KangarooIoApiRegistryV1alpha1Registry.Registry> {
|
|
12
13
|
return fm.fetchReq<KangarooIoApiRegistryV1alpha1Registry.CreateRegistryRequest, KangarooIoApiRegistryV1alpha1Registry.Registry>(`/apis/kangaroo.io/v1alpha1/registries`, {...initReq, method: "POST", body: JSON.stringify(req)})
|
|
@@ -47,4 +48,51 @@ export class Registries {
|
|
|
47
48
|
static GetStorageStatistic(req: KangarooIoApiRegistryV1alpha1Registry.GetStorageStatisticRequest, initReq?: fm.InitReq): Promise<KangarooIoApiRegistryV1alpha1Registry.GetStorageStatisticResponse> {
|
|
48
49
|
return fm.fetchReq<KangarooIoApiRegistryV1alpha1Registry.GetStorageStatisticRequest, KangarooIoApiRegistryV1alpha1Registry.GetStorageStatisticResponse>(`/apis/kangaroo.io/v1alpha1/registries/${req["registry"]}/storage_statistic?${fm.renderURLSearchParams(req, ["registry"])}`, {...initReq, method: "GET"})
|
|
49
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
|
+
}
|
|
55
|
+
export class Replications {
|
|
56
|
+
static ListNativeRegistry(req: KangarooIoApiRegistryV1alpha1Replication.ListNativeRegistryRequest, initReq?: fm.InitReq): Promise<KangarooIoApiRegistryV1alpha1Replication.ListNativeRegistryResponse> {
|
|
57
|
+
return fm.fetchReq<KangarooIoApiRegistryV1alpha1Replication.ListNativeRegistryRequest, KangarooIoApiRegistryV1alpha1Replication.ListNativeRegistryResponse>(`/apis/kangaroo.io/v1alpha1/registries/${req["registry"]}/native/registries?${fm.renderURLSearchParams(req, ["registry"])}`, {...initReq, method: "GET"})
|
|
58
|
+
}
|
|
59
|
+
static CreateNativeRegistry(req: KangarooIoApiRegistryV1alpha1Replication.CreateNativeRegistryRequest, initReq?: fm.InitReq): Promise<GoogleProtobufEmpty.Empty> {
|
|
60
|
+
return fm.fetchReq<KangarooIoApiRegistryV1alpha1Replication.CreateNativeRegistryRequest, GoogleProtobufEmpty.Empty>(`/apis/kangaroo.io/v1alpha1/registries/${req["registry"]}/native/registries`, {...initReq, method: "POST", body: JSON.stringify(req)})
|
|
61
|
+
}
|
|
62
|
+
static UpdateNativeRegistry(req: KangarooIoApiRegistryV1alpha1Replication.UpdateNativeRegistryRequest, initReq?: fm.InitReq): Promise<KangarooIoApiRegistryV1alpha1Replication.NativeRegistry> {
|
|
63
|
+
return fm.fetchReq<KangarooIoApiRegistryV1alpha1Replication.UpdateNativeRegistryRequest, KangarooIoApiRegistryV1alpha1Replication.NativeRegistry>(`/apis/kangaroo.io/v1alpha1/registries/${req["registry"]}/native/registries/${req["nativeRegistryId"]}`, {...initReq, method: "PUT", body: JSON.stringify(req)})
|
|
64
|
+
}
|
|
65
|
+
static DeleteNativeRegistry(req: KangarooIoApiRegistryV1alpha1Replication.DeleteNativeRegistryRequest, initReq?: fm.InitReq): Promise<GoogleProtobufEmpty.Empty> {
|
|
66
|
+
return fm.fetchReq<KangarooIoApiRegistryV1alpha1Replication.DeleteNativeRegistryRequest, GoogleProtobufEmpty.Empty>(`/apis/kangaroo.io/v1alpha1/registries/${req["registry"]}/native/registries/${req["nativeRegistryId"]}`, {...initReq, method: "DELETE"})
|
|
67
|
+
}
|
|
68
|
+
static ListPolicies(req: KangarooIoApiRegistryV1alpha1Replication.ListPoliciesRequest, initReq?: fm.InitReq): Promise<KangarooIoApiRegistryV1alpha1Replication.ListPoliciesResponse> {
|
|
69
|
+
return fm.fetchReq<KangarooIoApiRegistryV1alpha1Replication.ListPoliciesRequest, KangarooIoApiRegistryV1alpha1Replication.ListPoliciesResponse>(`/apis/kangaroo.io/v1alpha1/registries/${req["registry"]}/policies?${fm.renderURLSearchParams(req, ["registry"])}`, {...initReq, method: "GET"})
|
|
70
|
+
}
|
|
71
|
+
static DeletePolicy(req: KangarooIoApiRegistryV1alpha1Replication.DeletePolicyRequest, initReq?: fm.InitReq): Promise<GoogleProtobufEmpty.Empty> {
|
|
72
|
+
return fm.fetchReq<KangarooIoApiRegistryV1alpha1Replication.DeletePolicyRequest, GoogleProtobufEmpty.Empty>(`/apis/kangaroo.io/v1alpha1/registries/${req["registry"]}/policies/${req["policyId"]}`, {...initReq, method: "DELETE"})
|
|
73
|
+
}
|
|
74
|
+
static CreateExecution(req: KangarooIoApiRegistryV1alpha1Replication.CreateExecutionRequest, initReq?: fm.InitReq): Promise<GoogleProtobufEmpty.Empty> {
|
|
75
|
+
return fm.fetchReq<KangarooIoApiRegistryV1alpha1Replication.CreateExecutionRequest, GoogleProtobufEmpty.Empty>(`/apis/kangaroo.io/v1alpha1/registries/${req["registry"]}/executions`, {...initReq, method: "POST", body: JSON.stringify(req)})
|
|
76
|
+
}
|
|
77
|
+
static StopExecution(req: KangarooIoApiRegistryV1alpha1Replication.StopExecutionRequest, initReq?: fm.InitReq): Promise<GoogleProtobufEmpty.Empty> {
|
|
78
|
+
return fm.fetchReq<KangarooIoApiRegistryV1alpha1Replication.StopExecutionRequest, GoogleProtobufEmpty.Empty>(`/apis/kangaroo.io/v1alpha1/registries/${req["registry"]}/executions/${req["executionId"]}`, {...initReq, method: "PUT"})
|
|
79
|
+
}
|
|
80
|
+
static ListExecutions(req: KangarooIoApiRegistryV1alpha1Replication.ListExecutionsRequest, initReq?: fm.InitReq): Promise<KangarooIoApiRegistryV1alpha1Replication.ListExecutionsResponse> {
|
|
81
|
+
return fm.fetchReq<KangarooIoApiRegistryV1alpha1Replication.ListExecutionsRequest, KangarooIoApiRegistryV1alpha1Replication.ListExecutionsResponse>(`/apis/kangaroo.io/v1alpha1/registries/${req["registry"]}/executions?${fm.renderURLSearchParams(req, ["registry"])}`, {...initReq, method: "GET"})
|
|
82
|
+
}
|
|
83
|
+
static GetExecution(req: KangarooIoApiRegistryV1alpha1Replication.GetExecutionRequest, initReq?: fm.InitReq): Promise<KangarooIoApiRegistryV1alpha1Replication.Execution> {
|
|
84
|
+
return fm.fetchReq<KangarooIoApiRegistryV1alpha1Replication.GetExecutionRequest, KangarooIoApiRegistryV1alpha1Replication.Execution>(`/apis/kangaroo.io/v1alpha1/registries/${req["registry"]}/executions/${req["executionId"]}?${fm.renderURLSearchParams(req, ["registry", "executionId"])}`, {...initReq, method: "GET"})
|
|
85
|
+
}
|
|
86
|
+
static ListReplicationTasks(req: KangarooIoApiRegistryV1alpha1Replication.ListReplicationTasksRequest, initReq?: fm.InitReq): Promise<KangarooIoApiRegistryV1alpha1Replication.ListReplicationTasksResponse> {
|
|
87
|
+
return fm.fetchReq<KangarooIoApiRegistryV1alpha1Replication.ListReplicationTasksRequest, KangarooIoApiRegistryV1alpha1Replication.ListReplicationTasksResponse>(`/apis/kangaroo.io/v1alpha1/registries/${req["registry"]}/executions/${req["executionId"]}/tasks?${fm.renderURLSearchParams(req, ["registry", "executionId"])}`, {...initReq, method: "GET"})
|
|
88
|
+
}
|
|
89
|
+
static GetReplicationTasksLog(req: KangarooIoApiRegistryV1alpha1Replication.GetReplicationTaskLogRequest, initReq?: fm.InitReq): Promise<KangarooIoApiRegistryV1alpha1Replication.GetReplicationTaskLogResponse> {
|
|
90
|
+
return fm.fetchReq<KangarooIoApiRegistryV1alpha1Replication.GetReplicationTaskLogRequest, KangarooIoApiRegistryV1alpha1Replication.GetReplicationTaskLogResponse>(`/apis/kangaroo.io/v1alpha1/registries/${req["registry"]}/executions/${req["executionId"]}/tasks/${req["taskId"]}/log?${fm.renderURLSearchParams(req, ["registry", "executionId", "taskId"])}`, {...initReq, method: "GET"})
|
|
91
|
+
}
|
|
92
|
+
static CreatePolicy(req: KangarooIoApiRegistryV1alpha1Replication.CreatePolicyRequest, initReq?: fm.InitReq): Promise<GoogleProtobufEmpty.Empty> {
|
|
93
|
+
return fm.fetchReq<KangarooIoApiRegistryV1alpha1Replication.CreatePolicyRequest, GoogleProtobufEmpty.Empty>(`/apis/kangaroo.io/v1alpha1/registries/${req["registry"]}/policies`, {...initReq, method: "POST", body: JSON.stringify(req)})
|
|
94
|
+
}
|
|
95
|
+
static UpdatePolicy(req: KangarooIoApiRegistryV1alpha1Replication.UpdatePolicyRequest, initReq?: fm.InitReq): Promise<GoogleProtobufEmpty.Empty> {
|
|
96
|
+
return fm.fetchReq<KangarooIoApiRegistryV1alpha1Replication.UpdatePolicyRequest, GoogleProtobufEmpty.Empty>(`/apis/kangaroo.io/v1alpha1/registries/${req["registry"]}/policies/${req["policyId"]}`, {...initReq, method: "PUT", body: JSON.stringify(req)})
|
|
97
|
+
}
|
|
50
98
|
}
|
|
@@ -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 Image {
|
|
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
|
+
}
|