@flowcore/cli-plugin-iam 1.6.1 → 1.7.0
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/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,13 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
+
## [1.7.0](https://github.com/flowcore-io/cli-plugin-iam/compare/v1.6.1...v1.7.0) (2025-05-01)
|
|
4
|
+
|
|
5
|
+
|
|
6
|
+
### Features
|
|
7
|
+
|
|
8
|
+
* **policy:** :art: update policy action validation to support string union ([e16d95b](https://github.com/flowcore-io/cli-plugin-iam/commit/e16d95bfeaeaf74e32b41116a92790c85ca6be36))
|
|
9
|
+
* **policy:** :sparkles: add SENSITIVE_DATA_FETCH action to policy document ([6026408](https://github.com/flowcore-io/cli-plugin-iam/commit/60264082133c149e4d1fc78606ee2b0cb0cced4a))
|
|
10
|
+
|
|
3
11
|
## [1.6.1](https://github.com/flowcore-io/cli-plugin-iam/compare/v1.6.0...v1.6.1) (2025-03-20)
|
|
4
12
|
|
|
5
13
|
|
package/README.md
CHANGED
|
@@ -18,7 +18,7 @@ $ npm install -g @flowcore/cli-plugin-iam
|
|
|
18
18
|
$ iam COMMAND
|
|
19
19
|
running command...
|
|
20
20
|
$ iam (--version)
|
|
21
|
-
@flowcore/cli-plugin-iam/1.
|
|
21
|
+
@flowcore/cli-plugin-iam/1.7.0 linux-x64 node-v20.16.0
|
|
22
22
|
$ iam --help [COMMAND]
|
|
23
23
|
USAGE
|
|
24
24
|
$ iam COMMAND
|
|
@@ -55,7 +55,7 @@ DESCRIPTION
|
|
|
55
55
|
Delete a policy
|
|
56
56
|
```
|
|
57
57
|
|
|
58
|
-
_See code: [src/commands/delete/policy.ts](https://github.com/flowcore-io/cli-plugin-iam/blob/v1.
|
|
58
|
+
_See code: [src/commands/delete/policy.ts](https://github.com/flowcore-io/cli-plugin-iam/blob/v1.7.0/src/commands/delete/policy.ts)_
|
|
59
59
|
|
|
60
60
|
## `iam delete role NAME`
|
|
61
61
|
|
|
@@ -78,7 +78,7 @@ DESCRIPTION
|
|
|
78
78
|
Delete a role
|
|
79
79
|
```
|
|
80
80
|
|
|
81
|
-
_See code: [src/commands/delete/role.ts](https://github.com/flowcore-io/cli-plugin-iam/blob/v1.
|
|
81
|
+
_See code: [src/commands/delete/role.ts](https://github.com/flowcore-io/cli-plugin-iam/blob/v1.7.0/src/commands/delete/role.ts)_
|
|
82
82
|
|
|
83
83
|
## `iam edit policy NAME`
|
|
84
84
|
|
|
@@ -104,7 +104,7 @@ EXAMPLES
|
|
|
104
104
|
$ FC_EDITOR=code flowcore iam edit policy my-policy -t my-tenant
|
|
105
105
|
```
|
|
106
106
|
|
|
107
|
-
_See code: [src/commands/edit/policy.ts](https://github.com/flowcore-io/cli-plugin-iam/blob/v1.
|
|
107
|
+
_See code: [src/commands/edit/policy.ts](https://github.com/flowcore-io/cli-plugin-iam/blob/v1.7.0/src/commands/edit/policy.ts)_
|
|
108
108
|
|
|
109
109
|
## `iam edit role NAME`
|
|
110
110
|
|
|
@@ -130,7 +130,7 @@ EXAMPLES
|
|
|
130
130
|
$ FC_EDITOR=code flowcore iam edit role my-role -t my-tenant
|
|
131
131
|
```
|
|
132
132
|
|
|
133
|
-
_See code: [src/commands/edit/role.ts](https://github.com/flowcore-io/cli-plugin-iam/blob/v1.
|
|
133
|
+
_See code: [src/commands/edit/role.ts](https://github.com/flowcore-io/cli-plugin-iam/blob/v1.7.0/src/commands/edit/role.ts)_
|
|
134
134
|
|
|
135
135
|
## `iam get policy [NAME]`
|
|
136
136
|
|
|
@@ -153,7 +153,7 @@ DESCRIPTION
|
|
|
153
153
|
Get a policy
|
|
154
154
|
```
|
|
155
155
|
|
|
156
|
-
_See code: [src/commands/get/policy.ts](https://github.com/flowcore-io/cli-plugin-iam/blob/v1.
|
|
156
|
+
_See code: [src/commands/get/policy.ts](https://github.com/flowcore-io/cli-plugin-iam/blob/v1.7.0/src/commands/get/policy.ts)_
|
|
157
157
|
|
|
158
158
|
## `iam get role [NAME]`
|
|
159
159
|
|
|
@@ -176,5 +176,5 @@ DESCRIPTION
|
|
|
176
176
|
Get a role
|
|
177
177
|
```
|
|
178
178
|
|
|
179
|
-
_See code: [src/commands/get/role.ts](https://github.com/flowcore-io/cli-plugin-iam/blob/v1.
|
|
179
|
+
_See code: [src/commands/get/role.ts](https://github.com/flowcore-io/cli-plugin-iam/blob/v1.7.0/src/commands/get/role.ts)_
|
|
180
180
|
<!-- commandsstop -->
|
|
@@ -6,6 +6,7 @@ export declare enum PolicyDocumentAction {
|
|
|
6
6
|
FETCH = "fetch",
|
|
7
7
|
INGEST = "ingest",
|
|
8
8
|
READ = "read",
|
|
9
|
+
SENSITIVE_DATA_FETCH = "sensitive-data-fetch",
|
|
9
10
|
WRITE = "write"
|
|
10
11
|
}
|
|
11
12
|
export declare const policyDto: z.ZodObject<z.objectUtil.extendShape<{
|
|
@@ -26,15 +27,15 @@ export declare const policyDto: z.ZodObject<z.objectUtil.extendShape<{
|
|
|
26
27
|
description: z.ZodOptional<z.ZodString>;
|
|
27
28
|
flowcoreManaged: z.ZodOptional<z.ZodBoolean>;
|
|
28
29
|
policyDocuments: z.ZodArray<z.ZodObject<{
|
|
29
|
-
action: z.ZodUnion<[z.ZodArray<z.ZodNativeEnum<typeof PolicyDocumentAction>, "many">, z.ZodNativeEnum<typeof PolicyDocumentAction>]>;
|
|
30
|
+
action: z.ZodUnion<[z.ZodArray<z.ZodUnion<[z.ZodNativeEnum<typeof PolicyDocumentAction>, z.ZodString]>, "many">, z.ZodUnion<[z.ZodNativeEnum<typeof PolicyDocumentAction>, z.ZodString]>]>;
|
|
30
31
|
resource: z.ZodString;
|
|
31
32
|
statementId: z.ZodOptional<z.ZodString>;
|
|
32
33
|
}, "strip", z.ZodTypeAny, {
|
|
33
|
-
action:
|
|
34
|
+
action: string | string[];
|
|
34
35
|
resource: string;
|
|
35
36
|
statementId?: string | undefined;
|
|
36
37
|
}, {
|
|
37
|
-
action:
|
|
38
|
+
action: string | string[];
|
|
38
39
|
resource: string;
|
|
39
40
|
statementId?: string | undefined;
|
|
40
41
|
}>, "many">;
|
|
@@ -43,7 +44,7 @@ export declare const policyDto: z.ZodObject<z.objectUtil.extendShape<{
|
|
|
43
44
|
}, "strip", z.ZodTypeAny, {
|
|
44
45
|
version: string;
|
|
45
46
|
policyDocuments: {
|
|
46
|
-
action:
|
|
47
|
+
action: string | string[];
|
|
47
48
|
resource: string;
|
|
48
49
|
statementId?: string | undefined;
|
|
49
50
|
}[];
|
|
@@ -53,7 +54,7 @@ export declare const policyDto: z.ZodObject<z.objectUtil.extendShape<{
|
|
|
53
54
|
}, {
|
|
54
55
|
version: string;
|
|
55
56
|
policyDocuments: {
|
|
56
|
-
action:
|
|
57
|
+
action: string | string[];
|
|
57
58
|
resource: string;
|
|
58
59
|
statementId?: string | undefined;
|
|
59
60
|
}[];
|
|
@@ -71,7 +72,7 @@ export declare const policyDto: z.ZodObject<z.objectUtil.extendShape<{
|
|
|
71
72
|
spec: {
|
|
72
73
|
version: string;
|
|
73
74
|
policyDocuments: {
|
|
74
|
-
action:
|
|
75
|
+
action: string | string[];
|
|
75
76
|
resource: string;
|
|
76
77
|
statementId?: string | undefined;
|
|
77
78
|
}[];
|
|
@@ -89,7 +90,7 @@ export declare const policyDto: z.ZodObject<z.objectUtil.extendShape<{
|
|
|
89
90
|
spec: {
|
|
90
91
|
version: string;
|
|
91
92
|
policyDocuments: {
|
|
92
|
-
action:
|
|
93
|
+
action: string | string[];
|
|
93
94
|
resource: string;
|
|
94
95
|
statementId?: string | undefined;
|
|
95
96
|
}[];
|
|
@@ -2,6 +2,7 @@ import { baseResourceDto } from "@flowcore/cli-plugin-core";
|
|
|
2
2
|
import { diff } from "@opentf/obj-diff";
|
|
3
3
|
import enquirer from "enquirer";
|
|
4
4
|
import { diffString } from "json-diff";
|
|
5
|
+
import { inspect } from "node:util";
|
|
5
6
|
import { omit } from "radash";
|
|
6
7
|
import { z } from "zod";
|
|
7
8
|
export var PolicyDocumentAction;
|
|
@@ -10,6 +11,7 @@ export var PolicyDocumentAction;
|
|
|
10
11
|
PolicyDocumentAction["FETCH"] = "fetch";
|
|
11
12
|
PolicyDocumentAction["INGEST"] = "ingest";
|
|
12
13
|
PolicyDocumentAction["READ"] = "read";
|
|
14
|
+
PolicyDocumentAction["SENSITIVE_DATA_FETCH"] = "sensitive-data-fetch";
|
|
13
15
|
PolicyDocumentAction["WRITE"] = "write";
|
|
14
16
|
})(PolicyDocumentAction || (PolicyDocumentAction = {}));
|
|
15
17
|
export const policyDto = baseResourceDto.extend({
|
|
@@ -18,8 +20,8 @@ export const policyDto = baseResourceDto.extend({
|
|
|
18
20
|
flowcoreManaged: z.boolean().optional(),
|
|
19
21
|
policyDocuments: z.array(z.object({
|
|
20
22
|
action: z
|
|
21
|
-
.array(z.nativeEnum(PolicyDocumentAction))
|
|
22
|
-
.or(z.nativeEnum(PolicyDocumentAction)),
|
|
23
|
+
.array(z.union([z.nativeEnum(PolicyDocumentAction), z.string()]))
|
|
24
|
+
.or(z.union([z.nativeEnum(PolicyDocumentAction), z.string()])),
|
|
23
25
|
resource: z.string(),
|
|
24
26
|
statementId: z.string().optional(),
|
|
25
27
|
})),
|
|
@@ -119,6 +121,7 @@ export class PolicyService {
|
|
|
119
121
|
this.logger.fatal(`Failed to create policy with error(${err.error.status} - ${err.error.code}): ${err.error.message}`);
|
|
120
122
|
}
|
|
121
123
|
else {
|
|
124
|
+
console.log(`Error: ${error}`, inspect(error, { depth: null }));
|
|
122
125
|
this.logger.fatal(`Failed to create policy with unknown error: ${error}`);
|
|
123
126
|
}
|
|
124
127
|
}
|
package/oclif.manifest.json
CHANGED
package/package.json
CHANGED
|
@@ -91,7 +91,7 @@
|
|
|
91
91
|
"version": "oclif readme && git add README.md",
|
|
92
92
|
"update-schema": "rover graph introspect https://graph.api.flowcore.io/graphql -o schema.gql"
|
|
93
93
|
},
|
|
94
|
-
"version": "1.
|
|
94
|
+
"version": "1.7.0",
|
|
95
95
|
"bugs": "https://github.com/flowcore-io/cli-plugin-iam/issues",
|
|
96
96
|
"keywords": [
|
|
97
97
|
"oclif"
|