@jfvilas/kwirth-common 0.4.2 → 0.4.3
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/AccessKey.d.ts +6 -6
- package/dist/AccessKey.js +7 -7
- package/package.json +1 -1
package/dist/AccessKey.d.ts
CHANGED
|
@@ -9,12 +9,12 @@ declare function accessKeySerialize(accessKey: AccessKey): string;
|
|
|
9
9
|
declare function accessKeyDeserialize(key: string): AccessKey;
|
|
10
10
|
declare function parseResource(key: string): ResourceIdentifier;
|
|
11
11
|
declare function parseResources(key: string): ResourceIdentifier[];
|
|
12
|
-
declare function buildResource(scopes: string[], namespaces: string[],
|
|
12
|
+
declare function buildResource(scopes: string[], namespaces: string[], groups: string[], pods: string[], containers: string[]): string;
|
|
13
13
|
interface ResourceIdentifier {
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
14
|
+
scopes: string;
|
|
15
|
+
namespaces: string;
|
|
16
|
+
groups: string;
|
|
17
|
+
pods: string;
|
|
18
|
+
containers: string;
|
|
19
19
|
}
|
|
20
20
|
export { accessKeyBuild, accessKeyCreate, accessKeyDeserialize, accessKeySerialize, AccessKey, parseResource, parseResources, ResourceIdentifier, buildResource };
|
package/dist/AccessKey.js
CHANGED
|
@@ -53,11 +53,11 @@ exports.accessKeyDeserialize = accessKeyDeserialize;
|
|
|
53
53
|
function parseResource(key) {
|
|
54
54
|
var parts = key.split(':');
|
|
55
55
|
return {
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
56
|
+
scopes: parts[0],
|
|
57
|
+
namespaces: parts[1],
|
|
58
|
+
groups: parts[2],
|
|
59
|
+
pods: parts[3],
|
|
60
|
+
containers: parts[4]
|
|
61
61
|
};
|
|
62
62
|
}
|
|
63
63
|
exports.parseResource = parseResource;
|
|
@@ -70,7 +70,7 @@ function parseResources(key) {
|
|
|
70
70
|
return result;
|
|
71
71
|
}
|
|
72
72
|
exports.parseResources = parseResources;
|
|
73
|
-
function buildResource(scopes, namespaces,
|
|
74
|
-
return `${scopes.join(',')}:${namespaces.join(',')}:${
|
|
73
|
+
function buildResource(scopes, namespaces, groups, pods, containers) {
|
|
74
|
+
return `${scopes.join(',')}:${namespaces.join(',')}:${groups.join(',')}:${pods.join(',')}:${containers.join(',')}`;
|
|
75
75
|
}
|
|
76
76
|
exports.buildResource = buildResource;
|