First install composer and change to domestic mirror
1.sudo Apt-get Install composer
composer config -g repo.packagist composer https://packagist.phpcomposer.com
Installation Environment
1. sudo apt-get install Nginx-light
2. sudo apt-get install php7.0 php7.0-curl php7.0-gd php7.0-gmp php7.0-json php7.0-mysql php7.0-opcache php7.0-readline
3.sudo Apt Install php-pear
4.sudopecl install swoole
5. echo ‘extension=swoole.so‘ >> /etc/php/7.0/mods-available/swoole.ini
cd /etc/php/7.0/cli/conf.d/ && ln -s ../../mods-available/swoole.ini 20-swoole.inicd /etc/php/7.0/fpm/conf.d/ && ln -s ../../mods-available/swoole.ini 20-swoole.ini
sudo composer create-project easyswoole/app easyswoole
php easyswoole start
- The option must be turned off in a bashonwindows environment
daemonize
- Need to modify
config.h
closeHAVE_SIGNALFD
Some questions:
If Sh:phpize:command not found appears
Can trysudo apt-get install php-dev
If it appears
No releases available for package "Pecl.php.net/swoole"
Install failed
尝试:pear clear-cache pear update-channels pear upgrade
如果:Failed to download nikic/fast-route from dist: The zip extension and unzip command are both missing, skipping.
sudo apt-get install php-zip
Windows Subsystem Ubuntu18.04 installation Swoole