@contrail/cli 3.4.6-alpha.c203463 → 3.4.6-alpha.f8f859e
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/README.md +1 -1
- package/dist/commands/groups/import.js +7 -4
- package/oclif.manifest.json +1 -1
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -17,7 +17,7 @@ $ npm install -g @contrail/cli
|
|
|
17
17
|
$ contrail COMMAND
|
|
18
18
|
running command...
|
|
19
19
|
$ contrail (--version)
|
|
20
|
-
@contrail/cli/3.4.6-alpha.
|
|
20
|
+
@contrail/cli/3.4.6-alpha.f8f859e linux-x64 node-v20.20.2
|
|
21
21
|
$ contrail --help [COMMAND]
|
|
22
22
|
USAGE
|
|
23
23
|
$ contrail COMMAND
|
|
@@ -152,17 +152,20 @@ async function updateGroup(principals, orgUsers, existingGroup, allGroupsAfterCr
|
|
|
152
152
|
}
|
|
153
153
|
}
|
|
154
154
|
async function createGroupPrincipals(group, principals, orgUsers, allGroupsAfterCreate) {
|
|
155
|
-
const
|
|
155
|
+
const principalReferences = principals
|
|
156
156
|
.map((x) => groupPrincipalNameToId(x, allGroupsAfterCreate, orgUsers))
|
|
157
157
|
.filter((x) => !!x)
|
|
158
158
|
.map((x) => {
|
|
159
|
-
return
|
|
159
|
+
return `${x.type}:${x.identifier}`;
|
|
160
160
|
});
|
|
161
|
-
if (
|
|
161
|
+
if (principalReferences.length) {
|
|
162
162
|
try {
|
|
163
163
|
await new sdk_1.Entities().batchCreate({
|
|
164
164
|
entityName: 'group-principal',
|
|
165
|
-
objects:
|
|
165
|
+
objects: {
|
|
166
|
+
principalReferences,
|
|
167
|
+
groupIds: [group.id],
|
|
168
|
+
},
|
|
166
169
|
});
|
|
167
170
|
}
|
|
168
171
|
catch (e) {
|
package/oclif.manifest.json
CHANGED