Forked from vikramacharya/Install PHP Redis Client on ec2 aws
Created
September 14, 2023 14:30
-
-
Save jimi008/4bba9ede6b7137b48ba097209289f404 to your computer and use it in GitHub Desktop.
Install PHP Redis Client on ec2 aws
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
##### ec2-user ####### | |
sudo yum update -y | |
sudo yum install -y httpd24 | |
sudo yum install -y httpd24 php56 mysql55-server php56-mysqlnd | |
sudo service httpd start | |
sudo service httpd restart | |
sudo chkconfig httpd on | |
chkconfig --list httpd | |
sudo usermod -a -G apache ec2-user | |
groups | |
service httpd restart | |
sudo chown -R ec2-user:apache /var/www/folder/ | |
sudo chmod 2775 /var/www/folder/ | |
find /var/www/folder/ -type d -exec sudo chmod 2775 {} \; | |
find /var/www/folder -type f -exec sudo chmod 0664 {} \; | |
echo "<?php phpinfo(); ?>" > /var/www/html/phpinfo.php | |
sudo echo "<?php phpinfo(); ?>" > /var/www/folder/phpinfo.php | |
#### ROOT USER ##### | |
mkdir -p /opt/redis/php | |
cd /opt/redis/php | |
wget –no-check-certificate https://github.com/nicolasff/phpredis/zipball/master | |
unzip master | |
cd phpredis-phpredis-4c8cf98 | |
make clean | |
yum install php56-devel | |
phpize | |
./configure | |
make | |
make test | |
make install | |
echo "extension=redis.so" > /etc/php.d/phpredis.ini | |
service httpd restart |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment