This repository has been archived by the owner on Jan 6, 2023. It is now read-only.
-
-
Notifications
You must be signed in to change notification settings - Fork 204
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
0 parents
commit af42562
Showing
5,609 changed files
with
539,713 additions
and
0 deletions.
The diff you're trying to view is too large. We only load the first 3000 changed files.
There are no files selected for viewing
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
# Directus API 2.0 | ||
|
||
<p align="center"> | ||
<img src="https://camo.githubusercontent.com/ebf016c308b7472411bd951e5ee3c418a44c0755/68747470733a2f2f73332e616d617a6f6e6177732e636f6d2f662e636c2e6c792f6974656d732f33513238333030343348315931633146314b32442f64697265637475732d6c6f676f2d737461636b65642e706e67" alt="Directus Logo"/> | ||
</p> | ||
|
||
<p align="center">Open-Source Headless CMS API</p> | ||
<p> </p> | ||
|
||
**Important:** This API is currently under development for the next major [Directus](https://github.com/directus/directus) version. It is not ready to be used on production yet. | ||
|
||
[![Join the chat at https://slack.getdirectus.com](https://img.shields.io/badge/chat-on%20slack-C7205A.svg)](https://slack.getdirectus.com) | ||
[![GitHub issues](https://img.shields.io/github/issues/directus/api.svg)](https://github.com/directus/api/issues) | ||
[![GitHub license](https://img.shields.io/badge/license-GPL-blue.svg)](https://raw.githubusercontent.com/directus/api/master/license.md) | ||
[![StackShare](http://img.shields.io/badge/tech-stack-0690fa.svg?style=flat)](https://stackshare.io/ranger/directus) | ||
|
||
Read the [installation guide](docs/guide) to get started. | ||
|
||
## Copyright, License, and Trademarks | ||
* Directus Core codebase released under the [GPLv3](http://www.gnu.org/copyleft/gpl.html) license. | ||
* Example Code, Design Previews, Demonstration Apps, Custom Extensions, Custom interfaces, and Documentation copyright 2017 [RANGER Studio LLC](http://rngr.org/). | ||
* RANGER Studio owns all Directus trademarks, service marks, and graphic logos on behalf of our project's community. The names of all Directus projects are trademarks of [RANGER Studio LLC](http://rngr.org/). |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
rm -rf .directus-build | ||
git clone https://github.com/directus/directus.git .directus-build | ||
|
||
pushd .directus-build | ||
npm install | ||
gulp build | ||
gulp deploy | ||
popd | ||
|
||
rm -rf .directus-build |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
git subsplit init [email protected]:directus/directus.git | ||
|
||
# Collection | ||
git subsplit publish --heads="version/6.4" --no-tags --debug api/core/Directus/Collection:[email protected]:directus/directus-collection.git | ||
|
||
# Config | ||
git subsplit publish --heads="version/6.4" --no-tags --debug api/core/Directus/Config:[email protected]:directus/directus-config.git | ||
|
||
# Permissions | ||
git subsplit publish --heads="version/6.4" --no-tags --debug api/core/Directus/Permissions:[email protected]:directus/directus-permissions.git | ||
|
||
# Database | ||
git subsplit publish --heads="version/6.4" --no-tags --debug api/core/Directus/Database:[email protected]:directus/directus-database.git | ||
|
||
# Filesystem | ||
git subsplit publish --heads="version/6.4" --no-tags --debug api/core/Directus/Filesystem:[email protected]:directus/directus-filesystem.git | ||
|
||
# Hash | ||
git subsplit publish --heads="version/6.4" --no-tags --debug api/core/Directus/Hash:[email protected]:directus/directus-hash.git | ||
|
||
# Hooks | ||
git subsplit publish --heads="version/6.4" --no-tags --debug api/core/Directus/Hook:[email protected]:directus/directus-hook.git | ||
|
||
# Utils | ||
git subsplit publish --heads="version/6.4" --no-tags --debug api/core/Directus/Util:[email protected]:directus/directus-php-utils.git | ||
|
||
rm -rf .subsplit |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
#!/usr/bin/env php | ||
<?php | ||
|
||
$basePath = realpath(__DIR__ . '/../'); | ||
// Composer Autoloader | ||
$loader = require $basePath . '/vendor/autoload.php'; | ||
|
||
$cli = new \Directus\Console\Cli($basePath); | ||
$cli->run(); | ||
|
||
?> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
#!/bin/sh | ||
|
||
# | ||
# Command line runner for unit tests for composer projects | ||
# (c) Del 2015 http://www.babel.com.au/ | ||
# No Rights Reserved | ||
# | ||
|
||
# | ||
# Clean up after any previous test runs | ||
# | ||
mkdir -p documents | ||
rm -rf documents/coverage-html-new | ||
rm -f documents/coverage.xml | ||
|
||
# | ||
# Run phpunit | ||
# | ||
vendor/bin/phpunit --coverage-html documents/coverage-html-new --coverage-clover documents/coverage.xml | ||
|
||
if [ -d documents/coverage-html-new ]; then | ||
rm -rf documents/coverage-html | ||
mv documents/coverage-html-new documents/coverage-html | ||
fi | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,155 @@ | ||
<?php | ||
|
||
return [ | ||
'app' => [ | ||
'path' => '/', | ||
'env' => 'development', | ||
'debug' => true, | ||
'default_language' => 'en', | ||
'timezone' => 'America/New_York', | ||
], | ||
|
||
'settings' => [ | ||
'debug' => true, | ||
'displayErrorDetails' => true, | ||
'logger' => [ | ||
'name' => 'directus-api', | ||
'level' => Monolog\Logger::DEBUG, | ||
'path' => __DIR__ . '/logs/app.log', | ||
], | ||
], | ||
|
||
'database' => [ | ||
'type' => 'mysql', | ||
'host' => 'localhost', | ||
'port' => 3306, | ||
'name' => 'directus', | ||
'username' => 'root', | ||
'password' => 'pass', | ||
'prefix' => '', // not used | ||
'engine' => 'InnoDB', | ||
'charset' => 'utf8mb4' | ||
], | ||
|
||
'cache' => [ | ||
'enabled' => false, | ||
'response_ttl' => 3600, // seconds | ||
'adapter' => 'filesystem', | ||
'path' => '/storage/cache', | ||
// 'pool' => [ | ||
// 'adapter' => 'apc' | ||
// ], | ||
// 'pool' => [ | ||
// 'adapter' => 'apcu' | ||
// ], | ||
// 'pool' => [ | ||
// 'adapter' => 'filesystem', | ||
// 'path' => '../cache/', // relative to the api directory | ||
// ], | ||
// 'pool' => [ | ||
// 'adapter' => 'memcached', | ||
// 'host' => 'localhost', | ||
// 'port' => 11211 | ||
// ], | ||
// 'pool' => [ | ||
// 'adapter' => 'redis', | ||
// 'host' => 'localhost', | ||
// 'port' => 6379 | ||
// ], | ||
], | ||
|
||
'filesystem' => [ | ||
'adapter' => 'local', | ||
// By default media directory are located at the same level of directus root | ||
// To make them a level up outsite the root directory | ||
// use this instead | ||
// Ex: 'root' => realpath(ROOT_PATH.'/../storage/uploads'), | ||
// Note: ROOT_PATH constant doesn't end with trailing slash | ||
'root' => 'storage/uploads', | ||
// This is the url where all the media will be pointing to | ||
// here all assets will be (yourdomain)/storage/uploads | ||
// same with thumbnails (yourdomain)/storage/uploads/thumbs | ||
'root_url' => '/storage/uploads', | ||
'root_thumb_url' => '/storage/uploads/thumbs', | ||
// 'key' => 's3-key', | ||
// 'secret' => 's3-key', | ||
// 'region' => 's3-region', | ||
// 'version' => 's3-version', | ||
// 'bucket' => 's3-bucket' | ||
], | ||
|
||
// HTTP Settings | ||
'http' => [ | ||
'emulate_enabled' => false, | ||
// can be null, or an array list of method to be emulated | ||
// Ex: ['PATH', 'DELETE', 'PUT'] | ||
// 'emulate_methods' => null, | ||
'force_https' => false | ||
], | ||
|
||
'mail' => [ | ||
'transport' => 'mail', | ||
'from' => '[email protected]' | ||
], | ||
|
||
'cors' => [ | ||
'enabled' => false, | ||
'origin' => ['*'], | ||
'headers' => [ | ||
['Access-Control-Allow-Headers', 'Authorization, Content-Type, Access-Control-Allow-Origin'], | ||
['Access-Control-Allow-Methods', 'GET,POST,PUT,PATCH,DELETE'], | ||
['Access-Control-Allow-Credentials', 'false'] | ||
] | ||
], | ||
|
||
'rate_limit' => [ | ||
'enabled' => false, | ||
'limit' => 100, // number of request | ||
'interval' => 60, // seconds | ||
'adapter' => 'redis', | ||
'host' => '127.0.0.1', | ||
'port' => 6379, | ||
'timeout' => 10 | ||
], | ||
|
||
'hooks' => [], | ||
|
||
'filters' => [], | ||
|
||
'feedback' => [ | ||
'token' => 'a-kind-of-unique-token', | ||
'login' => true | ||
], | ||
|
||
// These tables will not be loaded in the directus schema | ||
'tableBlacklist' => [], | ||
|
||
'auth' => [ | ||
'secret_key' => '<secret-authentication-key>', | ||
'social_providers' => [ | ||
// 'okta' => [ | ||
// 'client_id' => '', | ||
// 'client_secret' => '', | ||
// 'base_url' => 'https://dev-000000.oktapreview.com/oauth2/default' | ||
// ], | ||
// 'github' => [ | ||
// 'client_id' => '', | ||
// 'client_secret' => '' | ||
// ], | ||
// 'facebook' => [ | ||
// 'client_id' => '', | ||
// 'client_secret' => '', | ||
// 'graph_api_version' => 'v2.8', | ||
// ], | ||
// 'google' => [ | ||
// 'client_id' => '', | ||
// 'client_secret' => '', | ||
// 'hosted_domain' => '*', | ||
// ], | ||
// 'twitter' => [ | ||
// 'identifier' => '', | ||
// 'secret' => '' | ||
// ] | ||
] | ||
], | ||
]; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
<?php | ||
|
||
return [ | ||
'paths' => [ | ||
'migrations' => '%%PHINX_CONFIG_DIR%%/../migrations/db/schemas', | ||
'seeds' => '%%PHINX_CONFIG_DIR%%/../migrations/db/seeds' | ||
], | ||
|
||
'version_order' => 'creation', | ||
|
||
'environments' => [ | ||
'default_migration_table' => 'directus_migrations', | ||
'default_database' => 'development' | ||
] | ||
]; |
Empty file.
Oops, something went wrong.