Copyright (C) Wrocław University of Science and Technology (PWr), 2013-2021. All rights reserved.
Developed within CLARIN-PL project.
The dependencies are installed within Docker container and the Inforex source code is linked to the container as an external storage.
Before building the docker install Composer, Docker and Docker Compose running the following command:
sudo apt-get install composer docker docker-compose
Than build the docker by executing the following script.
./docker-dev-up.sh
Links:
- http://localhost:9080/inforex — default admin account admin/admin,
- http://localhost:7080 — phpMyAdmin with default an account inforex/password.
When new source files are added it is required to reload the composer dependencies by executing the following command:
composer update
- zlib (zlib1g, zlib1g-dev)
- PHP5.6 (php5.6, php5.6-dev, php5.6-zip, php5.6-gd, php5.6-soap)
- Apach2 (apache2)
- MySQL 5.x (mysql-server)
- Composer (composer)
-
Install re2c library
sudo apt-get install re2c
-
Install libxdiff library
wget http://www.xmailserver.org/libxdiff-0.23.tar.gz tar -xvf libxdiff-0.23.tar.gz cd libxdiff-0.23 ./configure make sudo make install sudo ldconfig
-
Install xdiff PECL module
sudo apt-get install php5.6-dev sudo pear install http://pecl.php.net/get/xdiff-1.5.2.tgz
-
Enable xdiff module for PHP
Insert following line into files:
- /etc/php/5.6/apache2/php.ini
- /etc/php/5.6/cli/php.ini
extension=xdiff.so
-
Restart Apache2
sudo service apache2 reload
composer install
In case of update:
composer update
Set access to folder engine/templates_c. Execute the following commands inside the inforex-{VERSION} folder:
mkdir engine/templates_c
chmod g+rwx engine/templates_c
sudo chown :www-data engine/templates_c
Create a new database and load database/init/inforex-v1.0.sql
with the following command:
CREATE DATABASE inforex;
CREATE USER 'inforex'@'localhost' IDENTIFIED BY 'password';
GRANT ALL PRIVILEGES ON inforex.* to inforex@localhost ;
mysql -u inforex inforex < database/init/inforex-v1.0.sql
Use one of the following methods.
Create symbolic link to the public_html folder using following command
sudo ln -s $PWD/public_html /var/www/inforex
Create a new virtual host file:
sudo vi /etc/apache2/sites-available/inforex.conf
with the following content:
Alias /inforex /PATH_INFOREX/public_html
<Directory /PATH_INFOREX/public_html>
Require all granted
</Directory>
and make a symbolic link:
cd /etc/apache2/sites-enabled/
sudo ln -s ../sites-available/inforex.conf inforex.conf
sudo vi /etc/mysql/mysql.conf.d/mysqld.cnf
[mysqld]
sql_mode = "STRICT_TRANS_TABLES,NO_ZERO_IN_DATE,NO_ZERO_DATE,ERROR_FOR_DIVISION_BY_ZERO,NO_AUTO_CREATE_USER,NO_ENGINE_SUBSTITUTION"
sudo service mysql restart
Open engine/config.php file and set the following parameters:
static private $path_engine = '/path/inforex-{VERSION}/engine';
static private $path_www = '/path/inforex-{VERSION}/public_html';
static private $path_secured_data = '/path/inforex-{VERSION}/data';
static private $url = 'http://SET_VALUE_domain/inforex';
static private $dsn = array(
'phptype' => 'mysql',
'username' => '',
'password' => '',
'hostspec' => 'localhost',
'database' => '',
);
Default admin account:
Login: admin
Password: admin