@serve.zone/interfaces 1.0.16 → 1.0.19
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/dist_ts/00_commitinfo_data.js +1 -1
- package/dist_ts/data/cluster.d.ts +9 -2
- package/dist_ts/data/secret.d.ts +4 -1
- package/dist_ts/requests/cluster.d.ts +13 -4
- package/dist_ts/requests/config.d.ts +3 -3
- package/package.json +1 -1
- package/ts/00_commitinfo_data.ts +1 -1
- package/ts/data/cluster.ts +12 -2
- package/ts/data/secret.ts +6 -1
- package/ts/requests/cluster.ts +17 -4
- package/ts/requests/config.ts +3 -3
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
*/
|
|
4
4
|
export const commitinfo = {
|
|
5
5
|
name: '@serve.zone/interfaces',
|
|
6
|
-
version: '1.0.
|
|
6
|
+
version: '1.0.19',
|
|
7
7
|
description: 'interfaces for working with containers'
|
|
8
8
|
};
|
|
9
9
|
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiMDBfY29tbWl0aW5mb19kYXRhLmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiLi4vdHMvMDBfY29tbWl0aW5mb19kYXRhLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiJBQUFBOztHQUVHO0FBQ0gsTUFBTSxDQUFDLE1BQU0sVUFBVSxHQUFHO0lBQ3hCLElBQUksRUFBRSx3QkFBd0I7SUFDOUIsT0FBTyxFQUFFLFFBQVE7SUFDakIsV0FBVyxFQUFFLHdDQUF3QztDQUN0RCxDQUFBIn0=
|
|
@@ -4,12 +4,16 @@ export interface IClusterIdentifier {
|
|
|
4
4
|
clusterName: string;
|
|
5
5
|
secretKey: string;
|
|
6
6
|
}
|
|
7
|
-
export interface
|
|
7
|
+
export interface ICluster {
|
|
8
8
|
id: string;
|
|
9
9
|
data: {
|
|
10
10
|
name: string;
|
|
11
11
|
secretKey: string;
|
|
12
12
|
jumpCode: string;
|
|
13
|
+
/**
|
|
14
|
+
* when was the jump code used
|
|
15
|
+
* avoid replay attacks
|
|
16
|
+
*/
|
|
13
17
|
jumpCodeUsedAt: number;
|
|
14
18
|
/**
|
|
15
19
|
* how can the cluster reach cloudly
|
|
@@ -24,12 +28,15 @@ export interface IClusterConfig {
|
|
|
24
28
|
*/
|
|
25
29
|
containers: IClusterConfigContainer[];
|
|
26
30
|
/**
|
|
27
|
-
*
|
|
31
|
+
* ACME info. This is used to get SSL certificates.
|
|
28
32
|
*/
|
|
29
33
|
acmeInfo: {
|
|
30
34
|
serverAddress: string;
|
|
31
35
|
serverSecret: string;
|
|
32
36
|
};
|
|
37
|
+
/**
|
|
38
|
+
* Where to get the images from
|
|
39
|
+
*/
|
|
33
40
|
registryInfo: IDockerRegistryInfo;
|
|
34
41
|
};
|
|
35
42
|
}
|
package/dist_ts/data/secret.d.ts
CHANGED
|
@@ -4,6 +4,8 @@ export interface ISecretGroup {
|
|
|
4
4
|
*/
|
|
5
5
|
id: string;
|
|
6
6
|
data: {
|
|
7
|
+
name: string;
|
|
8
|
+
description: string;
|
|
7
9
|
/**
|
|
8
10
|
* the key of the secretgroup like CI_RUNNER_TOKEN
|
|
9
11
|
*/
|
|
@@ -47,7 +49,8 @@ export interface ISecretGroup {
|
|
|
47
49
|
export interface ISecretBundle {
|
|
48
50
|
id: string;
|
|
49
51
|
data: {
|
|
50
|
-
|
|
52
|
+
name: string;
|
|
53
|
+
description: string;
|
|
51
54
|
/**
|
|
52
55
|
* You can add specific secret groups using this
|
|
53
56
|
*/
|
|
@@ -1,5 +1,14 @@
|
|
|
1
|
-
import type {
|
|
1
|
+
import type { ICluster } from '../data/cluster.js';
|
|
2
2
|
import * as plugins from '../plugins.js';
|
|
3
|
+
export interface IRequest_GetAllClusters extends plugins.typedrequestInterfaces.implementsTR<plugins.typedrequestInterfaces.ITypedRequest, IRequest_GetAllClusters> {
|
|
4
|
+
method: 'getAllClusters';
|
|
5
|
+
request: {
|
|
6
|
+
jwt: string;
|
|
7
|
+
};
|
|
8
|
+
response: {
|
|
9
|
+
clusters: ICluster[];
|
|
10
|
+
};
|
|
11
|
+
}
|
|
3
12
|
export interface IRequest_CreateCluster extends plugins.typedrequestInterfaces.implementsTR<plugins.typedrequestInterfaces.ITypedRequest, IRequest_CreateCluster> {
|
|
4
13
|
method: 'createCluster';
|
|
5
14
|
request: {
|
|
@@ -7,16 +16,16 @@ export interface IRequest_CreateCluster extends plugins.typedrequestInterfaces.i
|
|
|
7
16
|
clusterName: string;
|
|
8
17
|
};
|
|
9
18
|
response: {
|
|
10
|
-
clusterConfig:
|
|
19
|
+
clusterConfig: ICluster;
|
|
11
20
|
};
|
|
12
21
|
}
|
|
13
22
|
export interface IRequest_UpdateCluster extends plugins.typedrequestInterfaces.implementsTR<plugins.typedrequestInterfaces.ITypedRequest, IRequest_UpdateCluster> {
|
|
14
23
|
method: 'updateCluster';
|
|
15
24
|
request: {
|
|
16
25
|
jwt: string;
|
|
17
|
-
clusterConfig:
|
|
26
|
+
clusterConfig: ICluster;
|
|
18
27
|
};
|
|
19
28
|
response: {
|
|
20
|
-
clusterConfig:
|
|
29
|
+
clusterConfig: ICluster;
|
|
21
30
|
};
|
|
22
31
|
}
|
|
@@ -16,20 +16,20 @@ export interface IRequest_Any_Cloudly_GetClusterConfig extends plugins.typedrequ
|
|
|
16
16
|
clusterIdentifier: clusterInterfaces.IClusterIdentifier;
|
|
17
17
|
};
|
|
18
18
|
response: {
|
|
19
|
-
configData: clusterInterfaces.
|
|
19
|
+
configData: clusterInterfaces.ICluster;
|
|
20
20
|
};
|
|
21
21
|
}
|
|
22
22
|
export interface IRequest_Cloudly_Coreflow_PushClusterConfig extends plugins.typedrequestInterfaces.implementsTR<plugins.typedrequestInterfaces.ITypedRequest, IRequest_Cloudly_Coreflow_PushClusterConfig> {
|
|
23
23
|
method: 'pushClusterConfig';
|
|
24
24
|
request: {
|
|
25
|
-
configData: clusterInterfaces.
|
|
25
|
+
configData: clusterInterfaces.ICluster;
|
|
26
26
|
};
|
|
27
27
|
response: {};
|
|
28
28
|
}
|
|
29
29
|
export interface IRequest_Cloudly_Coreflow_PushContainerUpdate extends plugins.typedrequestInterfaces.implementsTR<plugins.typedrequestInterfaces.ITypedRequest, IRequest_Cloudly_Coreflow_PushContainerUpdate> {
|
|
30
30
|
method: 'pushContainerUpdate';
|
|
31
31
|
request: {
|
|
32
|
-
configData: clusterInterfaces.
|
|
32
|
+
configData: clusterInterfaces.ICluster;
|
|
33
33
|
specificContainerConfigToUpdate: clusterInterfaces.IClusterConfigContainer;
|
|
34
34
|
};
|
|
35
35
|
response: {};
|
package/package.json
CHANGED
package/ts/00_commitinfo_data.ts
CHANGED
package/ts/data/cluster.ts
CHANGED
|
@@ -6,13 +6,19 @@ export interface IClusterIdentifier {
|
|
|
6
6
|
secretKey: string;
|
|
7
7
|
}
|
|
8
8
|
|
|
9
|
-
export interface
|
|
9
|
+
export interface ICluster {
|
|
10
10
|
id: string;
|
|
11
11
|
data: {
|
|
12
12
|
name: string;
|
|
13
13
|
secretKey: string;
|
|
14
14
|
jumpCode: string;
|
|
15
|
+
|
|
16
|
+
/**
|
|
17
|
+
* when was the jump code used
|
|
18
|
+
* avoid replay attacks
|
|
19
|
+
*/
|
|
15
20
|
jumpCodeUsedAt: number;
|
|
21
|
+
|
|
16
22
|
/**
|
|
17
23
|
* how can the cluster reach cloudly
|
|
18
24
|
*/
|
|
@@ -29,12 +35,16 @@ export interface IClusterConfig {
|
|
|
29
35
|
containers: IClusterConfigContainer[];
|
|
30
36
|
|
|
31
37
|
/**
|
|
32
|
-
*
|
|
38
|
+
* ACME info. This is used to get SSL certificates.
|
|
33
39
|
*/
|
|
34
40
|
acmeInfo: {
|
|
35
41
|
serverAddress: string;
|
|
36
42
|
serverSecret: string;
|
|
37
43
|
};
|
|
44
|
+
|
|
45
|
+
/**
|
|
46
|
+
* Where to get the images from
|
|
47
|
+
*/
|
|
38
48
|
registryInfo: IDockerRegistryInfo;
|
|
39
49
|
};
|
|
40
50
|
}
|
package/ts/data/secret.ts
CHANGED
|
@@ -5,6 +5,9 @@ export interface ISecretGroup {
|
|
|
5
5
|
id: string;
|
|
6
6
|
|
|
7
7
|
data: {
|
|
8
|
+
name: string;
|
|
9
|
+
description: string;
|
|
10
|
+
|
|
8
11
|
/**
|
|
9
12
|
* the key of the secretgroup like CI_RUNNER_TOKEN
|
|
10
13
|
*/
|
|
@@ -53,7 +56,9 @@ export interface ISecretGroup {
|
|
|
53
56
|
export interface ISecretBundle {
|
|
54
57
|
id: string;
|
|
55
58
|
data: {
|
|
56
|
-
|
|
59
|
+
name: string;
|
|
60
|
+
description: string;
|
|
61
|
+
|
|
57
62
|
/**
|
|
58
63
|
* You can add specific secret groups using this
|
|
59
64
|
*/
|
package/ts/requests/cluster.ts
CHANGED
|
@@ -1,6 +1,19 @@
|
|
|
1
|
-
import type {
|
|
1
|
+
import type { ICluster } from '../data/cluster.js';
|
|
2
2
|
import * as plugins from '../plugins.js';
|
|
3
3
|
|
|
4
|
+
export interface IRequest_GetAllClusters extends plugins.typedrequestInterfaces.implementsTR<
|
|
5
|
+
plugins.typedrequestInterfaces.ITypedRequest,
|
|
6
|
+
IRequest_GetAllClusters
|
|
7
|
+
> {
|
|
8
|
+
method: 'getAllClusters';
|
|
9
|
+
request: {
|
|
10
|
+
jwt: string;
|
|
11
|
+
};
|
|
12
|
+
response: {
|
|
13
|
+
clusters: ICluster[];
|
|
14
|
+
};
|
|
15
|
+
}
|
|
16
|
+
|
|
4
17
|
export interface IRequest_CreateCluster extends plugins.typedrequestInterfaces.implementsTR<
|
|
5
18
|
plugins.typedrequestInterfaces.ITypedRequest,
|
|
6
19
|
IRequest_CreateCluster
|
|
@@ -11,7 +24,7 @@ export interface IRequest_CreateCluster extends plugins.typedrequestInterfaces.i
|
|
|
11
24
|
clusterName: string;
|
|
12
25
|
};
|
|
13
26
|
response: {
|
|
14
|
-
clusterConfig:
|
|
27
|
+
clusterConfig: ICluster;
|
|
15
28
|
};
|
|
16
29
|
}
|
|
17
30
|
|
|
@@ -22,9 +35,9 @@ export interface IRequest_UpdateCluster extends plugins.typedrequestInterfaces.i
|
|
|
22
35
|
method: 'updateCluster';
|
|
23
36
|
request: {
|
|
24
37
|
jwt: string;
|
|
25
|
-
clusterConfig:
|
|
38
|
+
clusterConfig: ICluster;
|
|
26
39
|
};
|
|
27
40
|
response: {
|
|
28
|
-
clusterConfig:
|
|
41
|
+
clusterConfig: ICluster;
|
|
29
42
|
};
|
|
30
43
|
}
|
package/ts/requests/config.ts
CHANGED
|
@@ -26,7 +26,7 @@ extends plugins.typedrequestInterfaces.implementsTR<
|
|
|
26
26
|
clusterIdentifier: clusterInterfaces.IClusterIdentifier;
|
|
27
27
|
};
|
|
28
28
|
response: {
|
|
29
|
-
configData: clusterInterfaces.
|
|
29
|
+
configData: clusterInterfaces.ICluster;
|
|
30
30
|
};
|
|
31
31
|
}
|
|
32
32
|
|
|
@@ -37,7 +37,7 @@ extends plugins.typedrequestInterfaces.implementsTR<
|
|
|
37
37
|
> {
|
|
38
38
|
method: 'pushClusterConfig';
|
|
39
39
|
request: {
|
|
40
|
-
configData: clusterInterfaces.
|
|
40
|
+
configData: clusterInterfaces.ICluster;
|
|
41
41
|
};
|
|
42
42
|
response: {};
|
|
43
43
|
}
|
|
@@ -49,7 +49,7 @@ extends plugins.typedrequestInterfaces.implementsTR<
|
|
|
49
49
|
> {
|
|
50
50
|
method: 'pushContainerUpdate'
|
|
51
51
|
request: {
|
|
52
|
-
configData: clusterInterfaces.
|
|
52
|
+
configData: clusterInterfaces.ICluster;
|
|
53
53
|
specificContainerConfigToUpdate: clusterInterfaces.IClusterConfigContainer;
|
|
54
54
|
};
|
|
55
55
|
response: {}
|