A phalcon support has been added into CustomBuild script of DirectAdmin.
Phalcon is a full-stack PHP framework delivered as a C-extension. Its innovative architecture makes Phalcon the fastest PHP framework ever built!
The current version offer they is 4.0.4. The extension can be installed only for PHP 7+. Older PHP versions are not supported.
In order to get the extension installed we run the following commands as root:
cd /usr/local/directadmin/custombuild/ ./build update ./build set_php phalcon yes ./build php_phalcon
If you have old PHP versions from 5.x branch installed you will need to temporary disable them. Let's say we have 5.6 installed under php4_release:
PHP (default): 7.3 as php-fpm PHP (additional): 7.2 as php-fpm PHP (additional, 3rd): 7.1 as php-fpm PHP (additional, 4th): 5.6 as php-fpm
In order to get everything done OK, we need first to disable PHP 5.6. Here is it installed under php4_release, in your particular case the things might differ, and you might need to adjust the command accordingly. So for our case we run:
./build set php4_release no
It is safe to disable PHP 5.6 for the installation time, the command will change only options, and it does not remove PHP 5.6 from a server.
And as soon as we complete with the installation of PHP phalcon we need to re-enable PHP 5.6 (and other old versions) with the following command:
./build set php4_release 5.6
Again: Here is PHP 5.6 installed under php4_release, and you might need to adjust the command accordingly if you have the things differed.
As soon as the installation completed fine we can run the following command and/or check output of phpinfo():
php -i | grep -i phalcon
in order to make sure the extensions is enabled.
A sample output is shown below:
# php -i | grep -i phalcon phalcon Phalcon is a full stack PHP framework, delivered as a PHP extension, offering lower resource consumption and high performance. phalcon => enabled Author => Phalcon Team and contributors phalcon.db.escape_identifiers => On => On phalcon.db.force_casting => Off => Off phalcon.orm.case_insensitive_column_map => Off => Off phalcon.orm.cast_last_insert_id_to_int => Off => Off phalcon.orm.cast_on_hydrate => Off => Off phalcon.orm.column_renaming => On => On phalcon.orm.disable_assign_setters => Off => Off phalcon.orm.enable_implicit_joins => On => On phalcon.orm.enable_literals => On => On phalcon.orm.events => On => On phalcon.orm.exception_on_failed_metadata_save => On => On phalcon.orm.exception_on_failed_save => Off => Off phalcon.orm.ignore_unknown_columns => Off => Off phalcon.orm.late_state_binding => Off => Off phalcon.orm.not_null_validations => On => On phalcon.orm.update_snapshot_on_save => On => On phalcon.orm.virtual_foreign_keys => On => On phalcon.warning.enable => On => On