Environment Installation and Configuration

During the installation process, you will need to specify the connection to the database and domain in the system configuration file /config/sys.php.

To install the application on the server, follow these steps:

Environment Requirements

We recommend using CentOS or another Unix-like operating system.

The application has several mandatory system requirements for server environment configuration:

  • PHP version 7.4
  • PHP extensions: apc(u), curl, dom, gd, gettext, fileinfo, json, mbstring, openssl, pdo_mysql, pcntl, posix, spl, xmlreader, zip
  • Enabled PHP configuration: short_open_tag=On
  • PHP Ioncube Loader 12+ extension
  • MySQL 8+ database
  • Composer package manager

Web Server

You can use the following web servers:

  • Nginx+php-fpm: In this case, you need to include the settings described in the file /public_html/nginx.conf in the server configuration file of Nginx. or
  • Apache+mod_php or Apache+php-cgi: In this case, you need to use the file /public_html/.htaccess.

When configuring the domain on the server, the domain directory must specify the full path to /public_html.

Database

  • Create a MySQL database using the following files:
    • /install/install.sql
    • /install/install.categories.sql
    • /install/install.regions.sql
  • Specify the access to the created database in the system configuration file /config/sys.php (more details)

Project Domain

Specify the project domain in the settings.

  • In the system settings: /config/sys.php, settings site.* (change the domain to example.com)
  • We recommend using the editor Notepad++ or built-in online-editors (in ISPManager control panel or similar). Do not use the regular "Notepad" editor for these purposes.

Composer (Installing External Libraries)

Run the following console command in the /bff project directory:

composer install
  • This will install the external libraries used in the project.
  • We do not recommend running it as the root user.

Cron Manager

Configure the execution of the following cron task:

* * * * * /usr/bin/php -q /path/to/public_html/index.php bff=cron-manager

  • You need to change the path to the actual project path on the server before configuring.
  • Also, for correct operation (and better performance), check if the pcntl extension is enabled in the php settings.
  • The task must be executed by the user under which the project is launched and works (php execution). Do not improperly set it to run as the root user.

If the server is configured as Nginx+php-fpm:

  • Nginx runs under the user nginx.
  • Php-fpm runs under the user username.
  • The user username belongs to the nginx group.
  • The owner of all project files and directories is username:nginx.
  • The cron task should be executed by the user username. File /var/spool/cron/username:
  • * * * * * /usr/bin/php -q /path/to/public_html/index.php bff=cron-manager

If the server is configured as Apache+mod_php:

  • Apache runs under the user apache.
  • The owner of all project files and directories is apache:apache.
  • The cron task should be executed by the user apache. File /etc/crontab:
  • * * * * * apache /usr/bin/php -q /path/to/public_html/index.php bff=cron-manager

If the server is configured as Apache+php-cgi:

  • Apache runs under the user apache.
  • Php-cgi runs under the user username.
  • The user username belongs to the apache group.
  • The owner of all project files and directories is username:apache.
  • The cron task should be executed by the user username. File /var/spool/cron/username:
  • * * * * * /usr/bin/php -q /path/to/public_html/index.php bff=cron-manager

File and Directory Access

Allow write access to the following folders (and all their contents) from php (775):

The complete list of required directories, in case of access error, can be found in the System Status section.

Admin Panel

Access the admin panel of the project: {your project domain}/admin/

If the administrator password is lost, perform the following steps:

  • create a file /files/admin_password_recovery.txt, containing the new administrator password.
  • the administrator refers to the user who is a member of the "Super Administrator" group (user ID #1).
  • log in to the admin panel, enter the administrator's username (default is admin) and the password you specified in the file.
  • after successful authentication, the password will be changed to the new one, and the file will be automatically deleted.

System Status

To check the correctness of server and environment settings, go to the "Site Settings / System Status" section and perform a check by clicking the "Check Again" button.