-
-
Notifications
You must be signed in to change notification settings - Fork 204
[WIP] New implementations
NOTE: This is an active work in progress. The below are just random thoughts and experiments. It doesn't reflect the current codebase and/or installation steps.
Install directus
- Execute
composer global require directus/installer
Create a directus application
- Execute
directus new api
Configure your directus application in config/directus/projects/default.php
(this basically does everything the laravel installation below does automatically)
Install laravel
- Execute
composer global require laravel/installer
Create a laravel application
- Execute
laravel new api
Install directus
- Execute
composer require directus/directus
Add directus
provider in config/app.php
Directus\Api\Provider::class,
Add app
provider if you wish to expose app
in your application
Directus\App\Provider::class,
To create a new directus api, simply run
php artisan directus:create --project default
- This will create a new
default.php
config file underconfig/directus/projects/
folder
To configure a directus api, edit the corresponding configuration file under config/directus/projects
folder
To create a new directus api that uses use a custom config provider (for example environment variables), simply run
php artisan directus:create --project default --config env
--- if we keep using directus tables on the database ---
To install directus tables on a project's database, simply run
php artisan directus:install --project default
To upgrade your directus tables on a project's database, simply run
php artisan directus:upgrade --project default
To create a directus extensions, simply run
php artisan directus:extension create --name my_extension
To create custom routes, follow laravel instructions as this is just a laravel application enhanced with directus
Directus Internal Docs
Please see https://docs.directus.io for the usage guide.