8. Console Commands¶
This section describes console commands available in this bundle.
8.1. Create a new organization¶
To make use of this bundle, you need to first create the default organization. You may also need to create some other, custom organization if needed.
Note
This command persists organizations in database depending on your enabled persistence backend. If the PHPCR backend is enabled it will store tenants in PHPCR tree.
To create the default organization, execute the following console command:
1 | php bin/console swp:organization:create --default
|
To create a custom organization which will be disabled by default, use the command:
1 | php bin/console swp:organization:create --disabled
|
To create a custom organization, execute the following console command:
1 | php bin/console swp:organization:create
|
Run php bin/console swp:organization:create --help
to see more details of how to use this command.
8.2. List available organizations¶
This command list all available organizations.
Usage:
1 | php bin/console swp:organization:list
|
Run php bin/console swp:organization:list --help
to see more details of how to use this command.
8.3. Create a new tenant¶
To make use of this bundle, you need to first create the default tenant. You may also need to create some other, custom tenants.
Note
This command persists tenants in database depending on your enabled persistence backend. If the PHPCR backend is enabled it will store tenants in PHPCR tree.
To create the default tenant, execute the following console command:
1 | php bin/console swp:tenant:create --default
|
Note
When creating default tenant the command requires you to have the default organization created.
To create a custom tenant which will be disabled by default, use the command:
1 | php bin/console swp:tenant:create --disabled
|
To create a custom tenant, execute the following console command:
1 | php bin/console swp:tenant:create
|
You will need to specify organization unique code so tenant can be assigned to the organization.
Run php bin/console swp:tenant:create --help
to see more details of how to use this command.