diff --git a/INSTALL/INSTALL.md b/INSTALL/INSTALL.md index 6d07f89..2dd5675 100644 --- a/INSTALL/INSTALL.md +++ b/INSTALL/INSTALL.md @@ -9,13 +9,13 @@ An Ubuntu server (18.04/20.04 should both work fine) - though other linux instal ## Cerebrate installation instructions It should be sufficient to issue the following command to install the dependencies: -``` +```bash sudo apt install apache2 mariadb-server git composer php-intl php-mbstring php-dom php-xml unzip php-ldap php-sqlite3 sqlite libapache2-mod-php php-mysql ``` Clone this repository (for example into /var/www/cerebrate) -``` +```bash sudo mkdir /var/www/cerebrate sudo chown www-data:www-data /var/www/cerebrate sudo -u www-data git clone https://github.com/cerebrate-project/cerebrate.git /var/www/cerebrate @@ -23,7 +23,7 @@ sudo -u www-data git clone https://github.com/cerebrate-project/cerebrate.git /v Run composer -``` +```bash cd /var/www/cerebrate sudo -u www-data composer install ``` @@ -31,7 +31,7 @@ sudo -u www-data composer install Create a database for cerebrate From SQL shell: -``` +```mysql mysql CREATE DATABASE cerebrate; CREATE USER 'cerebrate'@'localhost' IDENTIFIED BY 'YOUR_PASSWORD'; @@ -41,7 +41,7 @@ FLUSH PRIVILEGES; ``` Or from Bash: -``` +```bash sudo mysql -e "CREATE DATABASE cerebrate;" sudo mysql -e "CREATE USER 'cerebrate'@'localhost' IDENTIFIED BY 'YOUR_PASSWORD';" sudo mysql -e "GRANT USAGE ON *.* to cerebrate@localhost;" @@ -51,27 +51,27 @@ sudo mysql -e "FLUSH PRIVILEGES;" Load the default table structure into the database -``` +```bash sudo mysql -u cerebrate -p cerebrate < /var/www/cerebrate/INSTALL/mysql.sql ``` create your local configuration and set the db credentials -``` +```bash sudo -u www-data cp -a /var/www/cerebrate/config/app_local.example.php /var/www/cerebrate/config/app_local.php sudo -u www-data vim /var/www/cerebrate/config/app_local.php ``` mod_rewrite needs to be enabled: -``` +```bash sudo a2enmod rewrite ``` Simply modify the Datasource -> default array's username, password, database fields This would be, when following the steps above: -``` +```php 'Datasources' => [ 'default' => [ 'host' => 'localhost', @@ -83,7 +83,7 @@ Create an apache config file for cerebrate / ssh key and point the document root For development installs the following can be done: -``` +```bash # This configuration is purely meant for local installations for development / testing # Using HTTP on an unhardened apache is by no means meant to be used in any production environment sudo cp /var/www/cerebrate/INSTALL/cerebrate_dev.conf /etc/apache2/sites-available/