Skip to content

Commit c670ae2

Browse files
authored
Create account: Add support for creating accounts of different resource types (#608)
Previously, we assumed only one resource syncer would implement CreateAccount. If no resource type is specified and there's only one account manager, we use that. So this should not break backwards compatibility.
1 parent e844d1b commit c670ae2

File tree

17 files changed

+209
-54
lines changed

17 files changed

+209
-54
lines changed

pb/c1/connector/v2/resource.pb.go

Lines changed: 18 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

pb/c1/connector/v2/resource.pb.validate.go

Lines changed: 15 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

pb/c1/connector/v2/resource_protoopaque.pb.go

Lines changed: 18 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

pb/c1/connectorapi/baton/v1/baton.pb.go

Lines changed: 19 additions & 3 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

pb/c1/connectorapi/baton/v1/baton.pb.validate.go

Lines changed: 15 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

pb/c1/connectorapi/baton/v1/baton_protoopaque.pb.go

Lines changed: 19 additions & 3 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

pkg/cli/commands.go

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -234,6 +234,7 @@ func MakeMainCommand[T field.Configurable](
234234
login,
235235
email,
236236
profile,
237+
v.GetString("create-account-resource-type"),
237238
))
238239
case v.GetString("create-account-login") != "":
239240
// should only be here if no create-account-profile is provided, so lets make one.
@@ -251,6 +252,7 @@ func MakeMainCommand[T field.Configurable](
251252
v.GetString("create-account-login"),
252253
v.GetString("create-account-email"),
253254
profile,
255+
v.GetString("create-account-resource-type"),
254256
))
255257
case v.GetString("invoke-action") != "":
256258
invokeActionArgsStr := v.GetString("invoke-action-args")

0 commit comments

Comments
 (0)