Page MenuHomePhorge

Setup all a tenant needs in a single command
ClosedPublic

Authored by mollekopf on Jun 11 2024, 10:18 PM.
Tags
None
Referenced Files
F17181486: D4776.id13741.diff
Mon, Dec 9, 4:07 AM
Unknown Object (File)
Sat, Dec 7, 8:18 PM
Unknown Object (File)
Fri, Dec 6, 10:46 PM
Unknown Object (File)
Wed, Dec 4, 7:22 AM
Unknown Object (File)
Tue, Dec 3, 11:11 AM
Unknown Object (File)
Mon, Dec 2, 1:42 AM
Unknown Object (File)
Mon, Dec 2, 12:16 AM
Unknown Object (File)
Sun, Dec 1, 10:47 PM
Subscribers

Details

Reviewers
machniak
Group Reviewers
Restricted Project
Commits
rKd2771e8d54fd: Setup all a tenant needs in a single command

Diff Detail

Repository
rK kolab
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

mollekopf created this revision.
mollekopf added a reviewer: Restricted Project.Jun 11 2024, 10:23 PM
machniak subscribed.
machniak added inline comments.
src/app/Console/Commands/Tenant/CreateCommand.php
38

There might be a soft-deleted user with this email, we should validate that. Also we probably should validate the email address itself.

162

What if the domain isn't public? I think we should bail out.

167

If it existed before it's not "created".

173

These have to be URLs. I.e. https:// prefix needs to be added.

This revision now requires changes to proceed.Jun 12 2024, 10:24 AM
src/app/Console/Commands/Tenant/CreateCommand.php
174

These are mail.* options.

mollekopf marked 2 inline comments as done.

To be able to validate things we now just validate first, and then create everything, and bail out if user or domain are preexisting.
There's doesn't seem to really be a point in converting existing users.

machniak added inline comments.
src/app/Console/Commands/Tenant/CreateCommand.php
140–141

This part made sense with an existing user. Useless now.

src/tests/Feature/Console/Tenant/CreateTest.php
20

test-tenant@kolabnow.com is not used anymore in the test

41

test-tenant@kolabnow.com is not used anymore in the test.

74

I suppose you planned to use that userId in tearDown(), but it's not really needed.

This revision now requires changes to proceed.Jun 14 2024, 8:30 AM
This revision is now accepted and ready to land.Jun 14 2024, 12:41 PM