installation:
yum install -y epel-release
yum install -y httpd
yum install -y http://rpms.remirepo.net/enterprise/remi-release-7.rpm
yum-config-manager --enable remi-php74
yum install -y phpmyadmin mod_ssl php-mcrypt php-cli php-gd php-curl php-mysql php-ldap php-zip php-fileinfo php-intl yum-utils php-pecl-apcu php-intl
wget -O /var/www/html/info.php https://repo.bkatz.net/info.php.txt
wget -O /etc/httpd/conf.d/phpMyadmin.conf https://repo.bkatz.net/phpmyadmin.txt
systemctl enable httpd --now
virtual host
vi /etc/httpd/conf.d/example.conf
add:
<VirtualHost *:80>
ServerName www.example.com
ServerAlias example.com
DocumentRoot /var/www/example.com/public_html
ErrorLog /var/www/example.com/error.log
CustomLog /var/www/example.com/requests.log combined
</VirtualHost>
systemctl restart httpd
ssl virtual host
vi /etc/httpd/conf.d/ssl.conf
<VirtualHost *:443>
DocumentRoot /var/www/html
ServerName www.example.com
SSLEngine on
SSLCertificateFile /etc/ssl/private/certificate.crt
SSLCertificateKeyFile /etc/ssl/private/private.key
</VirtualHost>
systemctl restart httpd
ioncube loader install (V12):
wget -O /src/ioncube.zip https://downloads.ioncube.com/loader_downloads/ioncube_loaders_lin_x86-64.zip
cd /src & unzip ioncube.zip
cd ioncube
find php extension dir:
php -i | grep extension_dir
mv ioncube/ioncube_loader_lin_7.4.so /path_to_extension_dir/
echo 'zend_extension="/usr/lib/php/path_to_extension_dir/ioncube_loader_lin_7.4.so"' > your php.int_file
systemctl restart httpd
check now with "php -v"
exanple output:
PHP 7.4.3 (cli) (built: Jun 13 2022 13:43:30) ( NTS )
Copyright (c) The PHP Group
Zend Engine v3.4.0, Copyright (c) Zend Technologies
with the ionCube PHP Loader + ionCube24 v11.0.1, Copyright (c) 2002-2022, by ionCube Ltd.
with Zend OPcache v7.4.3, Copyright (c), by Zend Technologies
certbot (must create vHost befor)
yum install certbot python2-certbot-apache -y
certbot --apache -d yourdomain.com