【环境搭建】

(1)搭建php环境(可以一个个编译,也可以安装集成)

(2)安装swoole扩展

  1.下载解压

    yum install unzip zip -y
    wget https://soft.itbulu.com/wdcp/swoole-src-swoole-1.7.21-stable.zip
    unzip swoole-src-swoole-1.7.21-stable.zip
    cd swoole-src-swoole-1.7.21-stable
  2.安装编译swoole
    phpize
  3.编译
    ./configure --with-php-config=/www/server/php/72/bin/php-config
  4.make
    make
    make install
  5.添加扩展(php.ini)
    extension=/www/server/php/72/lib/php/extensions/no-debug-non-zts-20151012/swoole.so
  6.重启服务器

猜你喜欢

转载自www.cnblogs.com/fyandy/p/10053144.html