DodoApp: New app gets all internal users as read-write collaborators
Disable SoftServe keyless and anon access
Change-Id: I898a34a5dbd4c8ce049f834dd61a96a3abb1e603
diff --git a/core/installer/welcome/dodo_app.go b/core/installer/welcome/dodo_app.go
index 7a84d71..32fb0de 100644
--- a/core/installer/welcome/dodo_app.go
+++ b/core/installer/welcome/dodo_app.go
@@ -788,6 +788,21 @@
if err := s.client.AddReadWriteCollaborator(appName, user); err != nil {
return err
}
+ if !s.external {
+ go func() {
+ users, err := s.client.GetAllUsers()
+ if err != nil {
+ fmt.Println(err)
+ return
+ }
+ for _, user := range users {
+ // TODO(gio): fluxcd should have only read access
+ if err := s.client.AddReadWriteCollaborator(appName, user); err != nil {
+ fmt.Println(err)
+ }
+ }
+ }()
+ }
return nil
}