mirror of
https://github.com/php-curl-class/php-curl-class.git
synced 2026-08-25 10:09:06 +00:00
Replace HHVM's built-in webserver with Nginx for continuous integration tests
This commit is contained in:
@@ -1,7 +0,0 @@
|
||||
Log {
|
||||
Level = Verbose
|
||||
}
|
||||
|
||||
Server {
|
||||
DefaultDocument = index.php
|
||||
}
|
||||
+10
-1
@@ -5,5 +5,14 @@ elif [[ "${TRAVIS_PHP_VERSION}" == "5.5" ]]; then
|
||||
elif [[ "${TRAVIS_PHP_VERSION}" == "5.6" ]]; then
|
||||
php -S 127.0.0.1:8000 -t tests/PHPCurlClass/ &
|
||||
elif [[ "${TRAVIS_PHP_VERSION}" == "hhvm" ]]; then
|
||||
cd tests && hhvm --mode server --port 8000 --config PHPCurlClass/server.hdf &
|
||||
sudo add-apt-repository -y ppa:nginx/stable
|
||||
sudo apt-get update
|
||||
sudo apt-get install -y nginx
|
||||
sudo /usr/share/hhvm/install_fastcgi.sh
|
||||
root="$(pwd)/tests/PHPCurlClass"
|
||||
root="${root//\//\\/}"
|
||||
sudo sed --in-place --regexp-extended 's/listen 80 default_server;/listen 8000 default_server;/' /etc/nginx/sites-enabled/default
|
||||
sudo sed --in-place --regexp-extended "s/root \/usr\/share\/nginx\/html;/root ${root};/" /etc/nginx/sites-enabled/default
|
||||
sudo sed --in-place --regexp-extended 's/index index.html index.htm;/index index.php;/' /etc/nginx/sites-enabled/default
|
||||
sudo /etc/init.d/nginx restart
|
||||
fi
|
||||
|
||||
Reference in New Issue
Block a user