Skip to content

Commit 8c537cf

Browse files
authored
feat(auto-onboarding): Allow auto-onboarding on organizations (#951)
Signed-off-by: Javier Rodriguez <[email protected]>
1 parent 3208b5e commit 8c537cf

File tree

24 files changed

+723
-267
lines changed

24 files changed

+723
-267
lines changed

Makefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ api:
1313
.PHONY: config
1414
# generate config proto
1515
config:
16-
cd ./internal/credentials/api && buf generate
16+
cd ./pkg/credentials/api && buf generate
1717
make -C ./app/controlplane config
1818
make -C ./app/artifact-cas config
1919

app/controlplane/cmd/wire.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@ func wireApp(*conf.Bootstrap, credentials.ReaderWriter, log.Logger, sdk.Availabl
4848
wire.Bind(new(biz.CASClient), new(*biz.CASClientUseCase)),
4949
serviceOpts,
5050
wire.Value([]biz.CASClientOpts{}),
51-
wire.FieldsOf(new(*conf.Bootstrap), "Server", "Auth", "Data", "CasServer", "ReferrerSharedIndex"),
51+
wire.FieldsOf(new(*conf.Bootstrap), "Server", "Auth", "Data", "CasServer", "ReferrerSharedIndex", "Onboarding"),
5252
wire.FieldsOf(new(*conf.Data), "Database"),
5353
dispatcher.New,
5454
authz.NewDatabaseEnforcer,

app/controlplane/cmd/wire_gen.go

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

app/controlplane/configs/config.devel.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -58,3 +58,4 @@ auth:
5858
# enabled: true
5959
# allowed_orgs:
6060
# - deadbeef
61+

app/controlplane/configs/samples/config.yaml

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -56,4 +56,10 @@ credentials_service:
5656
referrer_shared_index:
5757
enabled: true
5858
allowed_orgs:
59-
- deadbeef
59+
- deadbeef
60+
61+
onboarding:
62+
- name: "read-only-demo"
63+
role: "viewer"
64+
- name: "read-write-demo"
65+
role: "owner"

app/controlplane/internal/conf/buf.lock

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,12 @@ deps:
44
- remote: buf.build
55
owner: bufbuild
66
repository: protovalidate
7-
commit: b983156c5e994cc9892e0ce3e64e17e0
7+
commit: 46a4cf4ba1094a34bcd89a6c67163b4b
88
- remote: buf.build
99
owner: googleapis
1010
repository: googleapis
11-
commit: 7a6bc1e3207144b38e9066861e1de0ff
11+
commit: f0e53af8f2fc4556b94f482688b57223
12+
- remote: buf.build
13+
owner: kratos-go
14+
repository: kratos
15+
commit: e1d52e944e3845c6862a566db322432d

app/controlplane/internal/conf/buf.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ breaking:
55
deps:
66
- buf.build/googleapis/googleapis
77
- buf.build/bufbuild/protovalidate
8+
- buf.build/kratos-go/kratos
89
lint:
910
use:
1011
- DEFAULT

0 commit comments

Comments
 (0)