Last active
June 3, 2021 07:51
-
-
Save hemantshekhawat/2607dd5351a81dee8ff4bc521ca4ec40 to your computer and use it in GitHub Desktop.
Gearman Job Server for CentOS 7
This file contains 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
###### Install Apache/httpd and PHP | |
# Before you begin any installation, make sure that your software is up to date: | |
sudo yum update | |
#Install Apache: | |
sudo yum install httpd | |
#Start Apache: | |
sudo systemctl start httpd.service | |
#Set Apache to start on server boot: | |
sudo systemctl enable httpd.service | |
# Install PHP | |
sudo yum -y install php php-pear php-mysql php-mcrypt php-mbstring | |
# Install php-devel dependency via yum | |
sudo yum -y install php-devel |
This file contains 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
#!/bin/sh | |
sudo yum -y install epel-release ius-release | |
# Auto update | |
sudo yum update | |
# Install the required packages | |
sudo yum -y install gcc-c++ gperf uuid-devel libuuid libuuid-devel uuid boost-devel libevent libevent-devel gcc | |
# Install Gearman Lib | |
sudo yum -y install libgearman-devel | |
# Get the latest stable build from Gearman PECL extension page. | |
# The current stable release is version 1.1.2 | |
wget http://pecl.php.net/get/gearman-1.1.2.tgz | |
tar -xzvf gearman-1.1.2.tgz | |
cd gearman-1.1.2 | |
# Now phpize and complie it: | |
phpize | |
./configure | |
make | |
make install | |
# You will finally see something like this: | |
# Installing shared extensions: /usr/lib64/php/modules/ | |
# Update PHP.INI file: | |
# The following line will need to be added to all php.ini files, usually located in /etc/php*. | |
# extension=”gearman.so” | |
# Or create the file configuration file | |
sudo touch /etc/php.d/gearman.ini | |
sudo echo 'extension=gearman.so' >> /etc/php.d/gearman.ini | |
# Verify the installation by viewing a phpinfo page or just via the command line. | |
# You will see "gearman" in the list | |
php -m | |
# Restart php and httpd | |
# Install Gearman Server | |
sudo yum install gearmand | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment