diff options
| author | George Halkiadakis <gchalkiadakis@sklavenitis.co.gr> | 2023-04-17 12:12:22 +0300 |
|---|---|---|
| committer | George Halkiadakis <gchalkiadakis@sklavenitis.co.gr> | 2023-04-17 12:12:22 +0300 |
| commit | 68fc9e55e538e03f94509731ab41a0c8cf96710f (patch) | |
| tree | 3edb1e81864ac3eb35ba0fe8087ed24da1b812bf /core | |
| parent | 84b2da85a1b452922dadb6a609533b9945afe51d (diff) | |
| download | classroom-68fc9e55e538e03f94509731ab41a0c8cf96710f.tar.gz classroom-68fc9e55e538e03f94509731ab41a0c8cf96710f.tar.bz2 classroom-68fc9e55e538e03f94509731ab41a0c8cf96710f.zip | |
setup a real server environment (apache DocumentRoot=/var/www/public)
Diffstat (limited to 'core')
| -rw-r--r-- | core/README.md | 2 | ||||
| -rw-r--r-- | core/classes/session/FilesSession.php | 2 | ||||
| -rw-r--r-- | core/cli/micro/setup.php | 4 | ||||
| -rw-r--r-- | core/config/anom_settings.php | 5 | ||||
| -rw-r--r-- | core/config/init.php | 2 |
5 files changed, 8 insertions, 7 deletions
diff --git a/core/README.md b/core/README.md index fb92086..8dee940 100644 --- a/core/README.md +++ b/core/README.md @@ -168,7 +168,7 @@ NOTE: directory structure needs updata, but the main structure ramains untouched | |-- data * folder for batch data-imports to database | - |-- html ** PUBLIC directory + |-- public ** PUBLIC directory | |-- app * APP | | |-- Controllers * Controllers | | | |-- Art.php diff --git a/core/classes/session/FilesSession.php b/core/classes/session/FilesSession.php index a06f29c..a3c8437 100644 --- a/core/classes/session/FilesSession.php +++ b/core/classes/session/FilesSession.php @@ -36,7 +36,7 @@ class FileSessionHandler implements SessionHandlerInterface { // values comming from configuration $this->sessionName = SESSION_NAME; - $this->sess_filename = $path; + $this->sess_filename = FILESESSION_PATH; $this->minutes = $minutes; // Set handler to overide SESSION diff --git a/core/cli/micro/setup.php b/core/cli/micro/setup.php index 3a8e5eb..ca2fd40 100644 --- a/core/cli/micro/setup.php +++ b/core/cli/micro/setup.php @@ -54,7 +54,7 @@ define('APP_NAME', 'e-Classroom'); // Application Name define('APP_VERSION', 'v0.1'); // Application version -define('APP_ROOT', realpath(MINI_APP_BASE.'../../html')); +define('APP_ROOT', realpath(MINI_APP_BASE.'../../public')); // Cache driver and caching TTLs // ----------------------------------------------------------------------------- @@ -69,7 +69,7 @@ define('CACHE_CATEGORY_TTL', 18000); // 5 hours // Product define('CACHE_PRODUCT_TTL', 3600); // 1 hour -define('FILECACHE_PATH', realpath(MINI_APP_BASE.'../../html/cache/').'/'); +define('FILECACHE_PATH', realpath(MINI_APP_BASE.'../../storage/cache/').'/'); echo "Cache Directory is ". textColor(FILECACHE_PATH, GREEN)."\n"; diff --git a/core/config/anom_settings.php b/core/config/anom_settings.php index 399c180..f98c95d 100644 --- a/core/config/anom_settings.php +++ b/core/config/anom_settings.php @@ -117,7 +117,8 @@ define('AUTOLOADER' , '../vendor/autoload.php'); define('SESSION_DRIVER', 'DefaultSession'); - +// if FileSession is selected, a path for session-files is needed +# define('FILESESSION_PATH', '../storage/session'); /* ADVANCED OPTIMIZATION /////////////////////////////////////////////////////// * ----------------------------------------------------------------------------- @@ -158,7 +159,7 @@ define('CACHE_PRODUCT_TTL', 3600); // 1 hour // CONNECTIONS ... -define('FILECACHE_PATH', APP_ROOT.'/cache/'); // if CACHE_DRIVER is set to 'FileCache' +define('FILECACHE_PATH', APP_ROOT.'../storage/cache/'); // if CACHE_DRIVER is set to 'FileCache' # define('REDIS_HOST', '127.0.0.1'); // if CACHE_DRIVER is set to 'RedisCache' diff --git a/core/config/init.php b/core/config/init.php index 0dbaaf0..c64b35d 100644 --- a/core/config/init.php +++ b/core/config/init.php @@ -6,7 +6,7 @@ * (Registry and Request) * * Include _anything_ that is common practice on the request life-cycle - * of your project and does not need to be shown in the /html/index.php + * of your project and does not need to be shown in the /public/index.php * Usualy here you shall initialize supplamentary services like Sessions * / Database / Caching etc. * |
